WKUP R5F:1, How can I change the DDR priority. 2, How to assign TCM

Part Number: TDA4VEN-Q1

Tool/software:

Hi, Ti

We deploy AUTOSAR OS in TDA4Ventry wkup r5f.

When the full function is running(mcu1,mcu2,c7x,app.....), the WKUP AUTOSAR OS TASK cycle becomes unstable.

We would like to try the following solution:

1,Improve the priority of WKUP R5F to access DDR.

How should I do this?

2,Since each R5F core has TCMA and TCMB, we want to run part of the task on the TCM.

Before modifying the LDS file:

After modifying the LDS file:

After the modification, the OS cannot run properly.

How can I modify the LDS file so that TCMA or TCMB is Free. Ultimately used in the OS Task stack.

SDK:ti-processor-sdk-rtos-j722s-evm-10_00_00_05

MCAL:MCUSW_10_00_00_06_CONFIG

Thanks and Regards,

jianwei lei

  • Hello,

    boot code ,startup code has to be in TCM memory this will occupy very much less space. You can use remaining TCMA and TCMB free space by creating a new section in AUTOSAR Linker file.

    You can also use internal Memories (OCRAM etc..) apart from DDR to have quick access.

    Regards

    Tarun Mukesh

  • Hi Tarun,

    boot code ,startup code has to be in TCM memory this will occupy very much less space. You can use remaining TCMA and TCMB free space by creating a new section in AUTOSAR Linker file.

    Yes,I tried to release one of the TCM.

    Change the WKUP AUTOSAR Linker file,WKUP R5F cannot be run after the SBL is started,Watch the screenshot of the changes above.

    You can also use internal Memories (OCRAM etc..) apart from DDR to have quick access.

    Yes, I do use OCRAM, OCRAM space is too small. SBL More than half used

    We would prefer to try to modify the priority of WKUP's access to DDR.

    Thanks and Regards,

    jianwei lei

  • Hello,

    Change the WKUP AUTOSAR Linker file,WKUP R5F cannot be run after the SBL is started,Watch the screenshot of the changes above.

    You can use MCU R5F to run AUTOSAR whereas SBL can run on the DM core which is WKUP R5F core.

    Regards

    Tarun Mukesh

  • Hi Tarun,

    Thank for your quick reply!  

    You can use MCU R5F to run AUTOSAR whereas SBL can run on the DM core which is WKUP R5F core.

    Yes, that's what we did.

    Our MCU R5F and DM WKUP R5F both run AUTOSAR, and SBL also runs in DM core.

    Here's the process I understand: Power on the SBL to start running and load each core,When reloading DM core,Reset to boot entry(_self_reset_start),Start and initialize assembly code,Finally run to the DM(WKUP R5F) Main function.

    MCU R5F uses MSRAM, DM WKUP R5F can only use part of OCRAM.

    So we need to have A part of the TCM(A or B) out

    (Here's my puzzle:I can only keep the Settings consistent with the MCU Plus Example,Cannot respecify boot code to run only on TCMB:.startupCode   : align = 8,        > R5F_TCMB)

    or Increase the priority of WKUP R5F to access DDR

    Thanks and Regards,

    jianwei lei

  • Hi jianwei lei,

    So we need to have A part of the TCM(A or B) out

    But this part will be very small, isn't it? The only part, which is used by SBL, will need to be kept out. Rest entire TCM A and B memories can be used for your Autosar Task, isn't it? Is it not sufficient? 

    Regards,

    Brijesh

  • Hi Brijesh Jadav

    Thank for your reply!  

    At present, SRAM(OCSRAM+MCU_MSRAM) is sufficient and TCM is not needed.

    But I still have my doubts,How do I use TCM correctly in link file (A or B) and make sure DM SBL resets correctly and loads DM WKUP to boot.

  • Hello,

    If i understand correctly, you are asking

    How does SBL load the WKUP DM R5F core to boot from respective TCM either TCM A or TCM B ? 

    May i know which boot media are you using for SBL, based on the boot media for example SD card then It is run from an SD card . you can build this example like you do for the others using makefile .

    • Partition the SD card to have boot and root parititon
    • Copy sbl_sd.release.hs_fs.tiimage as tiboot3.bin to the boot partition of SD card
    • Copy application image as app to the boot partition of SD card
    • Depending on the type of SBL loaded, SBL looks for the multicore appimage of the application binary at a specified location in a boot media.
    • If the appimage is found, the multicore appimage is parsed into multiple RPRCs. These are optimized binaries which are then loaded into individual CPUs.
    • Each RPRC image will have information regarding the core on which it is to be loaded, entry points and multiple sections of that application binary
    • The SBL uses this information to initialize each core which has a valid RPRC. It then loads the RPRC according to the sections specified, sets the entry points and releases the core from reset. Now the core will start running.
    • So if you need to use particular TCM ( A or B) then set the entry point in the linker file of the application to the respective TCM memory section.

    I hope you understand the explanation. 

    Regards

    Tarun Mukesh