Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @ingroup RTEMSBSPsARMLPC176X |
---|
5 | * |
---|
6 | * @brief Timer benchmark functions for the lpc176x bsp. |
---|
7 | */ |
---|
8 | |
---|
9 | /* |
---|
10 | * Copyright (c) 2014 Taller Technologies. |
---|
11 | * |
---|
12 | * @author Boretto Martin (martin.boretto@tallertechnologies.com) |
---|
13 | * @author Diaz Marcos (marcos.diaz@tallertechnologies.com) |
---|
14 | * @author Lenarduzzi Federico (federico.lenarduzzi@tallertechnologies.com) |
---|
15 | * @author Daniel Chicco (daniel.chicco@tallertechnologies.com) |
---|
16 | * |
---|
17 | * The license and distribution terms for this file may be |
---|
18 | * found in the file LICENSE in this distribution or at |
---|
19 | * http://www.rtems.org/license/LICENSE. |
---|
20 | */ |
---|
21 | |
---|
22 | #include <rtems.h> |
---|
23 | #include <bsp.h> |
---|
24 | #include <rtems/btimer.h> |
---|
25 | |
---|
26 | #include <bsp/timer.h> |
---|
27 | |
---|
28 | static uint32_t benchmark_timer_base; |
---|
29 | |
---|
30 | void benchmark_timer_initialize( void ) |
---|
31 | { |
---|
32 | benchmark_timer_base = lpc176x_timer_get_timer_value( LPC176X_TIMER_1 ); |
---|
33 | } |
---|
34 | |
---|
35 | benchmark_timer_t benchmark_timer_read( void ) |
---|
36 | { |
---|
37 | uint32_t delta = lpc176x_timer_get_timer_value( LPC176X_TIMER_1 ) - |
---|
38 | benchmark_timer_base; |
---|
39 | |
---|
40 | return delta; |
---|
41 | } |
---|
42 | |
---|
43 | void benchmark_timer_disable_subtracting_average_overhead( bool find_avg_ovhead ) |
---|
44 | { |
---|
45 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.