I am now using these new wonderful systems in full for very detailed simulations, something I have come across that is not clear in the SDK documentation is how to use the indexed variables of these in different scenarios.
It is clear how to properly use the index names in RPN, for example given a circuit defined as:
circuit.1 = Type:CIRCUIT_PFD # ConsumerCfg:ConsumerPFD #Name:PFD
You would use it in RPN like this:
<ANIM_CODE>(A:CIRCUIT ON:'PFD'_n, percent)</ANIM_CODE>
however I cannot find how I am suppose to use it for:
Panel.xml for avionics:
Every panel.xml I have seen, is still using in the logic elements the old format:
<Simvar name="CIRCUIT ON:1" unit="boolean"/>
However the documentation state, we should be using the circuit name instead of a number for the index since the merge of aircraft parts could change the index number, so my question is, do the panel.xml logic elements support this? if so, how you use it then? an example would be useful for developers.
This apply obviously for hydraulics, pneumatics, new fuel system, etc.
WASM:
Same question, the examples I seen for the new VARS API is still using i as an index number:
FsUnitId unitId = fsVarsGetUnitId("DEGREES");
FsSimVarId simvarId = fsVarsGetAircraftVarId("ATTITUDE INDICATOR PITCH DEGREES");
FsVarParamArray param = FsCreateParamArray("i", 0);
double result = 0;
if (fsVarsAircraftVarGet(simvarId, unitId, param, &result) == FS_VAR_ERROR_NONE)
{
// valid
}
else
{
// error
}
So can we use a named circuit, hydraulic valve component, etc.? if so how?
I am worried that, although I can use the named index in RPN, I would be unable to do the same on panel.xml and custom WASM systems I have, so any advice on this, would be appreciated.
Regards,
Raul