DCMD_I2C_STATUS

#include <hw/i2c.h>

#define DCMD_I2C_STATUS             __DIOF (_DCMD_I2C, 11, i2c_status_t)

The arguments to devctl() are:

Argument Value
filedes A file descriptor that you obtained by opening the device.
dcmd DCMD_I2C_STATUS
dev_data_ptr A pointer to an i2c_status_t
n_bytes sizeof(i2c_status_t)
dev_info_ptr NULL

The DCMD_I2C_STATUS command gets the status of the device.

Input
None.
Output
The status; one of:
I2C_STATUS_DONE
The transaction completed (with or without an error).
I2C_STATUS_ERROR
An unknown error occurred.
I2C_STATUS_NACK
Slave no-acknowledgement.
I2C_STATUS_ARBL
Lost arbitration.
I2C_STATUS_BUSY
The transaction timed out.
I2C_STATUS_ABORT
The transaction was aborted.