-
Notifications
You must be signed in to change notification settings - Fork 818
docs: 2144 - ctrehan/2144 #2662
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,7 +25,7 @@ public SensorList() { | |
sensorList.put(0x5A, new String[]{"MLX90614 PIR temperature"}); | ||
sensorList.put(0x1E, new String[]{"HMC5883L magnetometer", "LSM303 magnetometer"}); | ||
sensorList.put(0x77, new String[]{"BMP180/GY-68 altimeter", "MS5607", "MS5611"}); | ||
sensorList.put(0x68, new String[]{"MPU-6050/GY-521 accel+gyro+temp", "ITG3200", "DS1307", "DS3231"}); | ||
sensorList.put(0x69, new String[]{"MPU-6050/GY-521 accel+gyro+temp", "ITG3200", "DS1307", "DS3231"}); | ||
sensorList.put(0x69, new String[]{"ITG3200"}); | ||
Comment on lines
+28
to
29
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. issue (bug_risk): Conflicting entries for key 0x69 in sensorList could result in inadvertent data loss. The first mapping for 0x69 (associating multiple sensor names including MPU-6050) is being overwritten by the second mapping (only "ITG3200") because map keys must be unique. Please double-check the intended sensor addressing to ensure both sets of sensor identifications are preserved or differentiated. |
||
sensorList.put(0x76, new String[]{"MS5607", "MS5611"}); | ||
sensorList.put(0x6B, new String[]{"LSM9DSO gyro"}); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
issue (bug_risk): Duplicate key mapping for 0x69 in sensorAddr may lead to unintended overrides.
Both MPU6050 and MPU925x are mapped to the same I2C address key (0x69), which means the latter mapping will overwrite the earlier one. It’s important to verify whether these devices should share the same address or if a distinct address or strategy (such as separate maps or composite values) is required.