int canEvents(struct can_api* c, double absTime, double relTime, ISRInfo *i) { switch (i->msg) { case EV2PRG_RECEIVED: TRACE("Data received and placed in i\n"); break; case EV2PRG_RECEIVED_STD: TRACE("Data received and placed in i\n CAN Identifier has Standard Frame Format\n"); break; case EV2PRG_RECEIVED_EXT: TRACE("Data received and placed in i\n CAN Identifier has Extended Frame Format\n"); break; case EV2PRG_TRANSMIT: TRACE("Data transmitted and placed in i\n"); break; case EV2PRG_TRANSMIT_STD: TRACE("Data transmitted and placed in i\n CAN Identifier has Standard Frame Format\n"); break; case EV2PRG_TRANSMIT_EXT: TRACE("Data transmitted and placed in i\n CAN Identifier has Extended Frame Format\n"); break; case EV2PRG_BUSERROR: TRACE("Bus error occured\n"); break; case EV2PRG_WARNING: TRACE("Warning error occured\n"); break; case EV2PRG_PASSIVE: TRACE("Passive error occured\nSJA1000 is now passive\n"); break; case EV2PRG_ARBITRATION: TRACE("Arbitration error occured\n"); break; case EV2PRG_WAKEUP: TRACE("Wakeup occured\n"); break; case EV2PRG_OVERRUN: TRACE("Overrun occured\nSome messages are lost\n"); break; } return 0; }