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.

Linux/TDA2PXEVM: How to use PRCM APIs ? (XDC ASSERT)

Part Number: TDA2PXEVM


Tool/software: Linux

Hello

I use TDA2PX and want to get power comsumption of the chip on SW side.
I found PRCM interface and tired to use them.
I just put Utils_prcmPrintAllVoltageValues() in vision_sdk/apps/src/rtos/common/chains_main_linux.c, but some eorrs occured as below

 [HOST] [IPU2  ]     18.406606 s: *** VPDMA Firmware Loading... ***
 [HOST] [IPU2  ]     18.406697 s: VPDMA Firmware Address = 0xa035b5c0
 [HOST] [IPU2  ]     18.406789 s: VPDMA Load Address     = 0x489dd004
 [HOST] [IPU2  ]     18.406880 s: VPDMA Firmware Version = 0x4d0001b8
 [HOST] [IPU2  ]     18.407002 s: VPDMA List Busy Status = 0x00000000
 [HOST] [IPU2  ]     18.407063 s: *** VPDMA Firmware Load Success ***
 [HOST] [IPU2  ]     18.478923 s:  SYSTEM: VPS Init Done !!!
 [HOST] [IPU2  ]     18.479899 s:  UTILS: DMA: HWI Create for INT25 !!!
 [HOST] [IPU2  ]     18.480204 s:  SYSTEM: SW Message Box Msg Pool, Free Msg Count = 1024
 [HOST] [IPU2  ]     18.480296 s:  SYSTEM: Heap = LOCAL_DDR            @ 0x00000000, Total size = 262144 B (256 KB), Free size = 256080 B (250 KB)
 [HOST] [IPU2  ]     18.480448 s:  SYSTEM: Heap = SR_OCMC              @ 0x00000000, Total size = 0 B (0 KB), Free size = 0 B (0 KB)
 [HOST] [IPU2  ]     18.480601 s:  SYSTEM: Heap = SR_DDR_CACHED        @ 0x84203000, Total size = 314572800 B (300 MB), Free size = 314572800 B (300 MB)
 [HOST] [IPU2  ]     18.480784 s:  SYSTEM: Heap = SR_DDR_NON_CACHED    @ 0xa0100000, Total size = 1046656 B (0 MB), Free size = 954496 B (0 MB)
 [HOST] [IPU2  ]     18.480967 s:  SYSTEM: Initializing Links !!!
 [HOST] [IPU2  ]     18.782620 s:  SYSTEM: Initializing Links ... DONE !!!
 [HOST] [IPU2  ]     18.830872 s:  ---------------------------------------------------------
 [HOST] [IPU2  ]     18.830994 s:
 [HOST] [IPU2  ]     18.831025 s:  UTILS_PRCM_STATS:  Current Voltage
 [HOST] [IPU2  ]     18.831116 s:
 [HOST] [IPU2  ]     18.831147 s:      Voltage Rail          ||      Voltage
 [HOST] [IPU2  ]     18.831208 s:  ---------------------------------------------------------
 [HOST] [IPU2  ]     18.831299 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831360 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831421 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831482 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831574 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831635 s:  UTILS_PRCM_STATS: Get Voltage Failed!!
 [HOST] [IPU2  ]     18.831696 s:
 [HOST] [IPU2  ]     18.831726 s:  ---------------------------------------------------------
 [HOST] [IPU2  ]     18.831818 s:  CHAINS: Application Started !!!
 [HOST] [IPU2  ]     18.844781 s:  BOARD: Board Init in progress !!!
 [HOST] [IPU2  ]     18.845330 s:  BOARD: Board Init Done !!!
 [HOST] [IPU2  ]     18.846214 s:
 [HOST] [IPU2  ]     18.846275 s:  ### XDC ASSERT - ERROR CALLBACK START ###
 [HOST] [IPU2  ]     18.846336 s:
 [HOST] [IPU2  ]     18.846489 s: E_hardFault: FORCED
 [HOST] [IPU2  ]     18.846550 s:
 [HOST] [IPU2  ]     18.846580 s:  ### XDC ASSERT - ERROR CALLBACK END ###
 [HOST] [IPU2  ]     18.846641 s:
 [HOST] [IPU2  ]     18.846855 s:
 [HOST] [IPU2  ]     18.846885 s:  ### XDC ASSERT - ERROR CALLBACK START ###
 [HOST] [IPU2  ]     18.846946 s:
 [HOST] [IPU2  ]     18.847068 s: E_busFault: PRECISERR: Immediate Bus Fault, exact addr known, address: 48060010
 [HOST] [IPU2  ]     18.847160 s:
 [HOST] [IPU2  ]     18.847190 s:  ### XDC ASSERT - ERROR CALLBACK END ###
 [HOST] [IPU2  ]     18.847282 s:


