Revision: 3674
Author:
peter.h...@gmail.com
Date: Sun Aug 2 20:05:39 2015 UTC
Log: Branch MatrixPilot_wjp_helicalTurns: Flight Analyzer: Fix bug in
treament of hexadecimal flags that denote status of MatrixPilot
https://code.google.com/p/gentlenav/source/detail?r=3674
Modified:
/branches/MatrixPilot_wjp_helicalTurns/Tools/flight_analyzer/matrixpilot_lib.py
=======================================
---
/branches/MatrixPilot_wjp_helicalTurns/Tools/flight_analyzer/matrixpilot_lib.py
Thu Mar 12 08:36:15 2015 UTC
+++
/branches/MatrixPilot_wjp_helicalTurns/Tools/flight_analyzer/matrixpilot_lib.py
Sun Aug 2 20:05:39 2015 UTC
@@ -1190,10 +1190,10 @@
return "Error"
else :
pass
- match = re.match(".*:fgs([-0-9]*?):",line) # flags from
defines.h
+ match = re.match(".*:fgs([A-F0-9]*?):",line) # flags from
defines.h; Match hex letters
if match :
try:
- self.flags = int(match.group(1))
+ self.flags = int(match.group(1),16) # Interpret as
base 16 hex
except:
print "Corrupt flag values in line", line_no
return "Error"