Platform/ECM3532/M3/hw/csp/ecm3532/m3/csp/src/eta_csp_i2c.c
/***************************************************************************/
/**
 *
 * EtaCspI2cLineClear - Triggers an I2C clearing event to clear any residual commands
 *                      issued before a soft reset
 *
 * @param iNum I2C instance number
 * @return Return the status.
 *
 ******************************************************************************/
Triggers an I2C clearing event to clear any residual commands
issued before a soft reset

@param iNum I2C instance number
@return Return the status.
Triggers an I2C clearing event to clear any residual commands issued before a soft reset @param iNum I2C instance number @return Return the status .
tEtaStatus
EtaCspI2cLineClear(tI2cNum iNum)
{
    tEtaStatus iResult;
    REGN_M1(iNum, I2C_CONFIG, IGNORE_NACK, 1);
    REG_I2C_TXRX_1BYTE_FIFO_DATA(iNum).V = 0xff;
    REG_I2C_TXRX_1BYTE_FIFO_DATA(iNum).V = 0xff;
    REG_I2C_CMD_FIFO_DATA(iNum).V = I2C_CMD_STOP;
    REGN_W1(iNum, I2C_STATUS, START_BUSY, 1);
    iResult = EtaCspI2cDonePoll(iNum);
    if(iResult != eEtaSuccess)
    {
        return(iResult);
    }
    REGN_M1(iNum, I2C_CONFIG, IGNORE_NACK, 0);
     Return the result.
    return(iResult);
}
tEtaStatus EtaCspI2cLineClear ( tI2cNum iNum ) { tEtaStatus iResult ; REGN_M1 ( iNum , I2C_CONFIG , IGNORE_NACK , 1 ) ; REG_I2C_TXRX_1BYTE_FIFO_DATA ( iNum ) . V = 0xff ; REG_I2C_TXRX_1BYTE_FIFO_DATA ( iNum ) . V = 0xff ; REG_I2C_CMD_FIFO_DATA ( iNum ) . V = I2C_CMD_STOP ; REGN_W1 ( iNum , I2C_STATUS , START_BUSY , 1 ) ; iResult = EtaCspI2cDonePoll ( iNum ) ; if ( iResult != eEtaSuccess ) { return ( iResult ) ; } REGN_M1 ( iNum , I2C_CONFIG , IGNORE_NACK , 0 ) ; return ( iResult ) ; }
EtaCspI2cLineClear - Triggers an I2C clearing event to clear any residual commands
                      issued before a soft reset
EtaCspI2cLineClear - Triggers an I2C clearing event to clear any residual commands issued before a soft reset
// // Return the result. //