How to convert the instrument data into meaningful data? #1032
-
I already get real-time data from dcs-bios, but i find some problem: Additionally, there are various knob switches that, despite outputting integer values, do not directly correlate to their actual meanings. For instance, when I read values like '1' or '3' from these controls, it is unclear what these numbers represent in practical terms when I manipulate the instruments. Do I need to manually define these mapping rules one by one? Are there any reference documents available that could assist with this process? My goal is to accomplish this task using straightforward code implementations. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
It depend so what your goal is. Bios outputs a consistent range for most analog gauges because most people use those values to drive servos. In these cases things like actual gauge value isn't important - what's important is where the needle is on the gauge. For switches, the values 0-x represent the different distinct switch positions. In most cases, position 0 represents the off state (or the default state in the case of rotaries). There is no guide that lists all controls and exactly how their positions in dcs correspond to dcs-bios. That would be cool, but I'm not sure it's something we could maintain. There are a lot of aircraft and many have lots of switches. For things like gauges, this gets even more complex for gauges with a non-linear scale. Consider most VVIs, for example, where the range is -6000 to 6000, but -1000 to 1000 takes up around a third of the gauge. It would be very difficult for us to map the data we get from dcs (for this control, a decimal value between -1 and 1) to the actual vertical velocity of the aircraft. I guess the thing to remember is that dcs-bios outputs reflect the cockpit state of the aircraft - not necessarily what the aircraft is actually doing. We can only show the values we get from dcs. |
Beta Was this translation helpful? Give feedback.
Thanks for your help! I found that the description provided for each key in DCS games is not comprehensive. Some key descriptions can be parsed to extract state information; for example, in F14, 'PLT_UHF1_FREQ_MODE': PILOT UHF ARC-159 Freq Mode GUARD/MANUAL/PRESET. However, most keys do not have such descriptions, and for instruments that require formula-based value calculations, I could not find appropriate formulas either. This is indeed frustrating, and I have ultimately decided to manually match some commonly used multi-position switches and instruments, looking forward to your future work.