From 677449b520088413afd0ce9e443a68cb87fa3236 Mon Sep 17 00:00:00 2001 From: Wolfgang Draxinger Date: Wed, 23 Nov 2011 21:24:09 +0100 Subject: retry_count variable initialisation and increment _was_ missing. --- Phytron.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Phytron.py b/Phytron.py index 7ea0d28..1679f80 100644 --- a/Phytron.py +++ b/Phytron.py @@ -311,11 +311,13 @@ class IPCOMM: self.conn.flushInput() self.send( ('%X' % ID) + cmd ) + retry_count = 0 while not recv_data and retry_count < self.max_retry_count: try: recv_data = self.recv() except ReceiveChecksumError: self.send( ('%X' % ID) + 'R') + retry_count += 1 if recv_data.status.rx_error: extended_status = self.queryextendedstatus(ID).data -- cgit v1.2.3