i2c_m_os_enable

Enable hardware.

int32_t i2c_m_os_enable(
    struct i2c_m_os_desc *const i2c
)

This function enables the I2C master device and then waits for this enabling operation to be done

Parameters

i2c

Type: struct i2c_m_os_desc Struct *const

An I2C master descriptor, which is used to communicate through I2C

Returns

Type: int32_t

The status whether successfully enable the device

-1

The passed parameters were invalid or the device enable failed

0

The hardware enabling is completed successfully