REXGEN 1REXGEN 2REXGEN 2 IMU GNSSREXGEN AirREXGEN ProDeveloper
REXGEN XML reference: recording (SD) and USB outputs
Choose what the logger records, when recording starts and stops, how files are split and what streams live to REXDESK over USB.
Recording blocks at a glance
The "SD" in these element names is historical. Every REXGEN logger records to internal storage (eMMC). There is no card to insert. Recording uses two kinds of block:
-
SDINTERFACEis the recorder: file size and length, triggers, pre and post-trigger time. The schema allows up to four. -
SDMESSAGEnames one thing to record and theSDINTERFACEthat records it. Add one for each message or sensor block.
If the file has no SDINTERFACE, the logger writes nothing to storage. Live data over USB works the same way: one USBINTERFACE and one USBMESSAGE for each stream. Every block takes a UID attribute (required and unique in the file) and the optional Version, X and Y.
Each entry in the settings lists gives the meaning, then whether the schema requires the element, its type and its default where one exists.
Recorders (SDINTERFACE_LIST)
SDINTERFACE
This recorder records from power-on, starts a new file every 100 MiB or every hour and keeps no pre or post-trigger data.
<SDINTERFACE UID="2">
<MaxLogSize>104857600</MaxLogSize>
<MaxLogTime>3600</MaxLogTime>
<LogFormat>InfluxGeneric1</LogFormat>
<PreLogTime>0</PreLogTime>
<PostLogTime>0</PostLogTime>
<IsPostTimeFromEnableStart>true</IsPostTimeFromEnableStart>
<NumberOfLogs>0</NumberOfLogs>
<IsEnableCreateNewLog>false</IsEnableCreateNewLog>
<InitialEnableState>true</InitialEnableState>
<EnableUID>0</EnableUID>
<DisableUID>0</DisableUID>
<PartitionID>0</PartitionID>
</SDINTERFACE>
MaxLogSize- Maximum size of one log file in bytes. When a file reaches it, the logger starts a new file. For example
104857600(100 MiB). Required. Unsigned int. MaxLogTime- Maximum duration of one log file in seconds. When a file reaches it, the logger starts a new file. For example
3600. Required. Unsigned int. LogFormat- File format of the log. The only allowed value is
InfluxGeneric1. Required. NumberOfLogs- Maximum number of log files the logger creates.
0means no limit other than the storage.1means a single file. Required. Unsigned int. InitialEnableState-
truerecords from power-on.falsewaits for the event named inEnableUID. Required. Boolean. EnableUID- UID of the block whose event starts recording, for example a trigger.
0means none. Optional. Unsigned short. DisableUID- UID of the block whose event stops recording.
0means none. Optional. Unsigned short. -
EnableUID_LIST,DisableUID_LIST - Several start or stop sources, each an
EnableUIDorDisableUIDchild. The example files do not use them. Optional. IsEnableCreateNewLog-
truestarts a new file each time recording is enabled, so every event gets its own file. Required. Boolean. Defaultfalse. PreLogTime- Milliseconds of data from before the enable event that the logger keeps in the file.
0means no pre-trigger data. Required. Unsigned int. PostLogTime- Milliseconds the logger keeps recording after the trigger. Required. Unsigned int.
IsPostTimeFromEnableStart- Where
PostLogTimeis counted from:truefrom the start of the enable event,falsefrom its end. Required. Boolean. PostLogContinuous- When
true, recording continues pastPostLogTimeuntil a size, time or other limit stops it. Optional. Boolean. Defaulttrue. PostLogOnlyOnEnable- When
true, post-trigger recording happens only when recording was explicitly enabled, not in always-on recording. Optional. Boolean. Defaultfalse. PartitionID- Storage partition to write to. The main partition is
0. A value above 0 needs storage formatted with partitions. Use0. Required. Unsigned byte.
How pre and post-trigger time work together
When a trigger enables recording, the logger first adds PreLogTime of buffered data from before the event. It then records through the event and keeps recording for PostLogTime. IsPostTimeFromEnableStart moves the start of that post-trigger count. IsEnableCreateNewLog puts each event in its own file.
The triggers themselves are easiest to build in REXDESK. See REXDESK: start and stop logging with triggers.
What to record (SDMESSAGE_LIST)
SDMESSAGE
Each SDMESSAGE records one block through one recorder. This one, from ADC2CAN_SD.xml, records analogue input block 8 through recorder 2.
<SDMESSAGE UID="18">
<MessageIdentStart>0</MessageIdentStart>
<MessageIdentEnd>4294967295</MessageIdentEnd>
<Direction>OutputPeriodic</Direction>
<DLC>8</DLC>
<IsExtended>false</IsExtended>
<InterfaceUID>2</InterfaceUID>
<Period>0</Period>
<TriggeringMessageUniqueID>0</TriggeringMessageUniqueID>
<DefaultHex>0000000000000000</DefaultHex>
<InputMessageUID>8</InputMessageUID>
</SDMESSAGE>
InputMessageUID- UID of the block to record: a
CANMESSAGE, an analogue, IMU or GNSS block. Required. Unsigned short. InterfaceUID- UID of the
SDINTERFACEthat writes it. Required. Unsigned short. Period- Period in milliseconds. Every example sets
0. Required. Unsigned int. -
MessageIdentStart,MessageIdentEnd - Required by the schema and ignored by the logger. Filter CAN identifiers on the
CANMESSAGEinstead. Use0and4294967295. Unsigned int. Direction- Required by the schema and ignored by the logger. Use
OutputPeriodic. DLC- Required by the schema and ignored by the logger. Use
8. Unsigned byte. IsExtended- Deprecated, still required by the schema. Use
false. Boolean. TriggeringMessageUniqueID- Required by the schema and ignored by the logger. Use
0. Unsigned short. DefaultHex- A default payload, two hexadecimal digits per byte. The examples set
0000000000000000. Optional.
Live data over USB (USBINTERFACE_LIST and USBMESSAGE_LIST)
A USBINTERFACE enables the USB live view, which REXDESK uses to show data while the logger is connected. The schema allows one. It works on models with a USB PC connection: REXGEN 1, REXGEN 2, REXGEN 2 IMU GNSS and REXGEN Air with the factory USB option.
USBINTERFACE
The block has no children, only its attributes.
<USBINTERFACE UID="3"/>
USBMESSAGE
Each USBMESSAGE streams one block. This one, from ADC2CAN_SD.xml, streams analogue input block 8.
<USBMESSAGE UID="20">
<MessageIdentStart>0</MessageIdentStart>
<MessageIdentEnd>4294967295</MessageIdentEnd>
<Direction>OutputPeriodic</Direction>
<DLC>8</DLC>
<IsExtended>false</IsExtended>
<InterfaceUID>3</InterfaceUID>
<Period>0</Period>
<DefaultHex>0000000000000000</DefaultHex>
<InputUID>8</InputUID>
</USBMESSAGE>
InputUID- UID of the block whose data the logger streams, for example a
CANMESSAGEor an analogue block. Required. Unsigned short. InterfaceUID- UID of the
USBINTERFACE. Required. Unsigned short. -
MessageIdentStart,MessageIdentEnd - Range of CAN identifiers to stream, in decimal.
0to4294967295streams everything. Required. Unsigned int. Direction-
Input,OutputEventorOutputPeriodic. The example files useInputfor a CAN message andOutputPeriodicfor sensor values. Required. Period- Transmit period in milliseconds, used only with
OutputPeriodic. Required. Unsigned int. DLC- Data length of the message. The examples set
8. Required. Unsigned byte. IsExtended- Deprecated, still required by the schema. Use
false. Boolean. DefaultHex- A default payload, two hexadecimal digits per byte. Optional.
Putting it together
To record a sensor and stream it, name the sensor block's UID in an SDMESSAGE (record) and in a USBMESSAGE (stream). To send it on the bus as well, name it in a CANSIGNAL too. The "with recording" example files do exactly that. See REXGEN XML examples: GNSS, IMU, analogue and RTC data onto CAN.
To get the recorded files off the logger, see REXDESK: download and export your logs.
Products in this guide
Still stuck?
Our engineers answer support questions on every Influx Technology product.