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.

Basic startup issues

Other Parts Discussed in Thread: HALCOGEN

Hello,

I'm having problems getting a very basic program to step through the debugger and hoping that somebody can point me in the right direction.  I have designed a board and think I have it running, JTAG appears to work.  I tried the same setup with the Hercules development board and that behaves the same way, so I don't think it is a hardware problem.

Basically when I try to start the debug session, I don't seem to be able to do anything except hit the red "Terminate" button, everything else is grayed out.  

I have tried CCSv5 and CCSv6 with a XDS100v2 JTAG, both do the exact same thing.  JTAG tests out fine using the "Test Connection" button, so I don't think it is the problem.

The program is very simple, just added some code to the default "Hello World" program (tried commenting out the cout statement too):

int main() {

cout << "!!!Hello World!!!" << endl; // prints !!!Hello World!!!
for(;;)
  {
    volatile int i, j, k, x;

    for (i=0; i<1000000000; i++)
      for (j=0; j<1000000000; j++)
        for (k=0; k<1000000000; k++)
        {
          x++;
        }
  }
  return 0;
}

Using the debug build configuration.  Tried the C version, same thing.

All I see on the console is:

CortexR4: GEL Output: Memory Map Setup for Flash @ Address 0x0CortexR4: GEL Output: Memory Map Setup for Flash @ Address 0x0 due to System Reset
CortexR4: GEL Output: Memory Map Setup for Flash @ Address 0x0 due to System Reset

Build reports this:

**** Build of configuration Debug for project test ****

"C:\\ti\\ccsv6\\utils\\bin\\gmake" -k all
'Building target: test.out'
'Invoking: ARM Linker'
"C:/ti/ccsv6/tools/compiler/ti-cgt-arm_5.2.4/bin/armcl" -mv4 --code_state=32 --abi=ti_arm9_abi -g --display_error_number --diag_warning=225 --diag_wrap=off -z -m"test.map" -i"C:/ti/ccsv6/tools/compiler/ti-cgt-arm_5.2.4/lib" -i"C:/ti/ccsv6/tools/compiler/ti-cgt-arm_5.2.4/include" --reread_libs --warn_sections --display_error_number --diag_wrap=off --xml_link_info="test_linkInfo.xml" --rom_model -o "test.out" "./hello.obj" -l"libc.a"
<Linking>
warning #10247-D: creating output section ".text" without a SECTIONS specification
warning #10247-D: creating output section ".const" without a SECTIONS specification
warning #10247-D: creating output section ".bss" without a SECTIONS specification
warning #10247-D: creating output section ".cinit" without a SECTIONS specification
warning #10247-D: creating output section ".sysmem" without a SECTIONS specification
warning #10210-D: creating ".stack" section with default size of 0x800; use the -stack option to change the default size
warning #10210-D: creating ".sysmem" section with default size of 0x800; use the -heap option to change the default size
'Finished building target: test.out'
' '

**** Build Finished ****

I'm probably missing something stupid, but I can't think of what that might be.

Any help on things to look into or test would be greatly appreciated

--Tom

  • Hi Tom, Two things:
    1) it looks like your build worked just fine. After you build you need to start a debug session though, this isn't automatic. You can right click on your project after building and select 'Debug As' from the context menu, or there's an icon on the menu bar to start a debug session. You need a target configuration file for this, but if you use the CCS project wizard to create the project *and* you take the time to select the connection during project creation (the debug probe and the target) then the project wizard will give you a target config file automatically. (.ccxml extension). If not you can create your own target config file and add it to an existing project but you have to know a bit more to do this.
    2nd) the 'empty main' project type that's in CCS just uses the compiler runtime library and the TI ARM compiler is pretty generic ... whereas Hercules parts require special startup code because of the dual-core lockstep and ECC.
    So your simple 'hello world' probably won't run if you didn't generate the startup code with HalCoGen.
    You should start with HalCoGen - it'll generate all your device setup code and provide you with a main() function in the file sys_main.c where you can insert your hello world.
  • Hi Anthony,

    Is there a sample project I could download for the 570LS0432PZ? I appear to be having some issues with my system. I just want figure out if it is a hardware issue on the board or something else.

    I do have another question, but I will ask that separately.

    Thanks a ton for your help!
  • Hi Thomas,

    Only thing I can think of that may be available 'pre built' or at least w. a project setup would be www.ti.com/.../launchpads-hercules-launchxl-tms57004.html

    -anthony
  • Ok, that helped. It was clearly a hardware problem and I have fixed it. Things appear to work fine now! Thank you so much for your help!