...
Address format of I/O tag:
Address format is [I|U|L|Ll|S|Sl|f|F|C|D]Fn.Address[.BitNr] in which:
- The first optional character defines the type of I/O tag:
- I - Integer 16 bit
- U - Unsigned 16 bit (default)
- L - Unsigned long (4 bytes = 2 registers) - two registers with Address and Address+1 are read, unsigned and transmitted as big-endian (see Note)
- Ll - Unsigned long (4 bytes = 2 registers) - two registers with Address and Address+1 are read and transmitted as little-endian, unsigned (see Note)
- S - Signed long (4 bytes = 2 registers) - two registers with Address and Address+1 are read, signed and transmitted as big-endian (see Note)
- Sl - Signed long (4 bytes = 2 registers) - two registers with Address and Address+1 are read and transmitted as little-endian, signed (see Note)
- f - Float 32 bit (two registers) in big endian format (bytes B4, B3, B2, B1 will be sent, B4 is highest byte and B1 is lowest byte of float)
- F - Float 32 bit (two registers) in little endian format (bytes B2, B1, B4, B3 will be sent, B4 is highest byte and B1 is lowest byte of float)
- C - Request counter up (16 bit unsigned, which is incremented by every read request). Works only for Fn=3 or Fn=4
- D - Request counter down (16 bit unsigned, which is decremented by every read request). Works only for Fn=3 or Fn=4
Note: Request counter up/down can be used to configure a "watchdog" I/O tag to monitor status and speed of Modbus communication.
- Parameter Fn is a function of Modbus protocol for data reading, which inserts I/O tag into proper address space:
- 1 - Coils: binary statuses
- 2 - Discrete Inputs: binary inputs
- 3 - Holding Registers: status registers
- 4 - Input Registers: input registers
- Parameter Address is 2-bytes address of register in the range of 0 up to 65535.
- Parameter BitNr optionally specifiec a bit of register in the range of 0 upto 15.
...
- Ver. 1.0 - April 24th, 2009 - document creating
- Ver. 1.1 - November 21st, 2010 - document update.
- Ver. 1.2 - November 11th, 2011 - document update.
- Ver. 1.3 - July 22th, 2019 - Implementation of signed/unsigned long values (L, Ll, S, Sl)
Info | ||
---|---|---|
| ||
...