Skip to content

Commit

Permalink
Fixes re appending of checksum to constant command values.
Browse files Browse the repository at this point in the history
  • Loading branch information
fdobrovolny committed Apr 22, 2023
1 parent 09274b2 commit 473fa82
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/mh_zxx/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ def _write_command(self, command: List[int]):
"""
Write command to the sensor.
"""
command.append(self._checksum(command))
self.serial.write(command)
self.serial.write(command + [self._checksum(command)])

def _read_response(self) -> bytes:
"""
Expand Down

0 comments on commit 473fa82

Please sign in to comment.