Question
How is receiving of a i2c byte initiated?
Posted on June 27, 2014 at 04:05
Hi, I would like te receive 3 Bytes. Therefore I am sending a start, the I2C address of the slave, the register address, a repeated start, the slaveaddress again, then I receive the 3 bytes and finish wish a stop. So far so good.
I can see code which is initiating the start condition (I2Cx->CR1 |= I2C_CR1_START;) I can see code which sends bytes (I2Cx->DR = Address;) In the manual I can see, that writing is automatically started when writing to the dr register. but: how is receiving initiated? In which register do I have to write to in order to start the receiving of a byte?