18.6.3.8.1 Function i2c_slave_read_packet_job()
Initiates a reads packet operation.
enum status_code i2c_slave_read_packet_job( struct i2c_slave_module *const module, struct i2c_slave_packet *const packet)
Reads a data packet from the master. A write request must be initiated by the master before the packet can be read.
The I2C_SLAVE_CALLBACK_WRITE_REQUEST callback can be used to call this function.
Data direction | Parameter name | Description |
---|---|---|
[in, out] |
module |
Pointer to software module struct |
[in, out] |
packet |
Pointer to I2C packet to transfer |
Returns
Status of starting asynchronously reading I2C packet.
Return value | Description |
---|---|
STATUS_OK |
If reading was started successfully |
STATUS_BUSY |
If module is currently busy with another transfer |