[5d0f4a56] | 1 | -- |
---|
| 2 | -- Timer_Driver / Specification |
---|
| 3 | -- |
---|
| 4 | -- Description: |
---|
| 5 | -- |
---|
| 6 | -- This package is the specification for the Timer Driver. |
---|
| 7 | -- |
---|
| 8 | -- Dependencies: |
---|
| 9 | -- |
---|
| 10 | -- |
---|
| 11 | -- |
---|
| 12 | -- COPYRIGHT (c) 1989-1997. |
---|
| 13 | -- On-Line Applications Research Corporation (OAR). |
---|
| 14 | -- Copyright assigned to U.S. Government, 1994. |
---|
| 15 | -- |
---|
| 16 | -- The license and distribution terms for this file may in |
---|
| 17 | -- the file LICENSE in this distribution or at |
---|
| 18 | -- http://www.OARcorp.com/rtems/license.html. |
---|
| 19 | -- |
---|
| 20 | -- $Id$ |
---|
| 21 | -- |
---|
| 22 | |
---|
| 23 | with RTEMS; |
---|
| 24 | |
---|
| 25 | package Timer_Driver is |
---|
| 26 | |
---|
| 27 | -- |
---|
| 28 | -- Initialize |
---|
| 29 | -- |
---|
| 30 | -- Description: |
---|
| 31 | -- |
---|
| 32 | -- This subprogram initializes the hardware timer to start it. |
---|
| 33 | -- |
---|
| 34 | |
---|
| 35 | procedure Initialize; |
---|
| 36 | pragma Import (C, Initialize, "Timer_initialize"); |
---|
| 37 | |
---|
| 38 | -- |
---|
| 39 | -- Read_Timer |
---|
| 40 | -- |
---|
| 41 | -- Description: |
---|
| 42 | -- |
---|
| 43 | -- This subprogram stops the timer, calculates the length of time |
---|
| 44 | -- in microseconds since the timer was started, and returns that |
---|
| 45 | -- value. |
---|
| 46 | -- |
---|
| 47 | |
---|
| 48 | function Read_Timer |
---|
| 49 | return RTEMS.Unsigned32; |
---|
| 50 | pragma Import (C, Read_Timer, "Read_timer"); |
---|
| 51 | |
---|
| 52 | -- |
---|
| 53 | -- Empty_Function |
---|
| 54 | -- |
---|
| 55 | -- Description: |
---|
| 56 | -- |
---|
| 57 | -- This subprogram is an empty subprogram. It is used to |
---|
| 58 | -- insure that a loop will be included in the final executable |
---|
| 59 | -- so that loop overhead can be subtracted from the directive |
---|
| 60 | -- times reported. |
---|
| 61 | -- |
---|
| 62 | |
---|
| 63 | procedure Empty_Function; |
---|
| 64 | pragma Import (C, Empty_Function, "Empty_function"); |
---|
| 65 | |
---|
| 66 | -- |
---|
| 67 | -- Set_Find_Average_Overhead |
---|
| 68 | -- |
---|
| 69 | -- Description: |
---|
| 70 | -- |
---|
| 71 | -- This subprogram sets the Find_Average_Overhead flag to the |
---|
| 72 | -- the value passed. |
---|
| 73 | -- |
---|
| 74 | |
---|
| 75 | procedure Set_Find_Average_Overhead ( |
---|
| 76 | Find_Flag : in Standard.Boolean |
---|
| 77 | ); |
---|
| 78 | |
---|
| 79 | private |
---|
| 80 | |
---|
| 81 | end Timer_Driver; |
---|