Tool/software: Code Composer Studio
I'm developing on a TMS320C5535 using the XDS110 debugger, the C5000 chip support library, and Code Composer version: 8.2.0.00007. I enter into my function:
CSL_Status my_Function(CSL_SpiHandle hSpi,
Uint16 frame_len,
char *ATcmd,
Uint8 *pAT_CmdParam,
XB_action action)
{
if ( frame_len < NUM_CONST_BYTES_4 ){
return (CSL_ESYS_INVPARAMS);
}
CSL_Status status = CSL_ESYS_FAIL;
Uint16 cmdParam_len = frame_len - NUM_CONST_BYTES_4;
Uint16 buff_len = frame_len + NUM_CONST_BYTES_4;
Uint8 *Tx = (Uint8 *)malloc(sizeof(Uint8) * buff_len);
memset(Tx, 0x00, sizeof(Uint8) * buff_len); // Init the array
Uint16 Tx_Idx = 0;
Uint16 byteCtr;
.
.
.
as soon as step into line 7 of this function, I get the following error:
C55xx: Trouble Reading Memory Block at 0x150005 on Page 1 of Length 0x1: (Error -1143 @ 0x150004) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x150005 on Page 1 of Length 0x1: (Error -1143 @ 0x150004) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x150006 on Page 1 of Length 0x1: (Error -1143 @ 0x150006) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x150007 on Page 1 of Length 0x1: (Error -1143 @ 0x150006) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x150008 on Page 1 of Length 0x1: (Error -1143 @ 0x150008) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x150009 on Page 1 of Length 0x1: (Error -1143 @ 0x150008) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x15000a on Page 1 of Length 0x1: (Error -1143 @ 0x15000A) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x15000b on Page 1 of Length 0x1: (Error -1143 @ 0x15000A) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x15000c on Page 1 of Length 0x1: (Error -1143 @ 0x15000C) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x15000d on Page 1 of Length 0x1: (Error -1143 @ 0x15000C) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6) C55xx: Trouble Reading Memory Block at 0x15000e on Page 1 of Length 0x1: (Error -1143 @ 0x15000E) Device core was hung. The debugger has forced the device to a ready state and recovered debug control, but your application's state is now corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 8.0.903.6)
I'm not sure why I'm getting this error. I double checked my command linker file and used view->memory allocation to check that there is enough space in RAM and it seems to be okay. I'm not using a GEL file, but I've initialized PPL, LDO, EBSR, and my GPIO registers and have successfully ran other programs using these same initializations, so I don't think initializing my peripherals is the problem either.
Lastly, I checked the memory map:
Program: Start Addr = 0x0, End Addr = 0x7FFFFFFFFFF...
Data: Start Addr = 0x0, End Addr = 0x7FFFFFFFFFF...
IO: Start Addr = 0x0, End Addr = 0x7FFFFFFFFFF...
I'm not sure if the memory map is the problem, or what GEL file to even use if I need it. Any guidance and advice would be greatly appreciated!