adafruit-circuitpython-mlx90393 2.1.3__py3-none-any.whl → 2.1.5__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {adafruit_circuitpython_mlx90393-2.1.3.dist-info → adafruit_circuitpython_mlx90393-2.1.5.dist-info}/METADATA +1 -1
- adafruit_circuitpython_mlx90393-2.1.5.dist-info/RECORD +6 -0
- {adafruit_circuitpython_mlx90393-2.1.3.dist-info → adafruit_circuitpython_mlx90393-2.1.5.dist-info}/WHEEL +1 -1
- adafruit_mlx90393.py +8 -8
- adafruit_circuitpython_mlx90393-2.1.3.dist-info/RECORD +0 -6
- {adafruit_circuitpython_mlx90393-2.1.3.dist-info → adafruit_circuitpython_mlx90393-2.1.5.dist-info}/LICENSE +0 -0
- {adafruit_circuitpython_mlx90393-2.1.3.dist-info → adafruit_circuitpython_mlx90393-2.1.5.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,6 @@
|
|
1
|
+
adafruit_mlx90393.py,sha256=94HFAZMsbNy57SV6Qqu8HqYeUofThg6hT1_PmbHrpzE,18326
|
2
|
+
adafruit_circuitpython_mlx90393-2.1.5.dist-info/LICENSE,sha256=WeIXVkYWpdba3Boxrax8dB0s5qWg9GTxl7c5uTZQDUI,1105
|
3
|
+
adafruit_circuitpython_mlx90393-2.1.5.dist-info/METADATA,sha256=2nUZH8DTMICjwDfcj6eP-8cg3Pd6fpHpMP9aljAU4Qk,4085
|
4
|
+
adafruit_circuitpython_mlx90393-2.1.5.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
5
|
+
adafruit_circuitpython_mlx90393-2.1.5.dist-info/top_level.txt,sha256=5RT_YbHfXFo2Y6zVvz8MXsZLIHm1OxrjFJrzRaCTdNY,18
|
6
|
+
adafruit_circuitpython_mlx90393-2.1.5.dist-info/RECORD,,
|
adafruit_mlx90393.py
CHANGED
@@ -28,6 +28,7 @@ Implementation Notes
|
|
28
28
|
https://github.com/adafruit/Adafruit_CircuitPython_Register
|
29
29
|
|
30
30
|
"""
|
31
|
+
|
31
32
|
import struct
|
32
33
|
import time
|
33
34
|
|
@@ -36,12 +37,13 @@ from micropython import const
|
|
36
37
|
|
37
38
|
try:
|
38
39
|
from typing import Tuple
|
39
|
-
|
40
|
+
|
40
41
|
from busio import I2C
|
42
|
+
from circuitpython_typing import ReadableBuffer
|
41
43
|
except ImportError:
|
42
44
|
pass
|
43
45
|
|
44
|
-
__version__ = "2.1.
|
46
|
+
__version__ = "2.1.5"
|
45
47
|
__repo__ = "https://github.com/adafruit/Adafruit_CircuitPython_MLX90393.git"
|
46
48
|
|
47
49
|
_CMD_SB = const(0b00010000) # Start burst mode
|
@@ -406,15 +408,12 @@ class MLX90393: # pylint: disable=too-many-instance-attributes
|
|
406
408
|
|
407
409
|
:param int reg: The register to read
|
408
410
|
"""
|
409
|
-
#
|
411
|
+
# Read register
|
410
412
|
payload = bytes([_CMD_RR, reg << 2])
|
411
|
-
with self.i2c_device as i2c:
|
412
|
-
i2c.write(payload)
|
413
|
-
|
414
|
-
# Read the response (+1 to account for the mandatory status byte!)
|
415
413
|
data = bytearray(3)
|
416
414
|
with self.i2c_device as i2c:
|
417
|
-
i2c.
|
415
|
+
i2c.write_then_readinto(payload, data)
|
416
|
+
|
418
417
|
# Unpack data (status byte, big-endian 16-bit register value)
|
419
418
|
self._status_last, val = struct.unpack(">BH", data)
|
420
419
|
if self._debug:
|
@@ -446,6 +445,7 @@ class MLX90393: # pylint: disable=too-many-instance-attributes
|
|
446
445
|
"""
|
447
446
|
Performs a software reset of the sensor.
|
448
447
|
"""
|
448
|
+
self._transceive(bytes([_CMD_EX]))
|
449
449
|
if self._debug:
|
450
450
|
print("Resetting sensor")
|
451
451
|
time.sleep(2)
|
@@ -1,6 +0,0 @@
|
|
1
|
-
adafruit_mlx90393.py,sha256=hXPJ-VXZMig5jPGBhv2OpfiL7sspWOE1SI-8l3uZQcM,18430
|
2
|
-
adafruit_circuitpython_mlx90393-2.1.3.dist-info/LICENSE,sha256=WeIXVkYWpdba3Boxrax8dB0s5qWg9GTxl7c5uTZQDUI,1105
|
3
|
-
adafruit_circuitpython_mlx90393-2.1.3.dist-info/METADATA,sha256=uDj53jv1VlKQuUTfpmgXm6bVL91rLdUXyheDdZ5NtfM,4085
|
4
|
-
adafruit_circuitpython_mlx90393-2.1.3.dist-info/WHEEL,sha256=oiQVh_5PnQM0E3gPdiz09WCNmwiHDMaGer_elqB3coM,92
|
5
|
-
adafruit_circuitpython_mlx90393-2.1.3.dist-info/top_level.txt,sha256=5RT_YbHfXFo2Y6zVvz8MXsZLIHm1OxrjFJrzRaCTdNY,18
|
6
|
-
adafruit_circuitpython_mlx90393-2.1.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|