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.

AM263P4-Q1: Different software on different cores

Part Number: AM263P4-Q1
Other Parts Discussed in Thread: UNIFLASH

Tool/software:

Hey Experts,

ive some question regarding the different cores of the µC.

As SW i am using:
CCS 12.8.1.00005
SDK 10_00_00_35
Uniflash 8.8.1.4983

Our plan is to use different cores for different softwares. Is there any example or step by step guide which explaint how to flash to different cores?

Lets imagen i have 2 softwares. One for core1 and one for core 2. Do i have to change any project option in CCS to say the software it belongs to which core?
Or is it all handled by SBL? 
What do i have to change in SBL in order to copy software A to core 1 and software B to core 2?
How do i flash with uniflash tool? Can i flash both softwares one after another or do i pack them into one image? How do i do that?

Best regards,

Marcel

  • Any multicore project (a.ka. a System Project) will output an .appimage (now migrated to multicore .elf) file containing the programs for all cores compiled in the project. The stock SBL from TI recognises the file format in flash and will load the correct program to the correct core and start the software.

    The concepts are detailed here: AM263Px MCU+ SDK: Understanding Multicore ELF image format

    Here's how to use UniFlash* to flash the SBL and .appimage: AM263Px MCU+ SDK: Flashing Tools

    *My advice is get the latest version 9.2. Earlier versions won't work with later dev boards.

  • I still don't get where to choose for which core my software gets compiled. Is it any setting in CCS?
    If i understand it correctly Uniflash is not capable of flashing multicore elfs. So is it also possible to flash the software step by step? e.g. first flash process is sw for core1 and sbl, second is flashing sw for core 2.


  • I still don't get where to choose for which core my software gets compiled. Is it any setting in CCS?

    I suppose there's 3 major points where you choose a particular core:

    1) In the System Project where you associate individual projects with a core for debug:

    - Create one from scratch Using System Projects to Simplify Multicore Debug Launch

    - Or choose a multicore example and build on that: e.g. C:\ti\mcu_plus_sdk_am263px_09_02_00_56\examples\drivers\ipc\ipc_notify_echo\am263px-cc

    2) If you're using SysCfg, choose which core to allocate resources in the tabs at the top.

    3) The final step is the 'makefile_system_ccs_bootimage_gen' as seen in the example projects which takes the core project ELFs and makes a combined .appimage file. Edit this to suit your project and allocate to cores.

    If i understand it correctly Uniflash is not capable of flashing multicore elfs.

    Yes that's a fair point. You'll have to stick with RPRC .appimages. This will be deprecated in SDK 11. I'm not sure what TI's plans are for updating UniFlash for SDK 11.

    So is it also possible to flash the software step by step? e.g. first flash process is sw for core1 and sbl, second is flashing sw for core 2.

    I don't get the question. Why have this complexity?

  • Hi Marcel,

    To give you better context:

    AM26x devices are multicore and external flash, and the R5F0 core takes care of running the bootloaders, RBL which runs on R5F0 is responsible for fetching SBL from external flash and executing it. Then secondary bootloader is responsible for fetching the application blob(all cores combined), then parsing it and loading application for all other cores.

    Also from SW tooling wise, since bootloader (SBL) parses the mcelf image blob and separates the binary for each cores and loads it accordingly.

    Now for flashing the .mcelf image format, Uniflash tool supports flashing, It supports both mcelf and rprc.

    From development perspective, You can develop the application for each core separately, as part of post build step it is combined together to facilitate a common image blob for flashing.

    It also helps with single flashing step for all cores. 

  • Uniflash tool supports flashing, It supports both mcelf and rprc.

    That's great news but it is different to this information:

    AM263Px MCU+ SDK: Understanding Multicore ELF image format

    Pls update the documentaion.

  • Thank you Kier for bringing it to notice, This will be updated in next release.

  • Thank you.

    Just more observation. The file filter for UniFlash 9.2 does not include .mcelf.

    If it is supported, then this would give informal confirmation of that.

  • Sure Kier, I will create a internal ticket for this.

  • 2) If you're using SysCfg, choose which core to allocate resources in the tabs at the top.

    just to be sure, with tabs at the top you mean this here:


    3) The final step is the 'makefile_system_ccs_bootimage_gen' as seen in the example projects which takes the core project ELFs and makes a combined .appimage file. Edit this to suit your project and allocate to cores.

    the first line of the makefile says its autogenerated. Can you tell me when its updated? And if i edit this, doesn't it get overwritten when there is a new autogeneration?


    So is it also possible to flash the software step by step? e.g. first flash process is sw for core1 and sbl, second is flashing sw for core 2.

    I don't get the question. Why have this complexity?

    We have a set of 6 PCBs. 5 should be flashed with SW1 and 1 with SW1+SW2. So for me the first thought was to have one SVN folder for SW1 and one folder for SW2. 

  • with tabs at the top you mean this here:

    I didn't see any tabs in your screenshot but I mean these tabs:

    In a System Project, there are multiple .syscfg files but it is presented as one configuration GUI within CCS with multiple tabs.

    the first line of the makefile says its autogenerated. Can you tell me when its updated?

    Good spot! No, I'm pretty sure it is not auto-generated, perhaps it was in the past. Anyway, I have modified this file by hand a few times to suit my project and it never gets overwritten.

    We have a set of 6 PCBs. 5 should be flashed with SW1 and 1 with SW1+SW2. So for me the first thought was to have one SVN folder for SW1 and one folder for SW2. 

    I'm still not fully grasping your use case but I suggest you modify file makefile_system_ccs_bootimage_gen to generate two .appimage files.

    1) SW1.appimage containing code for R5FSS0_0

    2) SW1+SW2.appimage containing code for R5FSS0_0 and R5FSS1_0 (for example).

    You then flash 1) or 2) to your external flash. Then the single common SBL can work out how many core programs you have in the .appimage from its header, load the program or programs into RAM and boot one or more cores accordingly.

  • with tabs at the top you mean this here:

    I didn't see any tabs in your screenshot but I mean these tabs:

    In a System Project, there are multiple .syscfg files but it is presented as one configuration GUI within CCS with multiple tabs.

    Yeah i was confused because i didn't found any tabs. You only get these tabs when you have a System Project. I guess when you have a "normal" project you can change the core to flash like i showed in my screenshot.

    I'm still not fully grasping your use case but I suggest you modify file makefile_system_ccs_bootimage_gen to generate two .appimage files.

    1) SW1.appimage containing code for R5FSS0_0

    2) SW1+SW2.appimage containing code for R5FSS0_0 and R5FSS1_0 (for example).

    You then flash 1) or 2) to your external flash. Then the single common SBL can work out how many core programs you have in the .appimage from its header, load the program or programs into RAM and boot one or more cores accordingly.

    I thinks this is mostly an issue of file ordering, i will be able to handle this.

    Thanks for your help!