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.

RTOS/TDA2PXEVM: Difference between binaries and SD boot image

Part Number: TDA2PXEVM
Other Parts Discussed in Thread: SYSBIOS

Tool/software: TI-RTOS

Hello All,

We are working with TDA2Px evm and PSDK3.03 sysbios all configuration.

We have integrated mcan module into psdk framework and calling mcan functionalities in our link.

The mcan module wrapper is created in csl based on standalone sample application for MCAN. All pad configuration are done similar to done in sample app.

The code works fine when we use binaries and CCS . But when we make appimage for SD boot , the code is stuck , logs are as shown in attached screen shot.

Are we missing some settings ? Are all gel settings are reflected default sbl code available in pdk package ?

regards

Hrishikesh

  • Hi Hrishikesh,

    One difference could be that SBL does not include clock enable for MCAN which might be there in gel. You should enable clocks for MCAN in the application.

    Regards,
    Rishabh
  • Hello Rishabh,

    Thank you for the reply.
    We have created MCAN module which internally uses the CSL mcan api's , similar to the DCAN module in Processor SDK 03.03.00.00

    We have added the init , transmit and receive API from our module in a default usecase i.e. issSimcop_display.
    When we run the usecase through JTAG debug binaries, the init for mcan is successful and are able to transmit the data from first TDA2px-EVM.
    On the second EVM, we are using the CSL MCAN loopback example(debug binaries through JTAG) to receive the data that is transmitted from the first EVM, and are able to receive. Same works for transmit as well.


    However, When the same is built for release/debug mode(Appimage when EVM is in SD boot mode), the mcan init is failing / stuck at the MCAN_isFDOpEnable() api in the application where memory is read using the HW_RD_FIELD32.

    All the configuration except for the UART in the CSL MCAN evm loopback example are done in our application.

    The MCAN clock enable done in the example is also done in our application.

    HW_WR_FIELD32(SOC_WKUPAON_CM_BASE+CM_WKUPAON_ADC_CLKCTRL,
    CM_WKUPAON_ADC_CLKCTRL_MODULEMODE,
    CM_WKUPAON_ADC_CLKCTRL_MODULEMODE_ENABLE);

    What could be the possible issue for this difference in SD boot and the JTAG debug modes? Are there any other settings to be done to make it run in SD card mode.

    Regards,
    Hrishikesh
  • Hi Hrishikesh,

    The code is correct for Clock enable.
    Just to confirm can you connect to one of the IPU cores when you are facing this issue and see if the MCAN registers are accessible.
    Also can you check if you are using AMMU mapped addresses in your APIs as MCAN falls in bitband address space.

    Regards,
    Rishabh
  • Hi Rishabh

    Thanks for reply, I am using Amol's login as there are some issue on login.

    I tried to connect to tda2px evm when this issue occurs using normal gel files and load binaries using load symbols for ipu1_0(while boot mode is sdboot and boot is stuck at the point described above)

    When i tried to read MCAN registers (using memory browser with mcan base address 0x42C00000U and  0x42C00000U + 0x20000000U (since this is in bitband ), in both cases ccs could not read the mcan base address , it was showing the error as  CCS failed to read at address for both cases ie 0x42c00000 and 0x62c00000. And memory browser was showing '?' symbols

    Also will you please let me know how to check "Also can you check if you are using AMMU mapped addresses in your APIs as MCAN falls in bitband address space"

    regards

    Hrishikesh

  • Hi Hrishikesh,

    It seems that AMMU mapping from 0x4000_0000 to 0x6000_0000 is missing (one large page of 512 MB).
    Gel does this mapping. SBL expects application to do it.
    Can you check AMMU address space i.e. CACHE_MMU_LARGE_ADDR_i registers (0x5508_0800) and see if the mapping is there?

    Regards,
    Rishabh
  • Hi Rishabh,
    I could see in the file PROCESSOR_SDK_VISION_03_03_00_00\vision_sdk\links_fw\src\rtos\bios_app_common\tda2px\ipu1_0\Ammu1_bios.cfg
    following configuration is commented (line 213)
    /*
    var entry = AMMU.largePages[3];
    entry.pageEnabled = AMMU.Enable_YES;
    entry.translationEnabled = AMMU.Enable_YES;
    entry.logicalAddress = 0x60000000;
    entry.translatedAddress = 0x40000000;
    entry.size = AMMU.Large_512M;
    entry.L1_cacheable = AMMU.CachePolicy_NON_CACHEABLE;
    entry.L1_posted = AMMU.PostedPolicy_NON_POSTED;
    entry.L2_cacheable = AMMU.CachePolicy_NON_CACHEABLE;
    entry.L2_posted = AMMU.PostedPolicy_NON_POSTED;
    */
    Does it needs to be uncommented and build ?
    Is it correct and are there any other changes needed to be done ?
    regards
    Hrishikesh
  • Hi Hrishikesh,

    Yes you should uncomment this and build. The code looks fine.

    Regards,
    Rishabh
  • Thanks a lot Rishabh for your timely help, now its booting with SDImage.
    I am just curious to know why it was commented in the code and if it has any side effects
    regards
    Hrishikesh
  • Hi Hrishikesh,

    It must be commented in case customers want to map one large page differently. With this you are using all the large pages available in the M4 subsystem. Kindly mark the post that answers your query as "This resolved my issue" and close the thread.

    Regards,
    Rishabh