For GIT version 2.4.0.0 and above
Due to the limitations of the Majestic Q400 External XML Interface, some issues exist when using Detective.
Not all LVars are genuine LVars, they are fake and have been created in this tool to simplify interfacing to this aircraft.
Fake LVars CANNOT be monitored in real-time due to the poor performance of the Majestic Q400 External XML Interface.
However, once Fake LVars are referenced in a Bespoke Event or used in a GoFlight device configuration, they will appear in the monitoring console window because they will have been added to the monitoring queue.
The number of Fake LVars that can be read and written to per second is exactly the same as your Frames Per Second. The Majestic Q400 External XML Interface returns data after each frame; but only one variable can be read per frame and another written to per frame.
Fake LVars contain -> near the beginning of their name.
Therefore the following guidance should be followed:
- Always use Simconnect variables and events whenever possible.
- If no Simconnect variables/events can be used, use LVars.
- If no LVars can be used, use Fake LVars.
- If you use Fake LVars anywhere in this tool, you must NEVER use the LVars MJC_VAR_READ_CODE, MJC_VAR_READ_VALUE, MJC_VAR_WRITE_CODE, and MJC_VAR_WRITE_VALUE as this will cause unpredictable results.
Note, that testing various Fake LVars can build up the monitoring queue to such an extent that the Fake LVars are taking along time to update. To solve this, simply quit this software and reload it. Do not use Restart as you will lose your changes!
For other GIT versions
Creating Bespoke Events
- Download the following interface package: www.majesticsoftware.com/fileexchange/MJC84/MJC84_XML_IF_1008.zip
- Unpack the interface package into an appropriate directory.
- Open the file <your flight sim directory>\SimObjects\Airplanes\mjc8q400\doc\scripts\varlist.xlsx
- Search for the variable you wish to change.
- Copy the full variable name; e.g. airData_->ADC[0].controls.barometricCorrectionRotaryDelta
- From the extracted interface package, start IntVarCRCGen.exe and paste the variable name into the FULL MJC VAR NAME field, making sure there are no spaces at the end of the pasted variable name.
- Copy the resulting CRC value which will be used as the value in setting the MJC_VAR_WRITE_CODE in Detective.
- In Detective, create a new Bespoke Event. In our example its for the ADC barometer rotary. This being a rotary function, two bespoke events will ultimately be required; one for clockwise and one for anticlockwise.
- Find MJC_VAR_WRITE_VALUE in the Lvar list and click Set. Set this value to 1 for positive rotation (clockwise) or -1 for negative rotation (anticlockwise). Click OK.
- Find MJC_VAR_WRITE_CODE in the Lvar list and click Set. Set this value to the value found in step 7 which should be 167545 and click OK.
- Test the bespoke event.
Settings Displays & LED's
- GIT version 2.1.14.0 or above is required.
- If the Lvar does not exist you will either have to add the light update to the relevant Bespoke Event or execute the light updates in the "Start" Bespoke Event that will run continuously and update the lights.
- Update the light in the Bespoke Event if the light only changes due to a button press. Update the light in the Start event if the flight sim can update it dynamically.
- All light updates will need to use a Bespoke Variable and this Bespoke Variable will be assigned as the Light Data.
- To update the lights, use a similar process as for creating the Bespoke Events for the Q400. The following example for the Terrain Inhibit light shows the format of the Bespoke Event (the text in italics is for reference only and shows the tasks used):
MJC_VAR_READ_CODE = 71619 <-- Set. Remember this value changes based on the variable to be read!
: 71619 <-- Label. Set the same as the variable code.
Sleep 150 <--Sleep.
If MJC_VAR_READ_CODE != 9991999 Next Else NextSkip <--If.
Goto 71619 <-- Goto.
Bespoke Var 0 = MJC_VAR_READ_VALUE <-- Set =. Remember to use a different Bespoke Var for each light variable! - For the Start Bespoke Event, include as many variables as you like, each using the above format, however the first task must be a Label called Begin and the very final task should be a Goto Begin so that it loops continuously. Remember the Start Bespoke Event only starts when GIT is first loaded, so you will initially need to restart GIT the very first time the Start Bespoke Event is created.