Is there a way to "monitor" the state of switches/knobs/buttons in this game?
-
as Dunc said, you can’t do that
Switch states are not externalized, so you can’t ask a software to do it as the information is not available from BMS shared memThe only way to do it, is to consider the user that clever software that put all switches in sync
And that’s done with the preflight cockpit checks -
@Red:
The only way to do it, is to consider the user that clever software that put all switches in sync
And that’s done with the preflight cockpit checksLol… some of us are too impatient we start the flight in the air… so no “preflight checks”…
-
doesn’t matter
You still have to place the switch in sync yourself, using the all position relevant callback -
Hmmm… okay, thank you, I think I got that part correct.
Now I know Falcon does make information available that allows cockpit builders to replicate the cockpit state — is this the “shared memory” you are talking about? So what exactly is in this shared memory? Is it just gauges and cockpit lights? Is that how MFDE and other cockpit extractors work, by reading this shared memory? So the cockpit switch states are not included in this?
-
yes, cockpit stuff is possible thanks to the information available in the sharedmemory
You can see what is in there by opening the flightdata.h in your doc folderit’s indeed gauge & lights stuff, but many other things - but no switch state
-
Yep, took a look, nothing about switches, mostly just lights and gauges.
-
Here’s my keyfile.
903 (different) callbacks without cougar (SSC/TQS) ones. These are included at end of file. -
Hmmm… okay, how do I make use of Flight Data.h information? How does it work? I was just hoping to be able to “watch for” the Master Arm switch coming on and would be able to reflect the On/Off state of the light in my project.
-
you need a sharedmemory reader, I’d check Viperpit for those, but they are in maintenance
-
I am curious how programs like Helios or MFDE reads the information. For example, how does MFDE know when to put on the caution light? If I can find out how it “reads” this info, I’ll try incorporating that to my program.
-
… I was just hoping to be able to “watch for” the Master Arm switch coming on and would be able to reflect the On/Off state of the light in my project.
WTH are you talking about?
Master Arm switch comming on…??? ON/OFF light…??? (What light ?)
Anyway, sharedmemory reflects all light states. Any sharedmemory reader will indicate lights states.
here’s a SM reader; https://www.assembla.com/code/lightningstools/subversion/nodes/releases/Programming%20Tools%20and%20Source%20Code/Falcon%204%20Shared%20Memory%20Reader%20for%20dotNet%20and%20COM?rev=95 (Work of “Mr.” Lightning)MFDE (and other) tools combine SM readers and video memory readings, coz MFDs and other Displays cannot be read from SM.
Also, follow this thread about SM structure and WIPs; https://www.benchmarksims.org/forum/showthread.php?5914-Shared-memory-documentation
-
I LOL at myself… I meant “Master Caution” light… sorry. Thanks for the links!
-
We can reverse the subject just to find a temporary solution. The key is:
Does exist a reachable falcon 4 database with all the “preset” button positions for every ramp start,taxyway, runway, Instant action, tac. engagement, dogfight campaign modes etc.?
If yes, the 99% of the job is done, just read that database for the mision you are are going to fly and sync your buttons before to start the mission.I´m almost sure the database exist in any way not sure if readable from the operating system.
Any help over there ?
-
maybe u can try dig out WDP.
before i use it, some info about HUD & MFD stored in myname.ini, but they only apply after “load” from MFD>>DTE page.
after using WDP, i dont need to “load” them any more, every time i jump in cockpit, all switch ready( i dont run WDP every time). -
Is there a way to “monitor” the state of switches/knobs/buttons in this game?
now that 4.33 is out, I want to ask that exact same question again in hope that there is now a new flightdata.h section or equivalent in place where i can read the current state of a switch in the sim.
checking the switches on startup (ramp or “in the air”) doesn’t help for every situation. desync can also occure for example with magnet-switches like jfs or autopilot in flight (for jfs not really “in flight” :-)) as well. -
i had a look at the flightdata.h file and I found at least the bits for the magnet-switches to determine whether jfs or ap is active or not.