DCMD_I2C_MASTER_SEND (deprecated)

The DCMD_I2C_MASTER_SEND command execute a master send transaction, using the slave device address and bus speed specified for the current connection.

Input
  • i2c_masterhdr_t — the message header:
    typedef struct {
        uint32_t len;    /* length of data to send/recv, in bytes
                            (not including this header) */
        uint32_t stop;   /* send stop when complete? (0=no, 1=yes) */
    } i2c_masterhdr_t;
          
    
  • uint8_t[] — the data buffer
Output
None.

If an error occurs, the command returns:

EIO
The master send failed. Causes include: bad slave address, bad bus speed, bus is busy.
EFAULT
An error occurred while accessing the data buffer.
EINVAL
Bad message format.
ENOMEM
Insufficient memory.
EPERM
The master is locked by another connection.