1 | initial version |
The Modbus dissector does just the same as a Modbus master when communicating with a slave, it assumes that a response matches the previous request as defined in the protocol.
As Modbus has no notion of the "semantic" values of the registers transferred from the slave to the master, the interpretation of registers as volts or amps is entirely down to the Modbus master application and the Modbus slave configuration.
One issue you may come across when looking at Modbus in a Wireshark capture is that the protocol itself uses 0-based addressing for registers, but many PLC configuration tools and master applications use 1-based addressing. The conversion between the offsets is handled in the software being used. This means that a read of the input register 30001 is actually transmitted as a read input registers command for starting address 0.