Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update icm40609d #23539

Merged
merged 3 commits into from
Aug 14, 2024
Merged

Update icm40609d #23539

merged 3 commits into from
Aug 14, 2024

Conversation

jlaitine
Copy link
Contributor

Adds a fix for ICM40609D interrupt (DRDY) driven mode, and cleanups for FIFO handling.

Without the first patch in this set, the DRDY mode is not working at all.

Tested on custom HW, using the sensor both in DRDY and polling mode, by using perf, listener and uorb top. Checked that values are sane, there are no extra errorsr in "perf" and uorbs are published at the desired rate.

If DRDY signal is used, the interrupt status needs to be cleared at FIFO reset
in order to make DRDY go back inactive. Otherwise there won't be a falling edge
interrupt at the next sample.

Signed-off-by: Jukka Laitinen <[email protected]>
Disable I2C to make sure that the sensor doesn't switch to that by accident

Signed-off-by: Jukka Laitinen <[email protected]>
As the sensor can directly report the amount of samples in the fifo, use it to simplify the logic.

Also combine the fifo empty/fifo overflow checks for interrupt and polling modes.

Signed-off-by: Jukka Laitinen <[email protected]>
@dagar dagar merged commit 0459481 into PX4:main Aug 14, 2024
90 of 91 checks passed
@jlaitine jlaitine deleted the update_icm40609d branch August 14, 2024 07:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants