This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

我用的是F28377s,官网下载的controlSUIT,底层驱动从里面调用的,按道理用没有错误,但是编译之后出现了如下错误,希望熟悉F28X系列的大佬指点一下,谢谢!

Other Parts Discussed in Thread: CONTROLSUITE

Problem:

Description Resource Path Location Type
#20 identifier "CanaRegs" is undefined F2837xS_can.c /My_test/drv/source line 32 C/C++ Problem

F2837XS_can.c中的代码:

......

CanaRegs.CAN_CTL.bit.Init = 1;  //这句报错!

......

F2837XS_Can_defines.h中的代码:

#define CAN_CTL_INIT 0x00000001 // Initialization
#define CAN_CTL_IE0 0x00000002 // Interrupt Enable 0
#define CAN_CTL_SIE 0x00000004 // Status Interrupt Enable
#define CAN_CTL_EIE 0x00000008 // Error Interrupt Enable
#define CAN_CTL_DAR 0x00000020 // Disable Automatic-Retransmission
#define CAN_CTL_CCE 0x00000040 // Configuration Change Enable
#define CAN_CTL_TEST 0x00000080 // Test Mode Enable
#define CAN_CTL_IDS 0x00000100 // Interruption Debug Support Enable
#define CAN_CTL_ABO 0x00000200 // Auto-Bus On Enable
#define CAN_CTL_PMD_S 10
#define CAN_CTL_PMD_M 0x00003C00 // Parity/SECDED Enable
#define CAN_CTL_SWR 0x00008000 // Software Reset Enable
#define CAN_CTL_INITDBG 0x00010000 // Debug Mode Status
#define CAN_CTL_IE1 0x00020000 // Interrupt Enable 1
#define CAN_CTL_PDR 0x01000000 // Power Down Mode Request
#define CAN_CTL_WUBA 0x02000000 // Wake Up on Bus Activity

应该已经定义了啊,为什么错误显示未定义?