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.
Tool/software: Code Composer Studio
Hi,
I am facing a weird issue when trying to debug a TMS320F28377D with a XDS220 debug probe: I need to connect to the device executing code from flash without causing a device reset. I have enabled real-time mode for both CPU cores in my debug configuration.I can connect to the device and no reset is performed, but somehow the entire RAM space of the device is zero when viewed in CCS and indeed the software stops functioning as soon as the debugger is attached.
Any ideas why this might be happening?
Thank you and best regards,
Bart
Bart,
I suspect the .gel file used by CCS is causing the RAM to get initialized.
Find the F28377D_cpu1.gel and F28377D_cpu2.gel files in your <CCS INSTALL FOLDER>\ccs_base\emulation\gel folder. Open with a text editor and scroll down to the OnTargetConnect() function in each. For the cpu1.gel, comment out the lines:
*(int *)0x5F412 =0x000F; /* RAM INIT FOR M0/M1/D0/D1 Memory */
*(int *)0x5F432 =0x003F; /* RAM INIT FOR LS0..LS5 Memory */
*(int *)0x5F452 =0xFFFF; /* RAM INIT FOR GS0..GS15 Memory */
and similar for the cpu2.gel comment out the lines
*(int *)0x5F412 =0x000F; /* RAM INIT FOR M0/M1/D0/D1 Memory */
*(int *)0x5F432 =0x003F; /* RAM INIT FOR LS0..LS5 Memory */
See if this fixes the problem.
Regards,
David
Also on below point -
I need to connect to the device executing code from flash without causing a device reset.
In Gel file we also have GEL_Reset() function call which will reset the CPU and CPU1 reset will reset the device. So you may want to comment out that function call as well if do not want device to be reset on connect.
if (GEL_IsInRealtimeMode()) /* Do real-time mode target initialization */
{
}
else /* Do stop-mode target initialization */
{
GEL_Reset(); /* Reset DSP */
}
Regards,
Vivek Singh
Thank you for your help, this resolved my issue!
I do find it somewhat frustrating, that something like this is not documented anywhere (that I could find).
Thank you for your feedback. We'll see if this can be addressed in next release of the document.
Regards,
Vivek Singh