-
Notifications
You must be signed in to change notification settings - Fork 13.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mpu6000: add & check for the device_type on driver startup
Fixes the following case: a board that has several bus_options enabled, and wants to start a specific device (eg mpu6000 -T 20608 start). In that case the given device_type is never actually checked, and since the start routine iterates over all bus_options, several can match, and thus start multiple instances of the driver (note that the whoami check is performed against the value provided with -T and thus the check will pass). This happens on Pixracer (PX4_SPIDEV_MPU and PX4_SPIDEV_ICM_20608 are both set).
- Loading branch information
Showing
1 changed file
with
15 additions
and
9 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