Skip to content

Commit 1f8d732

Browse files
author
Myles Metzler
committed
fix modbus rtu packe pause for watlowF4T issues.
1 parent 1de8cba commit 1f8d732

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

chamberconnectlibrary/modbus.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,14 +182,16 @@ def __init__(self, address, port, **kwargs):
182182
#watlow suggests using 0.012 char send time for buads greater than 19200
183183
databits, stopbits = kwargs.get('databits', 8), kwargs.get('stopbits', 1)
184184
baud = kwargs.get('baud', 9600)
185-
self.pause = 3.5 * (((databits + stopbits + 2)/ baud) if baud < 19200 else 0.012)
185+
# calculated pause time does not work on the Watlow F4T, using watlow recomended delay...
186+
#self.pause = 3.5 * (((databits + stopbits + 2)/ baud) if baud < 19200 else 0.012)
187+
self.pause = 0.012
186188
self.serial = serial.Serial(
187189
port=port,
188190
baudrate=baud,
189191
bytesize=databits,
190192
parity=kwargs.get('parity', 'N'),
191193
stopbits=stopbits,
192-
timeout=kwargs.get('timeout', 2)
194+
timeout=kwargs.get('timeout', 1)
193195
)
194196

195197
def __del__(self):

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ def readme():
55
return f.read()
66

77
setup(name='chamberconnectlibrary',
8-
version='1.1.3',
8+
version='1.1.4',
99
description='A library for interfacing with Espec North America chambers',
1010
long_description=readme(),
1111
url='https://github.com/EspecNorthAmerica/ChamberConnectLibrary',

0 commit comments

Comments
 (0)