File indexing completed on 2025-05-11 08:23:47
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018 #include <rtems.h>
0019 #include <rtems/btimer.h>
0020 #include <bsp.h>
0021
0022 void benchmark_timer_initialize(void)
0023 {
0024 uint32_t preScaleDivisor = bsp_get_CPU_clock_speed() / 1000000;
0025
0026 MCF_DTIM3_DTMR = 0;
0027 MCF_DTIM3_DTMR = MCF_DTIM_DTMR_PS(preScaleDivisor - 1) |
0028 MCF_DTIM_DTMR_CLK_DIV1 | MCF_DTIM_DTMR_RST;
0029 }
0030
0031
0032
0033
0034 benchmark_timer_t benchmark_timer_read(void)
0035 {
0036 return MCF_DTIM3_DTCN;
0037 }
0038
0039 void benchmark_timer_disable_subtracting_average_overhead(bool find_flag)
0040 {
0041 }