From abb79103162af2b7437c7a82f1c88d7fb1abfb68 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Sun, 14 Apr 2024 12:33:22 -0400 Subject: bulk_sensor: Rework ChipClockUpdater class into FixedFreqReader Move the sensor_bulk_data message queuing into the class, and then rename that class. This simplifies the users of the code. Signed-off-by: Kevin O'Connor --- klippy/extras/lis2dw.py | 30 ++++++++++-------------------- 1 file changed, 10 insertions(+), 20 deletions(-) (limited to 'klippy/extras/lis2dw.py') diff --git a/klippy/extras/lis2dw.py b/klippy/extras/lis2dw.py index 96b7db76..3f17c1f4 100644 --- a/klippy/extras/lis2dw.py +++ b/klippy/extras/lis2dw.py @@ -49,11 +49,9 @@ class LIS2DW: mcu.add_config_cmd("query_lis2dw oid=%d rest_ticks=0" % (oid,), on_restart=True) mcu.register_config_callback(self._build_config) - self.bulk_queue = bulk_sensor.BulkDataQueue(mcu, oid=oid) - # Clock tracking + # Bulk sample message reading chip_smooth = self.data_rate * BATCH_UPDATES * 2 - self.clock_updater = bulk_sensor.ChipClockUpdater(mcu, chip_smooth, - "