Myles_DJL Posted August 12, 2023 Report Share Posted August 12, 2023 Hi All I have started the process of creating replica gauges for the P-51 and B-17, with the end goal of having them work with their counterpart A2A aircraft. Step one was to model the gauges and work out the mechanical side which I have done, I plan to use Mobiflight and Stepper motors for most gauges, the next step it to work out what LVARS are driving the gauges in the A2A aircraft, I am hoping to achieve this via LINDA. My question is, how would I go around writing the LVAR for say the Hydraulic gauge, to one of the spare FSUIPC offsets so that it can then talk to mobiflight ? I am quite the novice when it comes to this, I know how to use existing FSUIPC offsets with Mobiflight, but when it comes to writing my own, I wouldn't know where to start. Thanks in advance for your help Myles @Pete Dowson Link to comment Share on other sites More sharing options...
John Dowson Posted August 13, 2023 Report Share Posted August 13, 2023 22 hours ago, Myles_DJL said: how would I go around writing the LVAR for say the Hydraulic gauge, to one of the spare FSUIPC offsets so that it can then talk to mobiflight ? in FSUIPC6 and earlier, you need a simple lua script to write the lvar value to an offset when the lvar value changes, using the event.lvar function. See the following post where i explained in more detail on how to do this: You can also enable writing to the offset to update the lvar if you like, by using the event.offset function. In FSUIPC7, a mechanism is provided to add lvars to offsets for both reading and writing by using the FSUIPC7.ini file. This is explained in the Advanced User guide. John Link to comment Share on other sites More sharing options...
Myles_DJL Posted August 13, 2023 Author Report Share Posted August 13, 2023 Thanks John, I get how this would work for switches, but I’m not sure how I write the code for gauges and what values/variables to have, I’m probably overcomplicating it in my head, but I just can’t get head around how to write the code, maybe if I understood what the various elements of the code did it would make it easy to understand? Would you be able to walk me through it, I’m a complete novice when it comes to this. thanks Myles Link to comment Share on other sites More sharing options...
John Dowson Posted August 14, 2023 Report Share Posted August 14, 2023 No, sorry - I do not have any experience in gauge programming - that is a completely different ball game. I am only familiar with the SimConnect Sdk, not the gauges API. John Link to comment Share on other sites More sharing options...
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