Page 1 of 1

I2C with STM32l432kc

Posted: Thu Dec 01, 2022 12:28 pm
by Iraton
I need to connect 2 i2c device on my board and the pinout of the board show me that he as i2c on pin PA_9/PA_10 and PB_7/PB_6, but when i do the i2c scanner only the second one recognize the i2c, why? It's normal that only one i2c works or I'm doing something wrong?

Re: I2C with STM32l432kc

Posted: Thu Dec 01, 2022 12:50 pm
by fpiSTM
If it is a nucleo32 check the schematic. I guess you have some SB to rework.

Re: I2C with STM32l432kc

Posted: Thu Dec 01, 2022 1:03 pm
by Iraton
Yes is a nucleo32 but could you be more explanatory? I don't know what you're talking about

Re: I2C with STM32l432kc

Posted: Thu Dec 01, 2022 4:09 pm
by fpiSTM
I talk about Soldier Bridge. Read the user manual or the schematic of the bord to see if pins you used are correct.

Re: I2C with STM32l432kc

Posted: Fri Dec 02, 2022 8:15 am
by fpiSTM
Just think about your first post:
PA_9/PA_10 and PB_7/PB_6
This is the pinName. You have to use PA9/PA10 and PB7/PB6 which are the pin number used at sketch level.
Moreover they are both on the same I2C: I2C1. So if you want 2 differents I2C at same time. You should connect all I2C peripherals on the same or use the I2C3 IP.

About pins and schematics with SB:
l432KC.png
l432KC.png (22.17 KiB) Viewed 1258 times
As you can see PB6/PB7 are available twice due to SB configurations.