Hello gents,
In my project,I have to request ALL simulation variables.Of course before this step,I should register struct with definition name.I do but , I am getting a lot of exception 7 (Specifies that the simulation event name (such as "brakes") is not recognized.)
And I decided to find out this exception coming from which line.Here is an example:
As you see,I try to map simulation variables to my variables in struct1.But there is wrong with last variable - STRUCT AMBIENT WIND.I use names and units as the same with simconnect variables document
But I am sure that this line cause an exception 7.When I remove it,the exception is gone.
Why ? Could anyone help me ?
Thanks for any advice..
In my project,I have to request ALL simulation variables.Of course before this step,I should register struct with definition name.I do but , I am getting a lot of exception 7 (Specifies that the simulation event name (such as "brakes") is not recognized.)
And I decided to find out this exception coming from which line.Here is an example:
Code:
simconnect.AddToDataDefinition(DEFINITIONS.struct1,
"AMBIENT WIND VELOCITY", "Knots", SIMCONNECT_DATATYPE.FLOAT64, 0.0f, SimConnect.SIMCONNECT_UNUSED);
simconnect.AddToDataDefinition(DEFINITIONS.struct1,
"AMBIENT WIND DIRECTION", "Degrees", SIMCONNECT_DATATYPE.FLOAT64, 0.0f, SimConnect.SIMCONNECT_UNUSED);
simconnect.AddToDataDefinition(DEFINITIONS.struct1,
"STRUCT AMBIENT WIND", "Feet_per_second", SIMCONNECT_DATATYPE.FLOAT64, 0.0f, SimConnect.SIMCONNECT_UNUSED);
As you see,I try to map simulation variables to my variables in struct1.But there is wrong with last variable - STRUCT AMBIENT WIND.I use names and units as the same with simconnect variables document
But I am sure that this line cause an exception 7.When I remove it,the exception is gone.
Code:
simconnect.AddToDataDefinition(DEFINITIONS.struct1,
"STRUCT AMBIENT WIND", "Feet_per_second", SIMCONNECT_DATATYPE.FLOAT64, 0.0f, SimConnect.SIMCONNECT_UNUSED);
Why ? Could anyone help me ?
Thanks for any advice..

