TMS320F28P650SK: 程序运行多次后进入ILLEGAL_ISR

Part Number: TMS320F28P650SK


我的是关于电机控制的程序,在程序进行多次电机启停测试后进入了ILLEGAL_ISR,在进入ILLEGAL_ISR前,发现一些变量会变成不确定的值,这是我配置的。cmd文件

{
   BEGIN            : origin = 0x0A0000, length = 0x000002  // Update the codestart location as needed

   BOOT_RSVD        : origin = 0x000002, length = 0x0001AF     /* Part of M0, BOOT rom will use this for stack */
   RAMM0            : origin = 0x0001B1, length = 0x00024F
   RAMM1            : origin = 0x000400, length = 0x000400

   RAMD0            : origin = 0x00C000, length = 0x002000
   RAMD1            : origin = 0x00E000, length = 0x002000
   RAMD2            : origin = 0x01A000, length = 0x002000  // Can be mapped to either CPU1 or CPU2. When configured to CPU2, use the address 0x8000. User should comment/uncomment based on core selection
   RAMD3            : origin = 0x01C000, length = 0x002000  // Can be mapped to either CPU1 or CPU2. When configured to CPU2, use the address 0xA000. User should comment/uncomment based on core selection
   RAMD4            : origin = 0x01E000, length = 0x002000  // Can be mapped to either CPU1 or CPU2. When configured to CPU2, use the address 0xC000. User should comment/uncomment based on core selection
   RAMD5            : origin = 0x020000, length = 0x002000  // Can be mapped to either CPU1 or CPU2. When configured to CPU2, use the address 0xE000. User should comment/uncomment based on core selection

。。。。

   codestart        : > BEGIN
   .text            : > FLASH_APPA, ALIGN(8)
   .cinit           : > FLASH_APPA, ALIGN(8)
   .switch          : > FLASH_APPA, ALIGN(8)
   .reset           : > RESET, TYPE = DSECT /* not used, */
   .blt_mb          : > RAMM0, type = NOINIT, ALIGN(4)

   .stack           : > RAMM1

停止时候的寄存器值:

image.png