2023-02-23 05:53 PM
hello.
I've never used STM32 before.
I'm trying to use it this time. It requires several pins of GPIO and 3 channels of I2C.
I searched and the STM32F301 seemed suitable, so I designed a circuit using it.
I tried setting the PIN using a setting tool called CUBEMX, but there seems to be something wrong.
If I set up I2C3 of STM32F301 using cubemx, exclamation marks appear on all I2C channels.
can i know what is the problem?
Solved! Go to Solution.
2023-02-23 08:44 PM
You can ignore the exclamation marks on I2C1 and I2C2 as long as you are using all 3 I2Cs in I2C mode.
The exclamation marks are just a warning to inform you that due to potential conflicts with some other peripherals, the peripherals showing the exclamation marks might have some limitations in their usage.
For instance, with the 3 I2Cs selected, once you select I2C3 in I2C mode, it prevents using I2C1 and/or I2C2 in SMBus-Alert mode. You can see that by scrolling down the list of mode selection for I2C1/2, you will see the SMBus-Alert-mode is in purple color meaning it cannot be used unless you resolve the conflict.
2023-02-23 08:29 PM
If the chip has in its block diagram 3 I2C HW IP cell, you can have 3 I2C bus run concurrently, as long as the proper SW is developped. Same for SPI or USART.
IMHO, one solution I would think of is to create a printer-like spooler for each one of them, queuing the I2C bus requested messages and callbacks. This could be implemented as an interrupt-based state machine. This is not provided as default much simpler provided examples.
2023-02-23 08:44 PM
You can ignore the exclamation marks on I2C1 and I2C2 as long as you are using all 3 I2Cs in I2C mode.
The exclamation marks are just a warning to inform you that due to potential conflicts with some other peripherals, the peripherals showing the exclamation marks might have some limitations in their usage.
For instance, with the 3 I2Cs selected, once you select I2C3 in I2C mode, it prevents using I2C1 and/or I2C2 in SMBus-Alert mode. You can see that by scrolling down the list of mode selection for I2C1/2, you will see the SMBus-Alert-mode is in purple color meaning it cannot be used unless you resolve the conflict.
2023-02-23 08:49 PM
Thank you for the reply.
The diagram for the STM32F301 shows 3 I2C's.
Before the PCB artwork, I only looked at the datasheet and wondered if I had properly assigned the functions to the pins, so I only set the pins in advance.
However, a 'conflict' message occurred.
If this message occurs, can I not use 3 I2C at the same time?
The signal specified as IPMI should operate as a slave, so an interrupt method will be used, but the rest will be used as polling as needed.
2023-02-24 01:49 AM
thank you It helped a lot. :)