Skip to content

Commit

Permalink
Clarify weird behavior of the LIS3MDL
Browse files Browse the repository at this point in the history
See issue #12514
  • Loading branch information
robertlong13 authored and mhkabir committed Jul 21, 2019
1 parent b71bae4 commit 84a0d16
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/drivers/magnetometer/lis3mdl/lis3mdl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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));

Expand Down

0 comments on commit 84a0d16

Please sign in to comment.