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.

Timer resolution of loggerSMDump.out run on 816x

Hi

I'm working with EVM 816x. I just want know what the timer resolution of loggerSMDump.out run on 816x is. That is, what does the 'timestamp' stand for?

For example, when we use loggerSMDump.out  to see the log of Video firmware, we get something like:

./../ti-uia/loggerSMDump.out 0x9E400000 video

N:Video P:1 #:00035 T:00000005|38d21bb3 S:main: calling RcmClient_getSymbolIndex(OmxRpcGetHandle)
N:Video P:1 #:00036 T:00000005|38d47aeb S:main: calling RcmClient_getSymbolIndex(OmxRpcFreeHandle)
N:Video P:1 #:00037 T:00000005|38d661bb S:main: calling RcmClient_getSymbolIndex(OmxRpcCreateProxyLite)
N:Video P:1 #:00038 T:00000005|38d8611d S:main: calling RcmClient_getSymbolIndex(OmxRpcGetHeapMemStats)
N:Video P:1 #:00039 T:00000005|38da4b85 S:main: calling RcmClient_getSymbolIndex(OmxRpcDeleteProxyLite)

The article here says:

N:MediaControllerName P:PartitionId #:SequenceId T:64bit timestamp S:Print_from_media_controller

But it doesn't say what the 'timestamp' means.

Q1. Is the timestamp here simply the time sample of CPU cycle? or does it mean something else?

Q2. I guess the firmware is running on ARM M3 core. So if Q1 is true, shall we use the frequence of M3 to get the realtime value?

Q3. How many the frequence of M3 is? I can't find it on datasheet.

  • Please find the answers below

     

    Q1. Is the timestamp here simply the time sample of CPU cycle? or does it mean something else?

    @ This timestamp value is generated from a 64 bit timer, whose clock frequency is 500 MHz. The timestamp does not represent the CPU cycles.

    Q2. I guess the firmware is running on ARM M3 core. So if Q1 is true, shall we use the frequence of M3 to get the realtime value?

    @The 64 bit timestamp is more useful to calculate the realtime values between various events  . For ex in the given log

    N:Video P:1 #:00035 T:00000005|38d21bb3 S:main: calling RcmClient_getSymbolIndex(OmxRpcGetHandle)
    N:Video P:1 #:00036 T:00000005|38d47aeb S:main: calling RcmClient_getSymbolIndex(OmxRpcFreeHandle)
    N:Video P:1 #:00037 T:00000005|38d661bb S:main: calling RcmClient_getSymbolIndex(OmxRpcCreateProxyLite)
    N:Video P:1 #:00038 T:00000005|38d8611d S:main: calling RcmClient_getSymbolIndex(OmxRpcGetHeapMemStats)
    N:Video P:1 #:00039 T:00000005|38da4b85 S:main: calling RcmClient_getSymbolIndex(OmxRpcDeleteProxyLite)

    OmxRpcGetHandle event occured at 00000005|38d21bb3 and OmxRpcFreeHandle occured at 00000005|38d47aeb. The actual real time value is

    00000005|38d47aeb - 00000005|38d21bb3 = 155448 ticks. 

    The difference ticks value divided by 500MHz gives the actual real time values in msec

    = 155448/500000

    = 0.31 msec ( This is the time difference between the two events OmxRpcFreeHandle and OmxRpcGetHandle)

     

    Q3. How many the frequence of M3 is? I can't find it on datasheet.

    M3 frequency is 250 MHz

     

    Regards

    Ansari

  • Hi Ansari,

    Thank so much for the detailed help. Just two more things.

    When you say the clock freq of the timer is 500MHz, what about the freq of Cortex-A8? Is it a 1GHz A8?

    I'm using a 1.2GHz A8, so the freq of my timer should be 600MHz = 500 * 1.2 MHz, isn't it?

    Thank you!

    Zhang

     

  • Zhang,

    The 64 bit timer is not related to Cortex-A8 frequency.  It is a Media Controller unicache timer. Please refer to DM816x TRM for details

     

    Regards

    Ansari

  • Hi Ansari,

    I want to use this 64bit timer on M3 side for Video capture driver timestamping. Can i use this approach? If so, can you please point out which function should i be calling to get the 64bit timer value on M3 side?

    Currently the video capture timestamp resolution is in millisecond. Has anybody tried using 64bit timestamp for video capture timestamping?

    Thank you.

     

    Regards,

    Santosh