-
Notifications
You must be signed in to change notification settings - Fork 6.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drivers: sensor: bmi08x: fix interfaceand trigger
1. Temperature Interface According to BMI08x datasheet, temperature reading requires both MSB and LSB bytes to be read and processed correctly. Temp data processing should follow the formula: Temp in °C = (temp_msb * 8) + (temp_lsb / 32) This patch implements the correct reading sequence and calculation method as specified in the datasheet. 2. Trigger Setting Previously we set handler and then trigger struct. However under some situation, as long as we set the handler, we get into ISR immediately and never set trigger struct. I simply changed the sequence. Testing: - Verified temperature readings match datasheet - Tested on stm32f407igh board with BMI08x sensor Fixes: #82375 Signed-off-by: Wenxi Xu <xuwenxi0517@gmail.com>
- Loading branch information
Showing
3 changed files
with
30 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters