From 0ff6929bbc732b5682f9fb40609d4942f6d53f8a Mon Sep 17 00:00:00 2001 From: Oleg Kalachev Date: Tue, 2 Apr 2024 20:43:31 +0300 Subject: [PATCH] Separate 9250 and 9255 detection messages --- MPU9250.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/MPU9250.cpp b/MPU9250.cpp index 064bfa7..c3c60ec 100644 --- a/MPU9250.cpp +++ b/MPU9250.cpp @@ -74,9 +74,11 @@ bool MPU9250::begin() { if (who_am_i_ == WHOAMI_MPU6500_) { // disable AK8963 functions is_mpu6500_ = true; - log("MPU6500 detected"); - } else if ((who_am_i_ == WHOAMI_MPU9250_) || (who_am_i_ == WHOAMI_MPU9255_)) { - log("MPU9250 detected"); + log("MPU-6500 detected"); + } else if (who_am_i_ == WHOAMI_MPU9250_) { + log("MPU-9250 detected"); + } else if (who_am_i_ == WHOAMI_MPU9255_) { + log("MPU-9255 detected"); } else { log("Unknown WHO_AM_I: 0x%02X", who_am_i_); return false;