Counter vs Btimer for tmtests

Sebastian Huber sebastian.huber at embedded-brains.de
Wed Nov 7 18:00:39 UTC 2018


----- Am 7. Nov 2018 um 18:13 schrieb joel joel at rtems.org:

> Hi
> 
> Do these report the same units?

Not necessarily.

> 
> If not, there are only *tmtests which use rtems/counter.h and thus would be
> reporting numbers with different units than the btimer.

You can convert the counter value to nanoseconds:

https://docs.rtems.org/doxygen/branches/master/group__ClassicCounter.html#ga3e50a042e60bfcafdff5dbd46cad8947

This is used by some tests for the XML output which can be used to plot some graphs:

https://git.rtems.org/rtems/tree/testsuites/tmtests/tmcontext01/tmcontext01.scn
https://git.rtems.org/rtems/tree/testsuites/tmtests/tmcontext01/plot.py


More information about the devel mailing list