/** ################################################################### ** Filename : CAN.C ** Project : CAN ** Processor : MC9S08DZ60CLH ** Version : Driver 01.11 ** Compiler : CodeWarrior HCS08 C Compiler ** Date/Time : 7/17/2008, 2:30 PM ** Abstract : ** Main module. ** This module contains user's application code. ** Settings : ** Contents : ** No public methods ** ** Copyright: 1997 - 2009 Freescale Semiconductor, Inc. All Rights Reserved. ** ** http : www.freescale.com ** mail : support@freescale.com ** ###################################################################*/ /* MODULE CAN */ /* Including needed modules to compile this module/procedure */ #include "Cpu.h" #include "Events.h" #include "Term1.h" #include "Inhr1.h" #include "CAN1.h" /* Include shared modules, which are used for whole project */ #include "PE_Types.h" #include "PE_Error.h" #include "PE_Const.h" #include "IO_Map.h" #define CAN_MSG_ID 1 #define CAN_TX_BUFF 0 byte LoopTxBuffer[CAN_MSG_LEN]; byte LoopRxBuffer[CAN_MSG_LEN]; byte i, err, frameType, frameFormat, msgLen; volatile byte OnFreeTxBuffer = 0; volatile byte OnFullRxBuffer = 0; dword msgID; bool cmpFailed; void main(void) { /* Write your local variable definition here */ /*** Processor Expert internal initialization. DON'T REMOVE THIS CODE!!! ***/ PE_low_level_init(); /*** End of Processor Expert internal initialization. ***/ /* Write your code here */ Term1_SendStr("CAN test");Term1_CRLF(); // for (i=0;i