Jump to content
The simFlight Network Forums
pilotjohn

Offset Status vs. Send Control and "Hold"

Recommended Posts

I noticed that some of the events listed in offsetStatus doc are not in the send control drop down, for example "GENERAL ENG STARTER:1".

Are they supposed to be?

Also are these new events toggles or settable?

Lastly, in general (for example TOGGLE_STARTER1) how can I achieve a "hold" behavior? If I use toggle starter it will toggle on for only a little while, not enough for the engine to start. Is there a way to achieve a "on while held" functionality?

 

 

Share this post


Link to post
Share on other sites
14 hours ago, pilotjohn said:

I noticed that some of the events listed in offsetStatus doc are not in the send control drop down, for example "GENERAL ENG STARTER:1".

This seems to be a common misunderstanding. The offset status documents is for the read/write functionality offered by FSUIPC's offsets. The data in the offsets table is populated (mainly) from simulator variables (aka simvars), not controls or events. Where an offset is related to a simvar, this is shown in the offset status document in the third column (column G).

Offsets (or simulator variables) can sometimes be updated directly on user request, and others are updated automatically by the model or on sim events (or controls). The read/write status of each offset is also given in the offset status document, together with its previous status in other FSUIPC versions (where it also indicates if the variable is updated by an event 'Ok-SimE' or by directly updating the simvar 'Ok-SimC').

Currently I have not provided a list of the available controls, which comprises of those provided by the SDK together with other controls added by FSUIPC. For the former list, you can use the 2016 list of FSX controls provided in previous versions (and attached to this comment). The FSUIPC added controls are  defined in the Advanced User manual, section Additional “FS” Controls added by FSUIP.The 2016 List of FSX and P3D Controls.pdf

14 hours ago, pilotjohn said:

Lastly, in general (for example TOGGLE_STARTER1) how can I achieve a "hold" behavior? If I use toggle starter it will toggle on for only a little while, not enough for the engine to start. Is there a way to achieve a "on while held" functionality?

You could try with Magneto Set, with a parameter of 1 on your button/key press, and a value of 0 on release. But I think that may also time out after a second or two. You could also try with repeat on. However, I think that this is probably how the starters are implemented, with it switching back from start automatically after a short period (or the engine is started).

Share this post


Link to post
Share on other sites
4 hours ago, John Dowson said:

This seems to be a common misunderstanding. The offset status documents is for the read/write functionality offered by FSUIPC's offsets. The data in the offsets table is populated (mainly) from simulator variables (aka simvars), not controls or events. Where an offset is related to a simvar, this is shown in the offset status document in the third column (column G).

Offsets (or simulator variables) can sometimes be updated directly on user request, and others are updated automatically by the model or on sim events (or controls). The read/write status of each offset is also given in the offset status document, together with its previous status in other FSUIPC versions (where it also indicates if the variable is updated by an event 'Ok-SimE' or by directly updating the simvar 'Ok-SimC').

So does updating an offset (thus simvar) sometimes have the same ultimate effect/result as a control would?

4 hours ago, John Dowson said:

Currently I have not provided a list of the available controls, which comprises of those provided by the SDK together with other controls added by FSUIPC. For the former list, you can use the 2016 list of FSX controls provided in previous versions (and attached to this comment). The FSUIPC added controls are  defined in the Advanced User manual, section Additional “FS” Controls added by FSUIP.The 2016 List of FSX and P3D Controls.pdf

It would be nice if this document could split into a table (like the spreadsheet for the offsets) so that we could filter on what works for MSFS (e.g. a checkbox column for each sim instead of the colors).

4 hours ago, John Dowson said:

You could try with Magneto Set, with a parameter of 1 on your button/key press, and a value of 0 on release. But I think that may also time out after a second or two. You could also try with repeat on. However, I think that this is probably how the starters are implemented, with it switching back from start automatically after a short period (or the engine is started).

Ack, will try that.

However, if I'm trying to make a generic starter button (which would need to send both magneto start and turbine start), there's no way to do this with repeat, correct?

If I have to resort to Lua for some things, a QQ: are the scripts loaded each time they're activated (e.g. button press), or are they cached in some way?

Share this post


Link to post
Share on other sites
15 minutes ago, pilotjohn said:

So does updating an offset (thus simvar) sometimes have the same ultimate effect/result as a control would?

It can do, but also note that updating an offset can also result in a control being sent (Ok-SimE) rather than the simvar being directly updated (Ok-SimC). But really, as an end user, you don't need to know how its implemented. Just use the controls, but if you cannot find a suitable control then try the offsets. It is preferable to use a control/event if available.

15 minutes ago, pilotjohn said:

It would be nice if this document could split into a table (like the spreadsheet for the offsets) so that we could filter on what works for MSFS (e.g. a checkbox column for each sim instead of the colors).

Yes, it would be nice but not that straightforward. For example, a control may work with one aircraft but not with another. And if a control doesn't work, there is not much we can do about it in FSUIPC - it needs to be reported and fixed in MSFS/by Asobo.

15 minutes ago, pilotjohn said:

However, if I'm trying to make a generic starter button (which would need to send both magneto start and turbine start), there's no way to do this with repeat, correct?

Why would you need to send both? You could overload your control to send both (by editing the ini), but then you should add an offset condition (using 0x0609) to only send the required control depending upon the aircraft type. You can repeat each control or not for each of the assignments, depending upon what works.
Alternatively, you can use profiles to send the correct control for that aircraft type.

15 minutes ago, pilotjohn said:

If I have to resort to Lua for some things, a QQ: are the scripts loaded each time they're activated (e.g. button press), or are they cached in some way?

It depends on the script. If its using an event, it will run all the time (or until killed), waiting for the event and then calling the appropriate function when received.
Some scripts may also run in an infinite loop, and others may simply run and terminate. Note that if they run and terminate, the next time they are called they will  be recompiled and ran in a new thread, which adds quite a bit of overhead. Using event based scripts is more efficient. So, its a lot more efficient to have a lua script running (usually from the [Auto] section of the in) and waiting for a button or key press event, rather than assigning the button or key press event to activate the lua.

 

 

Share this post


Link to post
Share on other sites

Thanks... is there a way to see what events are connected to what things in the aircraft model? For example, on some planes Avionics Mater switch events don't work. Are there options to try to inspect what should be sent instead?

Share this post


Link to post
Share on other sites
7 hours ago, pilotjohn said:

is there a way to see what events are connected to what things in the aircraft model?

You could try the SDK documentation where you will find a list of event ids (under variable lists) broken down by various categories (Aircraft engine, Aircraft Avionics, etc). However, be aware that many of these are not yet connected/working, so activating a function in the UI doesn't fire the event (i.e. nothing logged) and sending the event has no affect. In other cases, you can see the event when activated, but sending the event has no affect. This is a known issue and things should (hopefully) improve in this area in successive SimConnect /SDK updates.

7 hours ago, pilotjohn said:

For example, on some planes Avionics Mater switch events don't work. Are there options to try to inspect what should be sent instead?

There are other posts in this forum on the Avionics Master. Try using Avionics Master Set, possibly in combination with an offset conditional check on offset 0x02E80 (if using same button/key as a toggle)..

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.