From 84a0d163867f19ddbd03c2a185854548c14af0d6 Mon Sep 17 00:00:00 2001 From: Bob Long Date: Fri, 19 Jul 2019 09:52:38 -0400 Subject: [PATCH] Clarify weird behavior of the LIS3MDL See issue #12514 --- src/drivers/magnetometer/lis3mdl/lis3mdl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/drivers/magnetometer/lis3mdl/lis3mdl.cpp b/src/drivers/magnetometer/lis3mdl/lis3mdl.cpp index 6ab5e22bc786..ba75e887def4 100644 --- a/src/drivers/magnetometer/lis3mdl/lis3mdl.cpp +++ b/src/drivers/magnetometer/lis3mdl/lis3mdl.cpp @@ -361,8 +361,8 @@ LIS3MDL::collect() ret = _interface->read(ADDR_OUT_X_L, (uint8_t *)&lis_report, sizeof(lis_report)); /** - * Weird behavior: the X axis will be read instead of the temperature registers if you use a pointer to a packed struct...not sure why. - * This works now, but further investigation to determine why this happens would be good (I am guessing a type error somewhere) + * Silicon Bug: the X axis will be read instead of the temperature registers if you do a sequential read through XYZ. + * The temperature registers must be addressed directly. */ ret = _interface->read(ADDR_OUT_T_L, (uint8_t *)&buf_rx, sizeof(buf_rx));