# Editing the configuration

You can edit the configuration on the user interface or load it from a JSON file. Once the configuration has been changed, the Apply and the Cancel buttons are displayed.

## ATTENTION

Each variable is mapped to one Modbus register (16 bit) only. If, e. g., a 32-bit variable is mapped to a Modbus register, the upper 16 bits will be truncated.

Use discrete_input or input_register to read the value of a global variable from the real-time application. Use coil or holding_register to write to a global variable in the real-time application. When reading a coil or holding_register the mapped global variable of the real-time application will have the value last written to this register. Initially this will be zero.

If you rename a global variable in your project, you must change the name of the variable in the configuration accordingly.

1. Enter the desired value in the Update interval text box.

2. The update interval indicates the frequency in which the Modbus registers are updated or read.

3. A range of 10 ... 10000 ms is supported by the Modbus TCP server. If you enter a value outside this range, it will be changed to the nearest boundary value at runtime.

4. Click Add.
5. Select a Modbus object type from the drop-down list.
6. The Modbus object type is added to the table in a new row.
7. In the Address column, enter the register address.

8. Each address can only be assigned once per Modbus object type.

9. In the Global variable column, enter the name of the global variable.

After editing, the changes to the configuration must be applied to become effective.

To edit the configuration in a JSON file, enter Modbus object type, address, global variable and update interval as shown in the example below. The update interval in the file is given in µs.