mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-21 21:58:05 -06:00
adxl345: Fix read_axes_map() for non-adxl345 accelerometers
Commit 3f845019
unified the reading of the axes_map configuration
variable, but broke the per-sensor scaling capabilities. Pass the
scale parameters to read_axes_map() so that it can be implemented
per-sensor.
Reported by @Neko-vecter.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
7b490f3ec1
commit
d8d072b375
3 changed files with 6 additions and 6 deletions
|
@ -37,7 +37,7 @@ class LIS2DW:
|
|||
def __init__(self, config):
|
||||
self.printer = config.get_printer()
|
||||
adxl345.AccelCommandHelper(config, self)
|
||||
self.axes_map = adxl345.read_axes_map(config)
|
||||
self.axes_map = adxl345.read_axes_map(config, SCALE, SCALE, SCALE)
|
||||
self.data_rate = 1600
|
||||
# Setup mcu sensor_lis2dw bulk query code
|
||||
self.spi = bus.MCU_SPI_from_config(config, 3, default_speed=5000000)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue