ARM-software / CMSIS-Driver

Repository of microcontroller peripheral driver implementing the CMSIS-Driver API specification

Home Page:https://arm-software.github.io/CMSIS-Driver/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

i2c multi slave acknowledge polling

bart112233 opened this issue · comments

commented

For acknowledge polling after write command (ex. 24AA02E48 - for waiting write operation done ) is need to call MasterTransmit with params data=NULL and num=0. But implementation of I2C_MasterTransmit in I2C_MultiSlave.c don't allow this case.

Hi,

for this particular device you could implement a workaround by sending 1 byte using MasterTransmit. That extra byte would serve as a dummy Word Address. As a consequence read operations would need to specify (re-set) Word Address again after each write operation.

I agree this is not optimal, but it should work. Do you know other practical use cases for calling MasterTransmit using data = NULL and num = 0?

commented

Hi,

24AA02E48 have one byte length addresses - i will check your method, thanks.

No, i don't know any other practical usage of this case - only for eeprom ack poll.

Were you able to solve the problem using suggested workaround?

commented

Yes, your method works. Many thanks for you help.