Please let me know how to use PRCM APIs and "XDC ASSERT" in the log.

Or, if I can not use these APIs to meassure "power comsumption" on SW side, tell me the way to get the power state of the chip.

And I want to research PM HAL interface to check PM function body if it is possible... .  Is there the way to research this layer??

Thank you.
  

  • Hi,

    can you check chapter "7.4 Reading Power State and Clock Frequency of the system" in PROCESSOR_SDK_VISION_03_XX_XX\vision_sdk\docs\FeatureSpecificUserGuides\VisionSDK_DevelopmentGuide.pdf.

    Also this document might be useful: PROCESSOR_SDK_VISION_03_XX_XX\vision_sdk\docs\TrainingSlides\PowerManagementSoftwareIntroduction.pdf and this Application Note:
    proddms.itg.ti.com/.../sprac22.pdf

    Regards,
    Yordan
  • Hi Yordan

    As you said, I already tried to use prcm APIs such as "Utils_prcmPrintAllVoltageValues()" in PROCESSOR_SDK_VISION_03_XX_XX\vision_sdk\docs\FeatureSpecificUserGuides\VisionSDK_DevelopmentGuide.pdf.
    But these APIs are not working....
    Fail log as shown below

    [HOST] [IPU2 ] 18.831147 s: Voltage Rail || Voltage
    [HOST] [IPU2 ] 18.831208 s: ---------------------------------------------------------
    [HOST] [IPU2 ] 18.831299 s: UTILS_PRCM_STATS: Get Voltage Failed!!
    [HOST] [IPU2 ] 18.831360 s: UTILS_PRCM_STATS: Get Voltage Failed!!
    [HOST] [IPU2 ] 18.831421 s: UTILS_PRCM_STATS: Get Voltage Failed!!

    Can you tell me another information?
  • Hi,

    Have you set up the I2C to read the PMIC registers for reading the voltage?

    Also, there is a training video for PM, to help you understand the PDK PMHAL.

    Thanks and Regards,
    Piyali
  • Hi,,

    Have you set up the PMIC and the I2C for the voltage reading?

    For example call Utils_prcmClockRateInit before calling the voltage read.

    You would also find some details in the training video: training.ti.com/introduction-adas-power-management-software

    Thanks and Regards,
    Piyali
  • Hi ~

    I tried to use below functions to ready to call voltage read.
    - Utils_prcmClockRateInit();
    - Utils_prcmPrintPowerConsumptionInit();

    But after running APP, I still faced with xdc assert.

    [HOST] [IPU2 ] 18.846275 s: ### XDC ASSERT - ERROR CALLBACK START ###
    [HOST] [IPU2 ] 18.846336 s:
    [HOST] [IPU2 ] 18.846489 s: E_hardFault: FORCED
    [HOST] [IPU2 ] 18.846550 s:
    [HOST] [IPU2 ] 18.846580 s: ### XDC ASSERT - ERROR CALLBACK END ###
    [HOST] [IPU2 ] 18.846641 s:
    [HOST] [IPU2 ] 18.846855 s:
    [HOST] [IPU2 ] 18.846885 s: ### XDC ASSERT - ERROR CALLBACK START ###
    [HOST] [IPU2 ] 18.846946 s:
    [HOST] [IPU2 ] 18.847068 s: E_busFault: PRECISERR: Immediate Bus Fault, exact addr known, address: 48060010
    [HOST] [IPU2 ] 18.847160 s:
    [HOST] [IPU2 ] 18.847190 s: ### XDC ASSERT - ERROR CALLBACK END ###


    Please kindly explain XDC ASERRT.
    I think ...
    I am not using these APIs properly as well as missing another things such as build env, board configuration and etc~.

    Board : TDA2PX EVM
    Build : Debug build


    Thank you.
  • Hi,

    sorry for the delayed reply. Which build config you use? If you use "tda2px_evm_linux_all" can you do the following experiment: modify apps/configs/tda2px_evm_linux_all/cfg.mk and set "ULTRASONIC_INCLUDE=no" instead of "yes" and see if there is a change in the behavior?

    Regards,
    Yordan
  • Hi,

    I haven't heard back from you, I'm assuming you were able to resolve your issue.
    If not, just post a reply below (or create a new thread if the thread has locked due to time-out).

    Regards,
    Yordan