I'm trying to understand how to use datarefs. I have a datarefs.txt file in one of my airplane folders in Xplane but I have no idea how to read those in Spadnext. Is there a simple explenation available how I can use them. I'm trying to set it up for Airfoilabs Kinga Air 350 and it is not easy
SPAD.neXt automatically reads the datarefs that are in the file datarefs.txt in your aircraft folder. These datarefs are unique for this aircraft. The datarefs from this local file are added to the default XPLane11 datarefs (located in ..\X-Plane 11\Resources\plugins \datarefs.txt).
The dataref is an XPlane parameter/variable that you can connect to a button/switch/handle of a controller.
You can see the XPlane datarefs (default XPLane + the aircraft-specific) when you define an action/event to a controller button/switch/handle.
Throttle Quadrant – Button T5 – Add Event (Button pressed) – Add Action - Change Data Value.
A list of all X-Plane datarefs is now shown (make sure X-Plane box is ticked top-left in SPAD window). Select/search “Gear Handle Down”. Information about this dataref is given in the bottom-left section of the SPAD window: XPLANE:SIM/COCKPIT2/CONTROLS/GEAR_HANDLE_DOWN, Unit=BOOL, Usage 0 is up, 1 is down. This dataref (sim/cockpit2/controls/gear_handle_down) is a default XPlane dataref since it is contained in the file ..\X-Plane 11\Resources\plugins \datarefs.txt.
If the dataref.txt file in your aircraft folder would contain a dataref named airfoil/cockpit/switch-thingy, then you could connect this switch-thingy dataref in SPAD.neXt to a control button for your Airfoilabs aircraft.
Start XPlane with you Airfoilabs aircraft, activate the correct profile in SPAD.neXT, select a contoller button ... Change Data Value, then in left-mid selection window (FAVORITES-RECENT-XPLANE) you can even see a full list of all Airfoilabs-specific datarefs.
A very helpful tool in working with datarefs is the freeware XPlane plugin “DataRefTool” (h.. s://github.com/leecbaker/datareftool). With that tool you can examine and export all datarefs of standard and non-standard XPlane 11 aircraft, and then connect every available dataref to a contol button/switch/handle. Enough information on the DataRefToolcan be found on the internet. With this tool you can create a Dataref.txt file with all the non-standard XPlane datarefs for a particular aircraft. Once you have this file, you can connect every available aircraft-specific dataref to a control.