csuffyy / nmodbus

Automatically exported from code.google.com/p/nmodbus
0 stars 0 forks source link

RTU slave doesn't check received modbus command for CRC #21

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Setup a modbus master (RTU) which first sends a "bonus" character to 
the RTU slave. 
2. Wait a while, e.g. 10 sec.
3. From the modbus master send a proper modbus message to the slave

What is the expected output? What do you see instead?
I would expect to see the slave to ignor the "bonus" character or to 
discard the message due to an invalid CRC

What I see instead is that the slave will decode the message starting from 
the "bonus" character. From this point on the slave is not longer 
synchronized and all modbus messages sent to the slave will fail. After 
sending 7 "bonus" characters more the slave will respond again.

What version of the product are you using? On what operating system?
Windows XP

Please provide any additional information below.

Problem came to light due to ill behaving hardware. A rs-232 analyzer 
showed a "bonus" character was send.

Original issue reported on code.google.com by k.a.van....@gmx.net on 30 Nov 2007 at 7:18

GoogleCodeExporter commented 9 years ago
Thanks for the bug. I have a fix ready to go out w/ the next release, hopefully 
this
weekend.

Scottt

Original comment by sja...@gmail.com on 2 Dec 2007 at 1:30

GoogleCodeExporter commented 9 years ago

Original comment by sja...@gmail.com on 3 Dec 2007 at 3:54