Interfacing Razor 9dof M0 IMU with ESP32

Hi, I’m using an old Razor 9dof IMU and I can’t get it to send serial data to my ESP32 board to create a dead reckoning device. I’ve checked the baud rates, set up the firmware on the setup page to send data through HARDWARE instead of USBVIRTUAL, and believe that my code doesn’t have too much issue, unless I’m doing it all wrong. How should I go about fixing this? Thanks!

Looks like a typo in line 4?

Line 4 is commented out though? I assigned the actual pin values in the UART initialization instead of using the RX2 TX2 values.

Doh, I had never seen comment blocks in arduino

You might need the flash storage library too 9DoF Razor IMU M0 Hookup Guide - SparkFun Learn to be able to save the settings, and finally there’s a an example for this if you scroll up 1 page from here 9DoF Razor IMU M0 Hookup Guide - SparkFun Learn

I have the library and followed all the instructions for setting up the UART connection, but it’s still not detecting if the channel is open or not. I’m wondering if I need to write my own firmware for the IMU instead of using the default one? Is there anything that looks wrong on the ESP32’s end?

This is what the output is looking like on the ESP32’s end, I’m using PlatformIO with the above written code for the ESP and the original firmware from the hookup guide.