2025-02-26 12:57 PM
Hi.
I'm working on a project using I2C on the U545, and I've noticed that all the HAL_I2C_Slave_* functions include the following:
/* Enable Address Acknowledge */
hi2c->Instance->CR2 &= ~I2C_CR2_NACK;
However, the STM32U5 Reference manual states that writing 0 to this bit has no effect.
Many of these functions also set this bit before exiting with the comment "Disable Address Acknowledge", however the RM also states that an Address match will cause the bit to be cleared by hardware.
What is going on?