From 461e08db19b576243cecce19b2bdf6aef0cdc19c Mon Sep 17 00:00:00 2001 From: Jannik Zander Date: Fri, 10 Jun 2016 00:20:03 +0200 Subject: [PATCH] Minor update --- .local/bin/gf.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.local/bin/gf.py b/.local/bin/gf.py index 59a424d..44090af 100755 --- a/.local/bin/gf.py +++ b/.local/bin/gf.py @@ -88,7 +88,6 @@ def process(line): global t global speed global master - # Some extra info from logging tool isok=process_isok(line) timestamp=process_timestamp(line) @@ -96,19 +95,22 @@ def process(line): timezero=timestamp # Process received data typ,ds,le,da,sa,line=process_head(line) + numbytes=le-2 if da==0xF7: - numbytes=le-2 while numbytes>0: cl,os,ale,line=process_apdu(line) - numbytes=numbytes-2-ale + numbytes=numbytes-2 if cl==5: id,val,line=process_class5(line,int(ale/2)) + numbytes=numbytes-ale + # Debugging info.... t=t+[timestamp-timezero] master=master+[1+(sa-31)/10] for i in range(4): speed[i]=speed[i]+[val[i]/254] else: line=line[ale*3:] + numbytes=numbytes-ale crc=process_crc(line) return -- 2.43.0