24.03.2023, 08:13
I want to use the modbus configuration file on the LM to control the 485 slave device
"My requirement is that the mapped switch address' 1/1/1 'implements a write command to register 23. When the switch value is true, write 0xAAAA to address 23, and when the switch value is false, write 0x5555 to address 23.".
How should I change the ". json" file below to meet my requirements (without writing a script to implement it).
"My requirement is that the mapped switch address' 1/1/1 'implements a write command to register 23. When the switch value is true, write 0xAAAA to address 23, and when the switch value is false, write 0x5555 to address 23.".
How should I change the ". json" file below to meet my requirements (without writing a script to implement it).
Code:
...
{ "name": "on_off", "bus_datatype": "bool", "type": "register", "writable": 1, "address": 23, "value_custom": { "0": "off","1": "on" } },
...