source: rtems/c/src/ada-tests/tmtests/tm13/tmtest.ads @ c499856

4.115
Last change on this file since c499856 was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 2.5 KB
Line 
1--
2--  TMTEST / SPECIFICATION
3--
4--  DESCRIPTION:
5--
6--  This package is the specification for Test 13 of the RTEMS
7--  Timing Test Suite.
8--
9--  DEPENDENCIES:
10--
11-- 
12--
13--  COPYRIGHT (c) 1989-2011.
14--  On-Line Applications Research Corporation (OAR).
15--
16--  The license and distribution terms for this file may in
17--  the file LICENSE in this distribution or at
18--  http://www.rtems.org/license/LICENSE.
19--
20
21with RTEMS;
22with RTEMS.TASKS;
23
24package TMTEST is
25
26--
27--  Buffer Record similar to that used by RTEMS 3.2.1.  Using this
28--  avoids changes to the test.
29--
30
31   type BUFFER is
32      record
33         FIELD1 : RTEMS.UNSIGNED32;   -- TEMPORARY UNTIL VARIABLE LENGTH
34         FIELD2 : RTEMS.UNSIGNED32;
35         FIELD3 : RTEMS.UNSIGNED32;
36         FIELD4 : RTEMS.UNSIGNED32;
37      end record;
38
39--
40--  The following is the ID of the message queue used for timing operations.
41--
42
43   QUEUE_ID : RTEMS.ID;
44
45--
46--  The following variable is set to the execution time returned
47--  by the timer.
48--
49
50   END_TIME  : RTEMS.UNSIGNED32;
51
52--
53--  INIT
54--
55--  DESCRIPTION:
56--
57--  This RTEMS task initializes the application.
58--
59
60   procedure INIT (
61      ARGUMENT : in     RTEMS.TASKS.ARGUMENT
62   );
63   pragma Convention (C, INIT);
64
65--
66--  TEST_INIT
67--
68--  DESCRIPTION:
69--
70--  This subprogram performs test initialization.  As each application
71--  task is created and started, it will preempt this task and
72--  perform a blocking MESSAGE_QUEUE_RECEIVE.  Once all of the
73--  initialization is completed, the timer is started and the first
74--  preemptive MESSAGE_QUEUE_URGENT is executed.
75--
76
77   procedure TEST_INIT (
78      ARGUMENT : in     RTEMS.TASKS.ARGUMENT
79   );
80   pragma Convention (C, TEST_INIT);
81
82--
83--  HIGH_TASK
84--
85--  DESCRIPTION:
86--
87--  This RTEMS task is the highest priority task in the system. 
88--  It performs a blocking blocking MESSAGE_QUEUE_RECEIVE.  It is
89--  the last test task created and started.  Thus it is the last
90--  task to be enqueued waiting for a message and the last task
91--  to receive the message.  Once it receives the message, it
92--  stops the timer and reports the execution time for a
93--  preemptive MESSAGE_QUEUE_URGENT.
94--
95
96   procedure HIGH_TASK (
97      ARGUMENT : in     RTEMS.TASKS.ARGUMENT
98   );
99   pragma Convention (C, HIGH_TASK);
100
101--
102--  MIDDLE_TASKS
103--
104--  DESCRIPTION:
105--
106--  As each of these RTEMS tasks is created and started, it preempts
107--  the initialization task and perform a blocking MESSAGE_QUEUE_RECEIVE.
108--
109
110   procedure MIDDLE_TASKS (
111      ARGUMENT : in     RTEMS.TASKS.ARGUMENT
112   );
113   pragma Convention (C, MIDDLE_TASKS);
114
115end TMTEST;
Note: See TracBrowser for help on using the repository browser.