MicroMod ML board + nRF52840 + ICM 20948

Hello,

I have a problem using the ICM 20948 inside PlatformIO.

Hardware Setup: MicroMod ML carrier board + nRF52840 processor board + ICM 20948

Software tools: Arduino IDE and Visual Code with PlatformIO

When I upload the example Example1_Basics using the Arduino IDE, I get :

Scaled. Acc (mg) [ -00003.42, 00000.98, 01043.95 ], Gyr (DPS) [ 00001.53, -00000.29, 00000.91 ], Mag (uT) [ -00033.75, 00007.20, 00025.20 ], Tmp (C) [ 00025.54 ]

Scaled. Acc (mg) [ 00010.25, -00006.35, 01041.50 ], Gyr (DPS) [ 00002.85, -00000.05, 00002.42 ], Mag (uT) [ -00034.50, 00006.30, 00025.20 ], Tmp (C) [ 00025.73 ]

However, if I upload the same example using Platformio, I get:

Initialization of the sensor returned: Data Underflow

Trying again…

In Arduino IDE and PlatformIO the MicroMod board is recognized ad Arduino Nano 33 BLE.

Is the board definition different between Arduino IDE and PlatformIO.

Any suggestions are welcome.

Thanks for the feedback.

Regards,

Joeri

While we don’t generally use Platform IO, the fact that the regular Arduino IDE is working point to perhaps a library issue or settings issues in Platform IO - here’s the library they have posted for the ICM 20948 https://platformio.org/lib/show/6352/Sp … %20Library - I would check that, and double-check the COM selection as well (makes sure it’s using the same COM port as the Arduino IDE)

Best of luck!

The solution (thanks to maxgerhardt)

https://community.platformio.org/t/micr … rmio/22128

Hey. I am using MSP430FR5994 for this sparkfun Arduin ICM libraries. I am getting these errors.

erbose mode can be enabled via -v, --verbose option

CONFIGURATION: https://docs.platformio.org/page/boards … r5994.html

PLATFORM: TI MSP430 (2.3.0) > TI LaunchPad MSP-EXP430FR5994LP

HARDWARE: MSP430FR5994 16MHz, 4KB RAM, 256KB Flash

DEBUG: Current (mspdebug) On-board (mspdebug)

PACKAGES:

  • framework-energiamsp430 1.10810.210219 (1.8.10)

  • toolchain-timsp430 1.40603.210219 (4.6.3)

LDF: Library Dependency Finder → http://bit.ly/configure-pio-ldf

LDF Modes: Finder ~ chain, Compatibility ~ soft

Found 19 compatible libraries

Scanning dependencies…

Dependency Graph

|-- <SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library> 1.2.7

| |-- 1.0.0

| |-- 1.0.1

Building in release mode

Compiling .pio\build\lpmsp430fr5994\lib07b\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\util\ICM_20948_C.c.o

.pio\libdeps\lpmsp430fr5994\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\src\util\ICM_20948_C.c: In function ‘inv_icm20948_set_gyro_sf’:

.pio\libdeps\lpmsp430fr5994\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\src\util\ICM_20948_C.c:2526:65: internal compiler error: in msp430_expand_mul, at config/msp430/msp430.c:1705

Please submit a full bug report,

with preprocessed source if appropriate.

See <http://gcc.gnu.org/bugs.html> for instructions.

*** [.pio\build\lpmsp430fr5994\lib07b\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\util\ICM_20948_C.c.o] Error 1

========================================================================================== [FAILED] Took 2.62 seconds ==========================================================================================The terminal process “C:\Users\TARUN KARAK.platformio\penv\Scripts\platformio.exe ‘run’, ‘–environment’, ‘lpmsp430fr5994’” terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

Executing task in folder TI_MSP_ICM1: C:\Users\TARUN KARAK.platformio\penv\Scripts\platformio.exe run --environment lpmsp430fr5994 <

Processing lpmsp430fr5994 (platform: timsp430; board: lpmsp430fr5994; framework: arduino)

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via -v, --verbose option

CONFIGURATION: https://docs.platformio.org/page/boards … r5994.html

PLATFORM: TI MSP430 (2.3.0) > TI LaunchPad MSP-EXP430FR5994LP

HARDWARE: MSP430FR5994 16MHz, 4KB RAM, 256KB Flash

DEBUG: Current (mspdebug) On-board (mspdebug)

PACKAGES:

  • framework-energiamsp430 1.10810.210219 (1.8.10)

  • toolchain-timsp430 1.40603.210219 (4.6.3)

LDF: Library Dependency Finder → http://bit.ly/configure-pio-ldf

LDF Modes: Finder ~ chain, Compatibility ~ soft

Found 19 compatible libraries

Scanning dependencies…

Dependency Graph

|-- <SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library> 1.2.7

| |-- 1.0.0

| |-- 1.0.1

Building in release mode

Compiling .pio\build\lpmsp430fr5994\lib07b\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\util\ICM_20948_C.c.o

.pio\libdeps\lpmsp430fr5994\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\src\util\ICM_20948_C.c: In function ‘inv_icm20948_set_gyro_sf’:

.pio\libdeps\lpmsp430fr5994\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\src\util\ICM_20948_C.c:2526:65: internal compiler error: in msp430_expand_mul, at config/msp430/msp430.c:1705

Please submit a full bug report,

with preprocessed source if appropriate.

See <http://gcc.gnu.org/bugs.html> for instructions.

*** [.pio\build\lpmsp430fr5994\lib07b\SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library\util\ICM_20948_C.c.o] Error 1