Skip to content
This repository has been archived by the owner on Oct 29, 2019. It is now read-only.

Commit

Permalink
Merge pull request #9 from adafruit/microbuilder-patch-1
Browse files Browse the repository at this point in the history
Removed erroneous 4-bit shift
  • Loading branch information
ladyada authored Oct 12, 2018
2 parents 2a299cb + 38ab491 commit 66c17e3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions adafruit_lsm303.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,7 @@ def raw_magnetic(self):
"""
self._read_bytes(self._mag_device, _REG_MAG_OUT_X_H_M, 6, self._BUFFER)
raw_values = struct.unpack_from('>hhh', self._BUFFER[0:6])
values = tuple([n >> 4 for n in raw_values])
return (values[0], values[2], values[1])
return (raw_values[0], raw_values[2], raw_values[1])

@property
def magnetic(self):
Expand Down

0 comments on commit 66c17e3

Please sign in to comment.