Skip to content

Commit

Permalink
Merge pull request #101 from Jalle19/unit-type
Browse files Browse the repository at this point in the history
Read unit type from the correct register
  • Loading branch information
Jalle19 authored Jan 17, 2024
2 parents b494729 + 217d213 commit 56a6464
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Change log

## future release

* Fix reading from unit type from wrong register (https://github.com/Jalle19/eda-modbus-bridge/issues/100)

## 2.7.0

* Change Home Assistant auto-discovery log level to `debug` (https://github.com/Jalle19/eda-modbus-bridge/issues/93)
Expand Down
2 changes: 1 addition & 1 deletion app/modbus.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ export const getDeviceInformation = async (modbusClient) => {
'fanType': result.data[0] ? 'EC' : 'AC',
}

result = await mutex.runExclusive(async () => tryReadCoils(modbusClient, 72, 1))
result = await mutex.runExclusive(async () => tryReadCoils(modbusClient, 51, 1))
const unitType = getUnitTypeName(result.data[0])
deviceInformation = {
...deviceInformation,
Expand Down

0 comments on commit 56a6464

Please sign in to comment.