AZSG

I am working on a project and I was mapping out the coils/registers etc to memory addresses for reading vi modbus TCP.
Is it possible to read IW IX memory via modbus TCP?
Using modbus TCP to read coils/registers, it appears 0-799 for coils and 0-1023 for registers (Holding Registers), but discrete  input registers 0-799 and input registers 0-1023 are not readable?

Thanks in advance for your help.

Quote 0 0
AZSG

I think I figured it out. The client I was using doesn't have a query for function code 4 defined.  I think that is used for reading input registers.

https://www.modbustools.com/modbus.html#function04

Quote 0 0
thiagoralves
Inputs, coils and registers are all accessible through modbus according to this table: http://www.openplcproject.com/scada
Quote 1 0
AZSG

Thanks, I figured it out. I didn't have the correct function code and was just reading the holding registers and not the discrete.

Function Code - Function

01 - READ COIL STATUS

02 - READ INPUT STATUS

03 - READ HOLDING REGISTERS

04 - READ INPUT REGISTERS

05 - WRITE SINGLE COIL

06 - WRITE SINGLE REGISTER

15 - WRITE MULTIPLE COILS

16 - WRITE MULTIPLE REGISTERS

Quote 0 0