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.

AM5728: How to use TimeStamp in SMP/BIOS

Part Number: AM5728
Other Parts Discussed in Thread: SYSBIOS

Hi experts,

How do I use TimeStamp in SMP/BIOS?
I would like to know the sample project or documentation.

HW: AM572x EVM
SW: processor_sdk_rtos_am57xx_6_01_00_08,  bios_6_76_02_02

Best regards,
Sasaki

  • Additional information.

    My customer has added the following two lines to the Host.cfg file.

    var Timestamp = xdc.useModule('xdc.runtime.Timestamp');
    Timestamp.SupportProxy = xdc.useModule('ti.sysbios.family.arm.a15.TimestampProvider');

    And they have confirmed that the core0 timestamp works properly.
    However, the core1's timestamp display value is not counted and cannot be used. What do they need to do to enable timestamp on the core1?

    Best regards,
    Sasaki

  • Hi Sasaki,

    Can you take a look at and change to timer64 ? There are some additional resources within that page.

    Regards

    Vineet

  • Hi Vineet-san,

    Thank you for your reply.

    I have asked my customer to change to timer64
    My customer changed to timer64 and when they built it, they got the following error.

    "Timers unsupported on device!"

    For AM572x, how they should define Timestamp in Host.cfgt?

    Best regards,
    Sasaki

     

  • Hi Sasaki-san

    Is this a compile time warning ? I will try to reproduce and let you know.

    Regards

    Vineet

  • Hi Vineet-san,

    Thank you for your reply.

    Vineet Roy said:
    Is this a compile time warning ? I will try to reproduce and let you know.

    Yes. It's an error during a compile.

    Please let me know when you get progress.

    Best regards,
    Sasaki

  • Hi Vineet-san,

    Do you have any update?

    Thanks & regards,
    Sasaki

  • Hi Sasaki san,

    Unfortunately no. I will check asap.

    Regards

    Vineet

  • Hi Sasaki san,

    Again, apologies for the delay.

    You can use the following two lines instead

    var Timestamp         = xdc.useModule('xdc.runtime.Timestamp');
    Timestamp.SupportProxy = xdc.useModule('ti.sysbios.timers.dmtimer.TimestampProvider');

    I verified it by compiling the sample SMP application provided with AM5 PDK. EMAC_BasicExample_evmAM572x_SMP_armBiosExampleProject

    Regards

    Vineet

  • Hi Vineet san,

    Thank you for your support.

    I will contact the customer to try this description.

    Best regards,
    Sasaki

  • Hi Vineet-san,

    Vineet Roy said:

    You can use the following two lines instead

    var Timestamp         = xdc.useModule('xdc.runtime.Timestamp');
    Timestamp.SupportProxy = xdc.useModule('ti.sysbios.timers.dmtimer.TimestampProvider');

    I verified it by compiling the sample SMP application provided with AM5 PDK. EMAC_BasicExample_evmAM572x_SMP_armBiosExampleProject

    We have confirmed the above with our customers.

    However, the following problems are occurring.

    My customer prepares a 10 msec delay function and measures the execution time of this function in timestamp.
    Then the value of timestamp value will be 199827.We believe that a timestamp clock of 20MHz would give the correct result, but the customer's CPU clock is 1GHz.
    By the way, if they measure this 10 msec delay function using GPIO, they can observe 10 msec correctly.

    I have 2 question.

    • Is the Timestamp clocked at 20 MHz?
    • Do you know why 10 msec of time is 199827?

    Best regards,
    Sasaki

  • Hi Sasaki san,

    Can you try with value of 19.2 Mhz ? Default DM Timer frequency is configured in GEL files (if running on CCS) or in Bootloader (for SD card binary) or in CSL init code (baremetal app).

    BIOS records this frequency and configures the timer to the same value at startup. Any app using the timer must also do the same.

    Let's check the 10msec value with this clock frequency.

    Regards

    Vineet