2024-08-07 01:31 AM
Adapter Board | Arduino | |
1 | VDD | 3.3V |
2 | GND | GND |
3 | SCL | SCL |
4 | SDA | SDA |
5 | CS - VDDIO | |
6 | SDO | 3.3V |
The adapter board is mounted on a DIL 24 pin socket, which is then placed on a breadboard.
What am I doing wrong? I want to read and use the IMU readings, any suggestions on how I can do this any other way?
2024-08-07 05:14 AM
Recheck your assumptions, it should work.
Are there external pullups on the I2C lines? Can you look at the waveform? Perhaps show a picture of the setup. Is the chip powered appropriately? Can the Arduino detect a different I2C device?
2024-08-07 05:47 AM
There are no external pullups. do i need to add any?
The Arduino can detect other I2C devices, just not this one. I've added pictures of my set-up below, the code i used was just the Arduino Playground code for an I2C scanner (https://playground.arduino.cc/Main/I2cScanner/)
2024-08-07 06:00 AM - edited 2024-08-07 06:00 AM
I2C needs external resistors somewhere. If it's working with other devices, perhaps those devices have pullups, but yes they need to be present somewhere.
It's possible they're on the adapter board. I didn't look for a schematic.
2024-08-07 06:03 AM
AtMega is 5V device, likely you need "logic level converter"
2024-08-09 09:33 AM
The I2C is working now, the scanner is able to find the IMU device at address 0x6B as it should. I changed my breadboard and it started working, so I guess the connections were bad the first time.
I have another issue now.. when I run the scanner it finds the I2C device at 6B but it also says 'Unknown error at address 0x7E '. The IMU (with the adapter board) is the only device connected to the Arduino. What could the 7E be referring to?
2024-08-09 09:51 AM
My thought too. With the wealth of 3V3 Arduino boards available in that universe, why use an ATMEGA at 5V ?
VDDIO on the MEGA's hard wired to 5V, and SDA/SCL will be pulled to that too.
2024-08-09 10:50 AM
Perhaps consult the documentation of the scanner tool for what that error message means. Means nothing to me, it's not an STM32 convention.