Manual slave address ACK is different with a read than with a write. This is because of the generation of the DATA_REQUEST bit and the need to write to TXBUF right after the address is received.
Here is the sequence diagram:
- The SLAVE_ADDR_RDY BIT is set tSAR ns after the falling edge of the clock for the R/W bit of the address.
- The firmware reads from the PMBST register, clearing the SLAVE_ADDR_RDY bit. Next the firmware reads the address from the RXBUF, using only the low 7 bits – the most significant bit is random and must be masked out.
- The firmware writes to the ACK bit. If a 1 is written, the DATA_REQUEST bit will be set tDREQ2 ns after the ACK bit is set.
- The firmware reads the PMBST register, clearing the DATA_REQUEST bit.
- Then the firmware writes the appropriate outgoing data into the TXBUF register, after first making sure that the TX_COUNT bits reflect the correct number of bytes. Any clock stretch will be cleared tTXWRITE ns after the write to TXBUF. If the firmware is fast enough, no clock stretch will occur.
- Once the ACK is over, the ACK bit will be cleared, and the TXBUF will be moved into the shift register for transmission.
After the manual slave ACK, the rest of the read will continue as described in the sequences above.