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.

IPC, c6472 project templates do not run

Other Parts Discussed in Thread: SYSBIOS

Hello,

I  am trying to run the IPC project templates (IPC and I/O examples ->  C6472 Examples -> C6472: MessageQ / Notify), using

XDCtools: 3.20.8.88
SYS/BIOS: 6.30.3.46
IPC: 1.22.5.27
CCSv: 4.2.3
EVM6472 Board rev. 6

and have some newbie questions.

 

Trying to compile both projects fails due to a missing element "heapSize" in the ti.sysbios.BIOS structure  (in message_multicore.cfg and notify_multicore.cfg ).

var BIOS        = xdc.useModule('ti.sysbios.BIOS');
BIOS.heapSize   = 0x8000   // error

When I comment out this line (perhaps not a good idea ;-) ) the project compiles, but does not run as expected.

Who calls the tsk0_func in message_multicore.c and  notify_multicore.c ? I could not find it.

/*
 *  ======== tsk0_func ========
 *  Allocates a message and ping-pongs the message around the processors.
 *  A local message queue is created and a remote message queue is opened.
 *  Messages are sent to the remote message queue and retrieved from the
 *  local MessageQ.
 */
Void tsk0_func(UArg arg0, UArg arg1)

... 

 When I try to run the project in Debug mode in the CCSv4, first core0 (C64XP_A) is enabled and stops at the main function. Should one take care of a certain order to connect and run the rest of the cores (CORE1-5) ?

Running the messageQ example nothing is displayed on the console.

For the notify example 
main: MultiProc id=0
main: MultiProc name=CORE0 

is displayed on the console, so only core0 is running.

 

I have noticed, that the platform definition for the example project is 

Platform: ti.sdo.ipc.examples.platforms.evm6472.core0

why not ti.platforms.evm6472 for a multicore example ?

 

What would be the procedure using CCS, if different sources should be run on different cores, not the same source on all cores?

I would be glad, if someone could help me and tell me what is are my basic mistakes.

Regards, Carsten

 

 

  • Ok, figured out most of the problems by myself, after upgrading to SYS/BIOS 6.31.4.27.

    Connected each Core using CCS, loaded the *.out onto each core and then started each core manually.

    Are there examples how to run these test applications without using the GUI of CCSv4 ?

     

    Regards, Carsten

     

  • Carsten,

    I am glad you figured it out. Would you post a brief description of what you did to solve the problem and what you did to get it to work well, please?

    Was the upgrade to SYS/BIOS 6.31.4.27 the key, or just one step along the way?

    Your question about loading outside of CCSv4 would be better answered by posting a new thread to the (ironically) Code Composer forum, since that is the place for emulation questions, too.

    Regards,
    RandyP

  • Randy,

    lets say, the upgrade was the key step on the way, because I then had my mind free to take a look at the real issues.

    Perhaps the main mistake has been to think, that an example code without any further comments would simply run out of the box.

    So I had to learn to hit the right line in the debug editor for the c6472 multi-core system, connect each core 1-5 (core0 is automatically connected and run, stops at the main routine), then to load the *.out file onto each core 1-5 (is automatically loaded onto core0), then to press run for each core 1-5 (they keep running and do not stop at the main routine, don't know where the different behaviour of core0 and core1-5 is configured), and then finally press run for core 0 and look at the console output. 

    Voila.

    That's why I am asking for a more automatic way to perform all those steps ;-)

    My next question would be, if there is an example that demonstrates communication between the cores on the EVM and the host PC, e.g., write some data file from host PC to EVM (e.g. into L2 mem of core x)  do some processing onto core x, write the results into a buffer on the EVM and then read the results per host PC, or write the results per core x to the host PC. 

    Thank you and regards,

    Carsten

  • Carsten,

    Carsten Reuter said:
    (core0 is automatically connected and run, stops at the main routine)

    Personally, I prefer to have a bit of control over what exactly happens automatically. Most people use the default Bug icon that launches, builds, loads, and runs. I prefer to use the drop down box and use the single step first to only Launch the TI Debugger, especially for the Multi-core devices. You may need to check the default debugger settings to turn off things that get in your way by running automatically; I rarely have to change the defaults, so they are probably okay if you have not made changes yourself.

    You can use CCSv4 to load each application one-at-a-time. And you can run each core individually or use the CCSv4 Synchronous Mode to start all cores in parallel. You

    These are the steps in the Debug View that I use to load and run independent applications on the various cores (use the menu commands View->C/C++ Projects and View->Debug to make both windows visible, if needed):

    1. Launch TI Debugger to load the Target Configuration
    2. On the Debug window icon row, click Enable Synchronous Mode
    3. On the main icon row, click Connect Target to connect to all the cores, making sure that all the cores have successfully connected and now say (Suspended)
    4. On the Debug window icon row, click Disable Synchronous Mode
    5. Go to the C/C++ Projects window and right-click on the project for Core0 selecting Debug Properties..., then under the Debugger tab, click Connect to exact CPU and select Core0 from your emulator's list of cores. Repeat for all of the application projects to connect each to its associated coreN.
    6. Go back to the Debug window, and on the Debug icon row click Collapse All (for ease).
    7. Highlight Core0 and on the main icon row, click Load Program then Browse Project and select the appropriate *.out. Click OK and OK to load it to Core0. Repeat for all of the cores and their associated *.out files. (it may be easiest to start at the bottom with core5 because of the auto-expansion that occurs, and you can double-click on a .out file rather than selecting and clicking OK in the Browse Project window)
    8. On the Debug window icon row, click Enable Synchronous Mode
    9. On the Debug window icon row, click Run. All of the cores should show (running) as their status.

    After going through this process once, when you edit and rebuild a project you will be asked if you want to automatically load the .out file whenever a rebuild occurs. I always say yes and always tell it not to ask again, or whatever it says in that pop-up box.

    With Synchronous Mode enabled, you can restart all of the cores simultaneously, and they can all run to main() if you have that enabled. I usually do enable Run to main().

    I think that some of these steps can be removed since there seems to be some redundancy with step 5 and step 7. But I do not have an EVM right now, so I cannot play with it to optimize this sequence. If you do try out some of this and find a better way, please let us know. Or if you find a similar sequence you like better, please let us know.

     

    For your "next question", since it is getting farther off of the original topic, I strongly recommend that you post it as a new question to the BIOS forum under Embedded Software. Please post a link to that new post on this thread so people who read this one can follow you to that new one.

     

    Regards,
    RandyP

     

    If you need more help, please reply back. If this answers the question, please click  Verify Answer  , below.