jsmarko3 Posted 9 hours ago Report Posted 9 hours ago I have FSUIPC v7.5.4 installed along with MSFS 2024. I am working with someone on the Just Flight forums to help them bind a few things with FSUIPC, and for the life of me I cannot get Magneto1_Incr or Magneto1_Decr to work, at least in the new Black Square Bonanza Pro. I've not yet tried with other aircraft, that's been the one I've been focused on for the past few days. I suppose that's probably the next step. Magneto1_Incr is one of the stock FS Controls offered by FSUIPC, so it should be as simple as binding that to a button, but for some reason the magnetos in the aircraft are not responding. I have tried doing it via the Asobo control binding, and it works if I bind the button to Increase Magneto 1 there, but for this other user's purposes that's not a solution. There is also a Magneto 1 Incr event included in the Mobiflight presets that also does not work, which is probably unsurprising as I'm sure it does the same thing. Since it works via the Asobo bindings I'm very surprised it doesn't work via the FS Controls (I remove any conflicting bindings between tests). Even using Execute Calculator Code with (>K:MAGNETO1_INCR) is not working (again, perhaps unsurprisingly), but I have been able to manipulate other K events through FSUIPC, such as the Kollsman increase/decrease, the battery switch via BATTERY1_SET, so I don't think it's a problem with my technique. Black Square is fantastic about documenting his usage of variables in his manuals, and K:MAGNETO1_INCR is specifically called out for magneto control, along with an LVar for setting it to a specific position instead of just up or down. Since it also works through the Asobo bindings, and I dug through the online SDK to confirm that K:MAGNETO1_INCR is what it should be, I feel pretty confident that calling Magneto1_Incr or the premade event through FSUIPC should also do the trick, and yet it isn't. For both this other fellow to refuses to use anything but FSUIPC for controller bindings, and my own budding understanding of how to do advanced (and perhaps basic) functions in FSUIPC, does anyone have any thoughts on why certain K events are not working? Semi-related: what language or formatting are events written in? I am familiar with the RPN portion for at least math, but my eyes very quickly glaze over when I get to some of the examples with various if statements or even simple things like one that had "near" before the min and max. I assume that's some sort of rounding function, but any pointers to what language or style, or some documentation there of would be appreciated. Thanks!
John Dowson Posted 9 hours ago Report Posted 9 hours ago 13 minutes ago, jsmarko3 said: Since it works via the Asobo bindings I'm very surprised it doesn't work via the FS Controls (I remove any conflicting bindings between tests). Some standard controls don't work when assigned externally, and this is aircraft-dependent and I assume an issue with the event implementation in the aircraft. I cannot do anything about this in FSUIPC. 17 minutes ago, jsmarko3 said: I cannot get Magneto1_Incr or Magneto1_Decr to work, at least in the new Black Square Bonanza Pro There are no MF presets for this yet. The presets for the magneto in the BS Bonanza G36 use the lvar L:BKSQ_IgnitionPosition_1 with a parameter of 0, 1 or 3 (for off/right/left), so maybe try them - check to see if those lvars exist or if there are similar ones for this aircraft. 20 minutes ago, jsmarko3 said: Semi-related: what language or formatting are events written in? I am familiar with the RPN portion for at least math, but my eyes very quickly glaze over when I get to some of the examples with various if statements or even simple things like one that had "near" before the min and max. I assume that's some sort of rounding function, but any pointers to what language or style, or some documentation there of would be appreciated. See the MSFS documentation: https://docs.flightsimulator.com/msfs2024/html/6_Programming_APIs/Reverse_Polish_Notation.htm John
jsmarko3 Posted 8 hours ago Author Report Posted 8 hours ago 51 minutes ago, John Dowson said: There are no MF presets for this yet. The presets for the magneto in the BS Bonanza G36 use the lvar L:BKSQ_IgnitionPosition_1 with a parameter of 0, 1 or 3 (for off/right/left), so maybe try them - check to see if those lvars exist or if there are similar ones for this aircraft. John For the Black Square Bonanza Pro specifically, no, but in the events.txt file I did find one for just MagnetoIncrease#(>K:MAGNETO1_INCR) or named similarly, I don't have it handy in front of me to look. The same LVar does exist in the new one, but I'm not knowledgeable about about scripting with RPN to try to make an increase/decrease function while having to set specific positions. Thanks for the link to the RPN part of the SDK, I'll have a look, and I'll talk more to Nick at Black Square about event implementation.
John Dowson Posted 8 hours ago Report Posted 8 hours ago 4 minutes ago, jsmarko3 said: For the Black Square Bonanza Pro specifically, no, but in the events.txt file I did find one for just MagnetoIncrease#(>K:MAGNETO1_INCR) or named similarly, Did you try the MAGNETO_INCR k-event instead of the MAGNETO1 one? But I don't think that will work either... If the BS Bonanza G36 uses an lvar, I would have thought the Pro would use something similar. Have you tried listing the lvars to see if anything looks appropriate? Also maybe try looking at the Input Events - you can list these, and also log any changes. Set logging for Input Events, (Log->Input Events) open the logging console (Log->Open Console) and turn the magneto in the virtual cockpit (VC) to see if anything is logged. You can also examine the behavior of the switch using the MSFS dev tools to see how it is controlled - see this MF documentation: https://docs.mobiflight.com/guides/input-events-2024/ You can assign to input events in FSUIPC in two ways: 1. Using Input Event assignments directly 2. via calculator code and using them as B events (MSFS2024 only - doesn't work in MSFS2020) John
jsmarko3 Posted 8 hours ago Author Report Posted 8 hours ago 15 minutes ago, John Dowson said: Did you try the MAGNETO_INCR k-event instead of the MAGNETO1 one? But I don't think that will work either... I did and you are correct, it did not work either. 15 minutes ago, John Dowson said: If the BS Bonanza G36 uses an lvar, I would have thought the Pro would use something similar. Have you tried listing the lvars to see if anything looks appropriate? I edited the post a minute or so after I posted it to say this, but yes the Pro has the same named variable with a similar range. That does work. I have asked Nick on the Just Flight forums if he has any insight as to why the magneto K event would not work while I have a handful of other ones I tried that do work. Using the LVar is possible; I could write something right now to set it to a specific value, and I may do that myself in a few days when my button box and key switch arrive, but for an increase/decrease function I would need to get smart on scripting to check what it is set to and where it should go. I will likely put some thought and man-hours into trying to log it as you suggest; someone in a different topic on the JF forums mentioned he used some in-game developer tools to see what variables are changing, so I have a few options to go down that rabbit hole. B events are something I never touched, but I see there are few listed in various Black Square manuals as variables you can manipulate, so I may end up needing or wanting to learn them down the road. EDIT: and as always, thanks for the help.
John Dowson Posted 6 hours ago Report Posted 6 hours ago 1 hour ago, jsmarko3 said: I could write something right now to set it to a specific value, and I may do that myself in a few days when my button box and key switch arrive, but for an increase/decrease function I would need to get smart on scripting to check what it is set to and where it should go. You can do this easily in two ways: 1. use a preset to increment using '++'. Also use min/max so it stays within range 2. Add the lvar to an FSUIPC offset, then use the FSUIPC-added controls to inc/dec/cycle the offset. Changing the offset value in this way, when the offste holds an lvar, will send the new value to the FS. 1 hour ago, jsmarko3 said: I have asked Nick on the Just Flight forums if he has any insight as to why the magneto K event would not work Well, many standard events don't work for many add-on aircraft in MSFS, both MSFS2020 and MSFS2024. That is why you need to look into lvars, hvars, bvars, etc 1 hour ago, jsmarko3 said: I will likely put some thought and man-hours into trying to log it as you suggest; someone in a different topic on the JF forums mentioned he used some in-game developer tools to see what variables are changing, so I have a few options to go down that rabbit hole. Usually you can use FSUIPC logging - either events or input events. For lvars its more complicated - you have to find the lvars you want to monitor first (list them in FSUIPC), and then you can log the lvar changes to the lvars by adding a section to the FSUIPC7.ini file. This is documented in the WASM section of the Advanced User guide. 1 hour ago, jsmarko3 said: B events are something I never touched, but I see there are few listed in various Black Square manuals as variables you can manipulate, so I may end up needing or wanting to learn them down the road. B-events are Input Events, just via a different root - in FSUIPC, you can use input events directly via the Simconnect interface. B-events are only for use in gauge code, i.e. via valculator code or a preset. There is a mapping from B-events to input events, but not 1-1. For ecample, there may be just one input event which has a value (which you can change/set), but there may be several b-events associated to this input event, such as *_set, *_inc, *_dec. You won;t see these in the input event interface, just a variable with a value that you can control. 1 hour ago, jsmarko3 said: EDIT: and as always, thanks for the help. No problem! Cheers, John
jsmarko3 Posted 4 hours ago Author Report Posted 4 hours ago 1 hour ago, John Dowson said: use a preset to increment using '++'. Also use min/max so it stays within range I spent well over an hour learning a very valuable lesson on what exactly the leading > before an LVar means and does, but I think I'm well on my way. Need some help from Nick at Black Square about the magnetos not responding appropriately, but once that's solved I think I'm pretty much set with this. 1 hour ago, John Dowson said: Well, many standard events don't work for many add-on aircraft in MSFS, both MSFS2020 and MSFS2024. That is why you need to look into lvars, hvars, bvars, etc That's why I'm surprised the in-sim bindings work, but sending the K events directly does not, but again, a question for Nick.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now