Missing the first 2 bytes after WRITE_SINGLE_REGISTER

96 views
Skip to first unread message

theangusschmaloer

unread,
Dec 4, 2017, 9:55:45 AM12/4/17
to modbus-tk
Hey,
I am implementing ModbusRTU op my stm32 and i am using the rtumaster_example.py.

I have tested my Modbus Slave with the different function.
It all works fine, except when i use:
logger.info(master.execute(1, cst.WRITE_SINGLE_REGISTER, 50, output_value=54)).

Every commando after that one had a CRC error, my calculated CRC did not correspond with the received bytes.
I tried switching the functions around, but it still didn't work.
i looked at the whole string my uart received and there i saw that the string misses the first two bytes, the slave address and the function number.

Greetings,
Angus Schmaloer
Reply all
Reply to author
Forward
0 new messages