Hi,
I'm trying to get the CAN-bus up running on a Hercules development board (LaunchPad RM42x). I only want to transmit data via CAN1 to a Tranceiver.
For INIT in Halogen:
a. CAN1 Driver is enabled in Driver Enable
b. CAN interrupt ISR is mapped correct in VIM RAM
c. Enabled CAN high or low INT in VIM channel 0-31 and 31-62
Code Composer Studio:
#include "sys_common.h"
#include "system.h"
/* USER CODE BEGIN (1) */
#include "can.h"
/* Include ESM header file - types, definitions and function declarations for system driver */
#include "esm.h"
#define D_SIZE 1
uint8 tx_data[D_SIZE] = {0x11};
/* USER CODE BEGIN (2) */
/* USER CODE END */
void main(void)
{
/* initialize can 1 */
canInit();
/* transmit on can1 */
canTransmit(canREG1, canMESSAGE_BOX1, tx_data);
/* ... run forever */
while(1);
/* USER CODE END */
}
/* USER CODE BEGIN (4) */
/* USER CODE END */
It seems like the data is never send from CAN1. I'am new in this forum and need help.
Best regards
Dennis