Double NAK - additional byte transmitted in I2C read sequence - STM32F401
Hi Everyone!
My STM32F401 MCU is a master for communication with an I2C device which requires to write 3 bytes and than read 2 bytes. This cycle repeats each 50 ms. Each cycle includes:
- Check presence of the slave device using HAL_I2C_IsDeviceReady
- Write 3 bytes with HAL_I2C_Master_Transmit_DMA
- Short delay for some other operations
- Check presence of the slave device using HAL_I2C_IsDeviceReady
- Read 2 bytes using HAL_I2C_Master_Receive_DMA
Most of the time every thing works as expected, here is a single cycle:

However, randomly (at least I have not seen any pattern) STM generated additional byte transfer in the read sequence, after a NAK has been already generated. The abnormality is the double NAK and than a STOP condition.

I am assuming the STM is generating additional clocks, based on the unchanged analog signal characteristics. Would very much appreciate any help, did any one encountered such behavior before?
Regards
