18.6.3.8.2 Function i2c_slave_write_packet_job()

Initiates a write packet operation.

enum status_code i2c_slave_write_packet_job( struct i2c_slave_module *const module, struct i2c_slave_packet *const packet)

Writes a data packet to the master. A read request must be initiated by the master before the packet can be written.

The I2C_SLAVE_CALLBACK_READ_REQUEST callback can be used to call this function.

Table 18-35. Parameters
Data directionParameter nameDescription

[in, out]

module

Pointer to software module struct

[in, out]

packet

Pointer to I2C packet to transfer

Returns

Status of starting writing I2C packet.

Table 18-36. Return Values
Return valueDescription

STATUS_OK

If writing was started successfully

STATUS_BUSY

If module is currently busy with another transfer