Skip to content

Commit

Permalink
Fix boiler load sensor.
Browse files Browse the repository at this point in the history
  • Loading branch information
denpamusic committed Nov 14, 2023
1 parent 4477744 commit 37ec98b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pyplumio/structures/load.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@ def decode(
if load == BYTE_UNDEFINED:
return ensure_dict(data), offset

return (ensure_dict(data, {ATTR_LOAD: message[offset]}), offset)
return (ensure_dict(data, {ATTR_LOAD: load}), offset)
4 changes: 2 additions & 2 deletions tests/testdata/messages/sensor_data.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"items": [
"0755F7B15420BE5698FA3601003802003901003D18310000000000FF0300000900D012B34101F",
"FFFFFFF02FFFFFFFF03FFFFFFFF04FFFFFFFF05FFFFFFFF060000000007FFFFFFFF08FFFFFFFF",
"29002D800020000000000000000000000000000001120B3A4B01FFFFFFFF120A4801022800050",
"29002D800020000000000010000000000000000001120B3A4B01FFFFFFFF120A4801022800050",
"20300002E42000048420200000E420000000005FFFFFFFF28000800FFFFFFFF28000800FFFFFF",
"FF28000800FFFFFFFF280008000000A04128000800"
],
Expand Down Expand Up @@ -57,7 +57,7 @@
"fuel_level": 32,
"transmission": 0,
"fan_power": 0.0,
"load": 0,
"load": 16,
"power": 0.0,
"fuel_consumption": 0.0,
"thermostat": 1,
Expand Down

0 comments on commit 37ec98b

Please sign in to comment.