You can create custom variables when you need a suitable variable name for your device mapping configuration. For instance, you could use it when you need a variable for a custom purpose or when you need it for your own language.
How to create a new custom variable
1. Go to SiteAdmin > Devices > Variables page.
On this page ,you can see the overview of custom variables.
2. In the last row, you can fill in the details (Name, Description, Type, Unit) of the new variable you are adding.
Type: select Double, String, Boolean depending on what kind of value will you store in this new variable. Typically:
Double: anything that stores a number or "something that could be measured" like any analog signal (fuel level, temperature, speed, etc).
String: anything that stores a string of characters (for example, RFID or iButton that sends the "driver identification number)
Boolean: stores a signal that can only handle two states (true/false, 0/1, etc). For example: door open, lights on, SOS, etc.
3. Click the Save button.
How to use the custom variable
The new variable will be available in the Device Mapper in the application for any device type selected.
1. Select Admin > Device Mappers
2. Select your device from the list
3. Go to 3.Mappings
4. Select the Input and your new variable
Note: your new variable will show if it matches the type of input you're selecting.
Check which type you selected when creating the variable.
Export-Import your custom variables
Custom variables can also be exported and imported in case of backup or server migration.
Exporting custom variables
To backup your custom variables, follow these steps:
1. Go to Site Admin > Devices > Variables
2. Scroll down to the bottom of your variables list.
3. Click Export Template
Now a file message_fields.xml will be downloaded into your computer.
Importing custom variables
To import your custom variables, follow these steps:
1. Go to Site Admin > Import
2. Select Templates from the list.
3. Select the message_fields.xml file downloaded from the import step.
Now your variables should be listed under Devices > Variables.