Thanks to visit codestin.com
Credit goes to github.com

Skip to content

I2C ISR: Handle error #73

@BrendanKelly84213

Description

@BrendanKelly84213

code here

    case USCI_I2C_UCSTPIFG:                 // Vector 8: STPIFG
        if (i2cSlaveCtx.i2c_mode == I2C_RX_MODE) {          // Recieve
            ReceiveIndex = 0;
        } else if (i2cSlaveCtx.i2c_mode == I2C_TX_MODE) {   // Transmit
            TransmitIndex = 0;
        } 
        // else {
            // TODO: throw an error. 
        // }

        // Done 
        i2cSlaveCtx.i2c_mode = I2C_IDLE_MODE;
        break;

This TODO has always been here. Would be good to figure out some kind of error to throw.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions