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.

why i build a project for c2812 Simulator on ccs v3.3 but can't debug with connect ?

Other Parts Discussed in Thread: CCSTUDIO

 I  want  to  creat    a c2812  Simulator   project  on   ccs  v3.3 ,but   i  don't  know  what  i did  is right ?   it's   my   step  for  creat it . 

first   : Setup CCStudio v3.3    I  choose  F2812 Device  Simulator  and  save  it .  then  open  ccs v3.3  and  build  a  project .

while  build   ok , and  I   can't   load-program   for  a  not  correct  access  memory,  so   i   modify   the  memory-map  for  the  sim2812.gel  function  memory-map to  fit   it .  and   rebuild   it  ok,   but   it's  still   can't   load-program  for  write  a  not access  memory  .  so  i   want   ask   the  how  can  sim2812.gel  executed  after  i modify  it ?       

is  it  not   exectued   the function  "OnTargetConnect()"   of   sim2812.gel   while   can't  connect  target ? 

but    the   debug    options   for   "connect "  is   "disconnect"   .     

can  you  help  me ?  thanks .

  • Hello,

    It sounds like you are not using a linker command file. Instead of modifying the gel file (which you should not do), use a linker command file.

    If you don't know what a linker command file is, I suggest you read this article:

    You can try the default F2812 cmd file that gets generated in CCSv6 that I attached here:

    https://e2e.ti.com/cfs-file/__key/communityserver-discussions-components-files/81/2812_5F00_RAM_5F00_lnk.cmd

  • ---------------------------- new_test.pjt - Debug ----------------------------
    I create a new project and add a hello.c and add the file 2812_RAM_lnk.cmd you give me . when i build the project ,it gots some errors follows .

    [hello.c] "C:\CCStudio_v3.3\C2000\cgtools\bin\cl2000" -g -fr"C:/CCStudio_v3.3/MyProjects/new_test/new_test/Debug" -d"_DEBUG" -d"LARGE_MODEL" -ml -v28 -@"../../new_test/new_test/Debug.lkf" "hello.c"

    [Linking...] "C:\CCStudio_v3.3\C2000\cgtools\bin\cl2000" -@"Debug.lkf"
    <Linking>
    >> warning: entry point symbol _c_int00 undefined

    undefined first referenced
    symbol in file
    --------- ----------------
    _printf C:\CCStudio_v3.3\MyProjects\new_test\new_test\Debug\hello.obj
    >> error: symbol referencing errors - './Debug/new_test.out' not built

    >> Compilation failure

    Build Complete,
    2 Errors, 1 Warnings, 0 Remarks.

    I remove the printf() and build ok. but when I load-program and debug it , it appear some error like it. this is why? and what should modify? thanks to tell me.

    Trouble Writing Memory Block at 0x3f9780 on Page 0 of Length 0xcd9: Cannot access memory address 0x3FA000
    Trouble Writing Memory Block at 0x3f9780 on Page 0 of Length 0xcd9: Cannot access memory address 0x3FA000
    Error: Can't write to data memory 0x801, check memory config [-2184]
    Can't Run Target CPU: Can't write to data memory 0x808, check memory config [-2184]
  • chao jia said:
    I remove the printf() and build ok.

    Most likely you are missing the run-time library. You would need to add it to get printf support

    chao jia said:
    Cannot access memory address 0x3FA000

    Try this attached file instead:

    https://e2e.ti.com/cfs-file/__key/communityserver-discussions-components-files/81/F2812.cmd

  • I use the F2812.cmd and build . [Linking...] "C:\CCStudio_v3.3\C2000\cgtools\bin\cl2000" -@"Debug.lkf"
    I use F2812.cmd and build .

    <Linking>
    >> warning: load address of uninitialized section ramfuncs ignored
    >> warning: entry point symbol _c_int00 undefined

    Build Complete,
    0 Errors, 2 Warnings, 0 Remarks.

    and I load-program the test.out , appear some follows but not disassembly, this is why and i can't entry point symbol _c_int00 ?

    000000 0000 ITRAP0
    000001 0000 ITRAP0
    000002 0000 ITRAP0
    000003 0000 ITRAP0
    000004 0000 ITRAP0
    000005 0000 ITRAP0
    000006 0000 ITRAP0
    000007 0000 ITRAP0
    000008 0000 ITRAP0
    000009 0000 ITRAP0
    00000A 0000 ITRAP0
    00000B 0000 ITRAP0
    00000C 0000 ITRAP0
    00000D 0000 ITRAP0
    00000E 0000 ITRAP0
    00000F 0000 ITRAP0
    000010 0000 ITRAP0
    000011 0000 ITRAP0
    000012 0000 ITRAP0
    000013 0000 ITRAP0
    000014 0000 ITRAP0
    000015 0000 ITRAP0
    000016 0000 ITRAP0
    000017 0000 ITRAP0
    000018 0000 ITRAP0
    000019 0000 ITRAP0
    00001A 0000 ITRAP0
    00001B 0000 ITRAP0
    00001C 0000 ITRAP0
    00001D 0000 ITRAP0
    00001E 0000 ITRAP0
    00001F 0000 ITRAP0
    000020 0000 ITRAP0
    000021 0000 ITRAP0
    000022 0000 ITRAP0
    000023 0000 ITRAP0
    000024 0000 ITRAP0
    000025 0000 ITRAP0
  • I have solve the problem for debug it .
    for warning: load address of uninitialized section ramfuncs ignored .
    I modify the F2812.cmd
    ramfuncs : LOAD = FLASHD,
    RUN = RAML0,
    LOAD_START(_RamfuncsLoadStart),
    LOAD_END(_RamfuncsLoadEnd),
    RUN_START(_RamfuncsRunStart),
    PAGE = 0
    to
    ramfuncs : > RAMH0 PAGE = 1

    for warning: entry point symbol _c_int00 undefined .
    I add the rts2800.lib file and debug it ok .

    thanks for your help with patience .