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.

Run the dsp code of ipnc with CCS v5

Other Parts Discussed in Thread: SYSBIOS

Hi,

I have get the ipnc code from the aprro.

Now, I want run the dsp code of ipnc with the CCS v5.

My first step, connect the dsp with ccs v5 and run the "hello world", it is successful.

My second step, transplant the dsp code of ipnc to the ccs v5, it failed.

I find the BIOS_c6xdsp.cfg have the following code:

xdc.loadCapsule("mcfw/src_bios6/cfg/ti814x/SYSLINK_common.cfg");

If I should build the syslink in the windows with CCS v5. 

I try create a ccs project according to the web site: http://processors.wiki.ti.com/index.php/Creating_CCS_Project_for_SysLink_samples.

However, I can't find the platform "ti.syslink.samples.rtos.platforms.ti814x.dsp".

What should I do if I want to run the dsp code with CCS v5.

Thank you

  • Do you mean you want to load and run the DSP portion of IPNC RDK using CCS without the A8 application ? This is not possible. IPNC RDK depends on syslink for loading and seting up shared regions.

  • Hi Narayanan,
    Thank for your reply.
    If I want to debug the DSP code of IPNC RDK using CCS, what should I do?
    Now, I am no sure if I can run the syslink using CCS.
    I uncompress the tar.gz file into a directory of C:\ti in windows XP, and config the CCS as follow:

    However, when I edit the cfg file, add the "var Syslink                 = xdc.useModule ('ti.syslink.ipc.rtos.Syslink');" in it, and build the ccs project,

    the error as follow:

    C:\ti\syslink_2_10_07_31\packages\ti\syslink\ipc\rtos\package.xdc found along the package path, but no schema file was found. Ensure that the package 'ti.syslink.ipc.rtos' is completely built. 

    What's the mean?

  • To debug DSP side code, execute ./load.sh .This will take the DSP out pf reset and load the DSP firmware. THen you can connect to c674 DSP and do "Load Symbols" and choose the DSP firmware executable .You will then be able to debug using CCS as usual. It is not supported to build the IPNC DSP portion as a CCS project,

  • Hi,

    Sorry, I can't understand that. Could you explain that detailed. 

    I read the code of IPNC RDK, I find some "link" between C674x DSP and the M3. I guess the communication between  DSP and  M3, or  DSP and A8,  is used by link, and the link API may be the syslink or IPC. I want to know if the A8 used syslink, the DSP must use the syslink too. What can I do when the DSP use the syslink. If I must debug in the linux?

    Now, I can connect to C674 DSP,  and run the "Hello world" using ccs v5. My problem is that I want to know if I can run the syslink in the dsp using CCS. I download a ccs project of syslink samples on the web https://github.com/vanti/Syslink-MessageQ-sample-CCS-project/zipball/version-1.00.00.00, however when I build the project, I have the error as follow:

    C:\ti\syslink_2_10_07_31\packages\ti\syslink\ipc\rtos\package.xdc found along the package path, but no schema file was found. Ensure that the package 'ti.syslink.ipc.rtos' is completely built. 

    Could you give me some advices detailed.

    Further more, I want to know if the HLOS sied used the syslink and ipc, and the RTOS side only used the ipc. If I develop the DSP side, I just need use the IPC API to communicate with the A8, and the communication between DSP and M3, only used the IPC.

  • 1. Do you want to debug IPNC RDK DSP side code

       or

    2. Build Syslink samples using CCS.

    Based on your requirement, the method is completely different.

    IPNC RDK is a complete system and communication from A8 -> M3 is a small part of it. IPC RDK uses link APIs.Link APIs are not syslink APIs. They are high level APIs used to control behaviour of a link. Link APIs are implemented using Syslink/IPC modules to communicate across cores.

    On A8 HLOS side Syslink is used and on M3/DSP  RTOS side IPC package is used.

     

     

     

  • Thank you for your reply.

    I want to debug the IPNC RDK DSP side code using the CCS.

    what should I do?

  • For debugging using CCS you dont need a CCS project.

    Build the IPNC DSP firmware using the IPNC RDK build process (command line make based build)

    Load the DSP firmware using the scripts provided in IPNC RDK .(load.sh)

    Once DSP firmware is loaded, connect to DSP using CCS. Then do the following in CCSv5 menu:

    Menu -> Run -> Load -> Load Symbols . Select the DSP firmware executable.

    Now you will be able to put breakpoints and single step as you would normally debug using CCS 

  • Thank you for your reply.

    My CCSv5 installed in the windows os. Should I install it in the linux?

  • Hi, Narayanan.

    Thank you for your reply.

    Accord your instrument I load the DSP fireware executable file successful. However, because of I installed the CCS in the Windows OS, it can't find the source file in the Linux OS. 

    What should I do?

    I used the Davinci device and the Linux OS first. Thank you very much.

  • Untar the IPNC RDK source files in your windows machine and when CCS asks for path to source files choose the file. All other files will be taken based on relative path to the first file.

  • I can open the files according to your instrument.

    However, the files only opened in the code edit window, how can I manage the file in the  project explorer or organize the file as a project. 

    Thank you very much.

  • Hi, Narayanan.

    I can open the files of DSP side, and debug them.

    However, I find the A8 didn't run when I debug the DSP side.

    What should I do if I want the camera running normally and debug the DSP side.

    I have another question about develop the DM8148. If I can build a project to debug the DSP (without the IPNC code) in windows OS, and develop the ARM in Linux OS.

    What should I do if I want to connect them. 

  • However, I find the A8 didn't run when I debug the DSP side.

      - Do you mean A8 hung when you halt DSP or are you refering to fact that no data is received on A8 when DSP is halted. It is expected for data flow to stop when DSP is halted as DSP is an intermediate processing block in the data flow.You should not see the A8 hung however (.i.e If you press enter in the serial console it should be responsive).

    I have another question about develop the DM8148. If I can build a project to debug the DSP (without the IPNC code) in windows OS, and develop the ARM in Linux OS.

    What should I do if I want to connect them.

     - Do you mean you build a library separately and want to integrate it into IPNC RDK ?

  • Hi, Narayanan.

    My step as follow:

    1, execute the "load*.sh", load the DSP execute file, make the DSP out of reset.

    2, I connect the DSP in CCS, and load the DSP execute file, run it.

    3, I run the A8 system_server.

    However I find the information of feedback as follow:

    [m3vpss ] 163098: SYSTEM: Attaching to [DSP] ...
    [m3video] 164100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 164098: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 165098: SYSTEM: Attaching to [DSP] ...
    [m3video] 165100: SYSTEM: Attaching to [DSP] ...
    [m3video] 166100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 166098: SYSTEM: Attaching to [DSP] ...
    [m3video] 167100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 167098: SYSTEM: Attaching to [DSP] ...
    [m3video] 168100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 168098: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 169098: SYSTEM: Attaching to [DSP] ...
    [m3video] 169100: SYSTEM: Attaching to [DSP] ...
    [m3video] 170100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 170098: SYSTEM: Attaching to [DSP] ...
    [m3video] 171100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 171098: SYSTEM: Attaching to [DSP] ...
    [m3video] 172100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 172098: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 173098: SYSTEM: Attaching to [DSP] ...
    [m3video] 173100: SYSTEM: Attaching to [DSP] ...
    [m3video] 174100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 174098: SYSTEM: Attaching to [DSP] ...
    [m3video] 175100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 175098: SYSTEM: Attaching to [DSP] ...
    [m3video] 176100: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 176098: SYSTEM: Attaching to [DSP] ...
    [m3vpss ] 177098: SYSTEM: Attaching to [DSP] ...
    [m3video] 177100: SYSTEM: Attaching to [DSP] ...

    The second question, I can open the main_c6xdsp.c in the CCS, and add the breakpoint. However I can't open other files unless I suspend the dsp, and I can see the file which running, but can't add breakpoint.

    My mean is that. how debug the IPNC DSP side code as a project, for example, I can open any file of IPNC DSP side in CCS, and debug it. Furthermore, I can add my c source files or libs into the project.

    Thank you.

  •  I connect the DSP in CCS, and load the DSP execute file, run it.

     - Are you loading the executable or "Loading symbols". It is important you do load symbols and not load the executable. If you load the executable it will not work.

    The second question, I can open the main_c6xdsp.c in the CCS, and add the breakpoint. However I can't open other files unless I suspend the dsp, and I can see the file which running, but can't add breakpoint.

     - You can add breakpoints if you are aware of the function name where you want execution to halt.

    My mean is that. how debug the IPNC DSP side code as a project, for example, I can open any file of IPNC DSP side in CCS, and debug it. Furthermore, I can add my c source files or libs into the project.

    - As indicates CCS project is not supported. If you want to add files for compilation you will have to update the IPNC RDK makefiles.

  • Hi, Narayanan.

    I worked as your advice.

    However, I can't load the file successful, the error as follow:

    No source available for "ti_sysbios_family_c64p_Hwi0() at Z:\DM8127\ipnc_8127_3.2\ipnc_rdk\target\filesys\opt\ipnc\firmware\ipnc_rdk_fw_c6xdsp.xe674:{3}

  • Hi, Narayanan.

    Thank you for your reply, it's so helpful for us.

    Loading Symbols and I choose the executed file in the firmware directory.

    However it can't execute successful.

    My steps as follow:

    1, execute the "load.sh" to make DSP out of "reset"

    2, connect the DSP in the CCS,  Loading Symbols and choose the executed file in the firmware directory, run DSP. The feedback information as follow:

          No source available for "C$$EXIT() at Z:\DM8127\ipnc_8127_3.2\ipnc_rdk\target\filesys\opt\ipnc\firmware\ipnc_rdk_fw_c6xdsp.xe674:{3} 0x8f492520{4}"

    Could you give me some advices about that, thanks.

    Tianxing 

  • Hi, Narayanan

    I am so glad that I have connected the DSP using CCS successful, and I can run the A8 and M3 successful.

    Now, I have some questions about debugging the DSP.

    1, when I run the DSP, it will suspend and I must continue run it. My steps as follow:

         1) Create a new Target Configuration File, and configure it as follow:

              

         2) Launch the selected configuration, as follow:

            

         3) execute the "load.sh", make the DSP out of "reset"

         4) Connect the C674x DSP

         5) Execute the system_server  to run the A8 and M3, 

         6) Load the executable file of DSP through "Load Symbols" in CCS

         7) Run the DSP

          when I run the DSP, it will suspend, I must continue click F8 to run it.

    2, When I using CCS3.3, I can open and debugging a lib project as follow:

           1) open a project of ccs3.3

                          

             2)open the lib project as follow:           

                

                

              Then I can debug the lib source.

              Though I can't debugging the source code of dsp as a project, could I add a lib to the IPNC_RDK and debugging the lib as above.

              I will also try that, since I using the Davinci device and Linux OS first, could you give me some suggestions about developing the Davinci device.

             Thank you very much.

  • 1, when I run the DSP, it will suspend and I must continue run it

     - Do you mean once you connect to DSP, load symbols and give "Run" it halts automatically. At which point does it halt. If you run again using F8 does it run continuously or does it halt again ? Note that connecting to the DSP will halt the core and that is expected. You should give run first time.

    When I using CCS3.3, I can open and debugging a lib project as follow:

     - If you just want to add the library source files for single step and debug, you can do

      

    Select the edit source lookup and add path to your library folder. This will enable CCS to select files from your library if it halts at one of your library functions.

    Pls also try posting your query in CCS forum. The CCS experts monitor that forum and will be able to provide better advice

    CCS forum: http://e2e.ti.com/support/development_tools/code_composer_studio/default.aspx

     

  • Hi, Thank you for your reply, it is helpful for us.

    As I mentioned before, when I connect the DSP using CCS, the core will be halted, and I run it using F8, however, it will be halted again, it will for some times.

    If it connected with the start sequence of A8?

  • Hi, I can load symbol and run the code of DSP side successful.

    However I have a question.

    I execute the code by step, however, I find it can't execute as my expect. I guess it execute as the asm code, what should I do if I want it execute as C code.

    As follow:

    First step, it run in the line 2974. But the second step it run in the 2972.

    The first step

    The second step

  • This is due to compiler optimization .If you want to completely disable compiler optimization modify:

    /dvr_rdk/makerules/rules_c674.mk

    Change


    CFLAGS_INTERNAL += --symdebug:dwarf -O3 -ms0 --opt_for_speed=5 --optimize_with_debug

    to

    CFLAGS_INTERNAL += --symdebug:dwarf

    (Remove -O3 -ms0 --opt_for_speed=5 --optimize_with_debug)

    Note that this will have a major performance impact. Use it only for debug during development time

  • Thank you for your reply.

    I will try it.

  • Hi,

    I have a question about creating a lib for the C674x DSP in the DM8127.

    Could I create a C674x static lib on the Linux OS, what should I do?

    And I create a C674x static lib by using the CCS v5.2 on the Windows OS, as follow:

  • Do you mean your development host is linux and you want to use create a c674 static lib ?

    The TI c6x codegen tools are available for linux also (part of RDK package) and you can use it to create lib.

    ar6x is the tools which can be used to create libraries

  • Hi,

    Thanks for your fast reply.

    Are there some differences between the lib created on the Windows and Linux, for example, the performance?

    I am more concerned the performance.

    Tianxing

  • There is absolutely no difference in performance

  • Hi,Badri

    sorry for interrupting,would you plaese offer some material about generating static dsp library on linux system?

    i have generated dsp static library with CCS 5.2 and C6000 7.4.2,also,i can call these function,but the running result is not right.

    as discribe in this thread:http://e2e.ti.com/support/dsp/davinci_digital_media_processors/f/716/t/303658.aspx

    thank you.