When connected to a modbus device consisting of 10 coils the read coils results are incorrect. With all 10 coils on
the results are True, True, False, False, False, False, False, False, True, True.
When using the Client and server examples simulating 10 coils all turned on the following results are returned:
Client to Server
All 10 coils True returned data 00 01 00 00 00 05 01 01 02 FF 03
Client to MODBUS Device
Coils 1,2,9,10 True 3-8 False returned data 00 01 00 00 00 05 01 01 02 03 FF
The last two bytes are swapped. I believe this is the cause for the readcoils method returning the incorrect result.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
View and moderate all "General Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Discussion"
When connected to a modbus device consisting of 10 coils the read coils results are incorrect. With all 10 coils on
the results are True, True, False, False, False, False, False, False, True, True.
When using the Client and server examples simulating 10 coils all turned on the following results are returned:
Client to Server
All 10 coils True returned data 00 01 00 00 00 05 01 01 02 FF 03
Client to MODBUS Device
Coils 1,2,9,10 True 3-8 False returned data 00 01 00 00 00 05 01 01 02 03 FF
The last two bytes are swapped. I believe this is the cause for the readcoils method returning the incorrect result.
Hi,
i was trying with your values and I did not get any problems. Do you hve some more informations? Screenshots of the client server connection...
Stefan