The issue
The component code needs a complete refactoring.
- Currently, the code cannot be considered thread-safe because the mutex is only acquired/released during individual register reads/writes, whereas there are functions that perform multiple register writes.
- In most places where a register value is written and the same value is stored in the descriptor, the descriptor is updated FIRST, and only then the register write is performed without checking the result. This could potentially lead to a situation where the value in the descriptor differs from the actual register value.
Which SDK are you using?
esp-idf
Which version of SDK are you using?
latest
Which build target have you used?
Component causing the issue
bmi160
Anything in the logs that might be useful for us?
Additional information or context
No response
Confirmation
The issue
The component code needs a complete refactoring.
Which SDK are you using?
esp-idf
Which version of SDK are you using?
latest
Which build target have you used?
Component causing the issue
bmi160
Anything in the logs that might be useful for us?
Additional information or context
No response
Confirmation