mirror of
https://github.com/lumapu/ahoy.git
synced 2025-05-16 10:26:10 +02:00
Update ahoy.py decode cmd=131
CMD 131 seem to contain temperatures
This commit is contained in:
parent
3eb3ada916
commit
141d53ff9c
1 changed files with 11 additions and 0 deletions
|
@ -163,6 +163,17 @@ def on_receive(p):
|
|||
d['wday2_Wh'] = uk5
|
||||
d['uk2'] = uk2
|
||||
|
||||
elif cmd==131:
|
||||
name = 'statedata'
|
||||
uk1, uk2, uk3, uk4, uk5, uk6 = struct.unpack('>HHHHHH', p[10:22])
|
||||
print(f'uk1={uk1}, ', end='')
|
||||
print(f'uk2={uk2}, ', end='')
|
||||
print(f'uk3={uk3}, ', end='')
|
||||
print(f'uk4={uk4}, ', end='')
|
||||
print(f'uk5={uk5}, ', end='')
|
||||
print(f'uk6={uk6}')
|
||||
d['t_C'] = uk4/10
|
||||
|
||||
else:
|
||||
print(f'unknown cmd {cmd}')
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue