Bugfix unexpected Reply from xlactor

This commit is contained in:
2018-02-20 11:19:31 +01:00
parent 93c519ea05
commit 90e2f2cf36

View File

@@ -136,10 +136,13 @@ class CanListener (can.Listener):
#State requeset
elif infotype [_info_type] == 'state':
_sendecho = 0 #No Echo on State telegram
sdata = _data.decode("utf-8", "ignore")
if self.waitackst [_address]:
self.log ("Echo fuer Status erhalten", 3)
self.waitackst [_address] = 0
_sendecho = 0
elif ('MEL' in sdata) or ('GESP' in sdata) or ('UNBE' in sdata):
self.log ("unerwartetes Echo fuer Status erhalten", 3)
else:
animalnr = int (_data)
self.log ("Statusanfrage fuer Tiernummer %d" % animalnr)