@@ -189,13 +189,14 @@ def events(self) -> Dict[str, bool]:
189
189
| Key | Description |
190
190
+============+============================================================================+
191
191
| ``tap`` | True if a tap was detected recently. Whether it's looking for a single |
192
- | | or double tap is determined by the tap param of `enable_tap_detection` |
192
+ | | or double tap is determined by the tap param of |
193
+ | | :meth:`adafruit_adxl34x.enable_tap_detection` |
193
194
+------------+----------------------------------------------------------------------------+
194
195
| ``motion`` | True if the sensor has seen acceleration above the threshold |
195
- | | set with ` enable_motion_detection`. |
196
+ | | set with :meth:`adafruit_adxl34x. enable_motion_detection` |
196
197
+------------+----------------------------------------------------------------------------+
197
198
| ``data_ready`` | True if the sensor has data to be read. Can be used for more precise |
198
- | | timing if reading many samples |
199
+ | | timing if reading many samples. Set with `enable_data_ready_interrupt` |
199
200
+------------+----------------------------------------------------------------------------+
200
201
201
202
@@ -238,3 +239,10 @@ def enable_data_ready_interrupt(self):
238
239
active_interrupts |= _INT_DATA_READY
239
240
self ._write_register_byte (_REG_INT_ENABLE , active_interrupts )
240
241
self ._enabled_interrupts ["data_ready" ] = True
242
+
243
+ def disable_data_ready_interrupt (self ) -> None :
244
+ """Disable Data Ready interrupt"""
245
+ active_interrupts = self ._read_register_unpacked (_REG_INT_ENABLE )
246
+ active_interrupts &= ~ _INT_DATA_READY
247
+ self ._write_register_byte (_REG_INT_ENABLE , active_interrupts )
248
+ self ._enabled_interrupts .pop ("data_ready" )
0 commit comments