Clean up
This commit is contained in:
parent
bdf3e427cc
commit
f84dd400ed
@ -85,11 +85,16 @@ def parseMsg(payload):
|
|||||||
https://docs.python.org/2/library/struct.html
|
https://docs.python.org/2/library/struct.html
|
||||||
'''
|
'''
|
||||||
|
|
||||||
charAry, val1, val2, val3 = parsedStruct.unpack_from(arr)
|
charAry, val1, val2, val3 = parsedStruct.unpack_from(arr) #convert byte array to formatted struct
|
||||||
charAry = charAry.rstrip(' \t\r\n\0') #remove trailing white space from buffer
|
charAry = charAry.rstrip(' \t\r\n\0') #remove trailing white space from buffer
|
||||||
return charAry, val1, val2, val3
|
return charAry, val1, val2, val3
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
"""Wait for incoming message published by Adafruit MQTT client"""
|
"""Wait for incoming message published by Adafruit MQTT client"""
|
||||||
global args
|
global args
|
||||||
|
Loading…
Reference in New Issue
Block a user