pyhys / minimalmodbus

Easy-to-use Modbus RTU and Modbus ASCII implementation for Python.
Apache License 2.0
308 stars 145 forks source link

I want to know how much delay can be achieved in continuous reading and writing. #34

Closed leytonxu closed 5 years ago

leytonxu commented 6 years ago

When I tried to read and write registers, I found that it would report errors when "time.sleep()" is too short.

ssshah86 commented 6 years ago

It is dependent on your baud_rate. There must be 3.5 character silent period, see here.

The clocks on your slave and master may not be synchronized so this is a minimum. You can also try running and testing lower sleep times until you achieve the performance desired. Good luck.

pyhys commented 5 years ago

In next release the sleep time will be increased for some of the higher baud rates. See #25.