Other Parts Discussed in Thread: C2000WARE
Tool/software:
I have code for sending data via CAN, and it builds and runs successfully in Code Composer Studio. In the expression window, I can see the data. However, when I connect the designated pin on the TMS320F280025C board to a logic analyzer as shown in the diagram, no data is visible on the analyzer.
Do I need to make any changes in Code Composer Studio or check specific settings on the logic analyzer to view the data?//
//
//
#include "device.h"
#include "driverlib.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
#define TX_MSG_OBJ_ID 1
#define MSG_DATA_LENGTH 8
uint16_t txMsgData_1[8]={0x11,0x12,0x23,0x84,0x75,0x16,0x37,0x28};
void main(void)
{
Device_init();
Device_initGPIO();
GPIO_setPinConfig(DEVICE_GPIO_CFG_CANRXA);
GPIO_setPinConfig(DEVICE_GPIO_CFG_CANTXA);
CAN_initModule(CANA_BASE);
CAN_setBitRate(CANA_BASE, DEVICE_SYSCLK_FREQ, 500000, 16);
CAN_setupMessageObject(CANA_BASE, TX_MSG_OBJ_ID, 0x18FB47FF,
CAN_MSG_FRAME_EXT, CAN_MSG_OBJ_TYPE_TX, 0,
CAN_MSG_OBJ_NO_FLAGS, MSG_DATA_LENGTH);
CAN_startModule(CANA_BASE);
EINT;
while(1)
{
CAN_sendMessage(CANA_BASE, TX_MSG_OBJ_ID, MSG_DATA_LENGTH, txMsgData_1);
while(((HWREGH(CANA_BASE + CAN_O_ES) & CAN_ES_TXOK)) == CAN_ES_TXOK)
{
}
DEVICE_DELAY_US(1000000);
}
}
