source: rtems/c/src/ada-tests/sptests/sp16/sptest.ads @ 6d4e604b

4.104.114.84.95
Last change on this file since 6d4e604b was 6d4e604b, checked in by Joel Sherrill <joel.sherrill@…>, on Jun 2, 1997 at 8:19:03 PM

Initial revision

  • Property mode set to 100644
File size: 6.1 KB
Line 
1--
2--  SPTEST / SPECIFICATION
3--
4--  DESCRIPTION:
5--
6--  This package is the specification for Test 16 of the RTEMS
7--  Single Processor Test Suite.
8--
9--  DEPENDENCIES:
10--
11-- 
12--
13--  COPYRIGHT (c) 1989, 1990, 1991, 1992, 1993, 1994.
14--  On-Line Applications Research Corporation (OAR).
15--  All rights assigned to U.S. Government, 1994.
16--
17--  This material may be reproduced by or for the U.S. Government pursuant
18--  to the copyright license under the clause at DFARS 252.227-7013.  This
19--  notice must appear in all copies of this file and its derivatives.
20--
21--  sptest.ads,v 1.3 1995/07/12 19:42:11 joel Exp
22--
23
24with CLOCK_DRIVER;
25with RTEMS;
26
27package SPTEST is
28
29--
30--  These arrays contain the IDs and NAMEs of all RTEMS tasks created
31--  by this test.
32--
33
34   TASK_ID   : array ( RTEMS.UNSIGNED32 range 1 .. 5 ) of RTEMS.ID;
35   TASK_NAME : array ( RTEMS.UNSIGNED32 range 1 .. 5 ) of RTEMS.NAME;
36
37--
38--  These arrays contain the IDs and NAMEs of all RTEMS regions created
39--  by this test.
40--
41
42   REGION_ID   : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.ID;
43   REGION_NAME : array ( RTEMS.UNSIGNED32 range 1 .. 3 ) of RTEMS.NAME;
44
45--
46--  The following constant defines the priority of most of the
47--  RTEMS tasks in this test.  This allows one of the tasks to
48--  easily set itself to a higher priority than the rest.
49--
50
51   BASE_PRIORITY : constant RTEMS.TASK_PRIORITY := 140;
52
53--
54--  These arrays define the memory areas used for the regions in
55--  this test.
56--
57
58   AREA_1 : array ( RTEMS.UNSIGNED32 range 0 .. 4095 ) of RTEMS.UNSIGNED8;
59   for AREA_1'ALIGNMENT use RTEMS.STRUCTURE_ALIGNMENT;
60
61   AREA_2 : array ( RTEMS.UNSIGNED32 range 0 .. 4095 ) of RTEMS.UNSIGNED8;
62   for AREA_2'ALIGNMENT use RTEMS.STRUCTURE_ALIGNMENT;
63
64   AREA_3 : array ( RTEMS.UNSIGNED32 range 0 .. 4095 ) of RTEMS.UNSIGNED8;
65   for AREA_3'ALIGNMENT use RTEMS.STRUCTURE_ALIGNMENT;
66
67--
68--  INIT
69--
70--  DESCRIPTION:
71--
72--  This RTEMS task initializes the application.
73--
74
75   procedure INIT (
76      ARGUMENT : in     RTEMS.TASK_ARGUMENT
77   );
78
79--
80--  PUT_ADDRESS_FROM_AREA_1
81--
82--  DESCRIPTION:
83--
84--  This subprogram prints the offset of the address TO_BE_PRINTED
85--  from the first byte of AREA_1.
86--
87--  NOTE:
88--
89--  This subprogram is used because the actual address of AREA_1
90--  varies based upon the size of the executable, the target board,
91--  and the target processor.
92--
93
94   procedure PUT_ADDRESS_FROM_AREA_1 (
95      TO_BE_PRINTED : in     RTEMS.ADDRESS
96   );
97
98--
99--  PUT_ADDRESS_FROM_AREA_2
100--
101--  DESCRIPTION:
102--
103--  This subprogram prints the offset of the address TO_BE_PRINTED
104--  from the first byte of AREA_2.
105--
106--  NOTE:
107--
108--  This subprogram is used because the actual address of AREA_2
109--  varies based upon the size of the executable, the target board,
110--  and the target processor.
111--
112
113   procedure PUT_ADDRESS_FROM_AREA_2 (
114      TO_BE_PRINTED : in     RTEMS.ADDRESS
115   );
116
117--
118--  PUT_ADDRESS_FROM_AREA_3
119--
120--  DESCRIPTION:
121--
122--  This subprogram prints the offset of the address TO_BE_PRINTED
123--  from the first byte of AREA_3.
124--
125--  NOTE:
126--
127--  This subprogram is used because the actual address of AREA_3
128--  varies based upon the size of the executable, the target board,
129--  and the target processor.
130--
131
132   procedure PUT_ADDRESS_FROM_AREA_3 (
133      TO_BE_PRINTED : in     RTEMS.ADDRESS
134   );
135
136--
137--  TASK_1
138--
139--  DESCRIPTION:
140--
141--  This RTEMS task tests the Region Manager.
142--
143
144   procedure TASK_1 (
145      ARGUMENT : in     RTEMS.TASK_ARGUMENT
146   );
147
148--
149--  TASK_2
150--
151--  DESCRIPTION:
152--
153--  This RTEMS task tests the Region Manager.
154--
155
156   procedure TASK_2 (
157      ARGUMENT : in     RTEMS.TASK_ARGUMENT
158   );
159
160--
161--  TASK_3
162--
163--  DESCRIPTION:
164--
165--  This RTEMS task tests the Region Manager.
166--
167
168   procedure TASK_3 (
169      ARGUMENT : in     RTEMS.TASK_ARGUMENT
170   );
171
172--
173--  TASK_4
174--
175--  DESCRIPTION:
176--
177--  This RTEMS task tests the Region Manager.
178--
179
180   procedure TASK_4 (
181      ARGUMENT : in     RTEMS.TASK_ARGUMENT
182   );
183
184--
185--  TASK_5
186--
187--  DESCRIPTION:
188--
189--  This RTEMS task tests the Region Manager.
190--
191
192   procedure TASK_5 (
193      ARGUMENT : in     RTEMS.TASK_ARGUMENT
194   );
195
196--
197--  This is the Driver Address Table for this test.
198--
199
200   DEVICE_DRIVERS : aliased RTEMS.DRIVER_ADDRESS_TABLE( 1 .. 1 ) :=
201   (1=>
202      (
203        CLOCK_DRIVER.INITIALIZE'ACCESS,              -- Initialization
204        RTEMS.NO_DRIVER_ENTRY,                       -- Open
205        RTEMS.NO_DRIVER_ENTRY,                       -- Close
206        RTEMS.NO_DRIVER_ENTRY,                       -- Read
207        RTEMS.NO_DRIVER_ENTRY,                       -- Write
208        RTEMS.NO_DRIVER_ENTRY                        -- Control
209      )
210   );
211
212--
213--  This is the Initialization Tasks Table for this test.
214--
215
216   INITIALIZATION_TASKS : aliased RTEMS.INITIALIZATION_TASKS_TABLE( 1 .. 1 ) := 
217   (1=>
218     (
219       RTEMS.BUILD_NAME( 'U', 'I', '1', ' ' ),        -- task name
220       2048,                                          -- stack size
221       1,                                             -- priority
222       RTEMS.DEFAULT_ATTRIBUTES,                      -- attributes
223       SPTEST.INIT'ACCESS,                            -- entry point
224       RTEMS.NO_PREEMPT,                              -- initial mode
225       0                                              -- argument list
226     )
227   );
228
229--
230--  This is the Configuration Table for this test.
231--
232
233   CONFIGURATION : aliased RTEMS.CONFIGURATION_TABLE := (
234      RTEMS.NULL_ADDRESS,        -- will be replaced by BSP
235      64 * 1024,                 -- executive RAM size
236      10,                        -- maximum # tasks
237      0,                         -- maximum # timers
238      0,                         -- maximum # semaphores
239      0,                         -- maximum # message queues
240      0,                         -- maximum # messages
241      0,                         -- maximum # partitions
242      3,                         -- maximum # regions
243      0,                         -- maximum # dp memory areas
244      0,                         -- maximum # periods
245      0,                         -- maximum # user extensions
246      RTEMS.MILLISECONDS_TO_MICROSECONDS(10), -- # us in a tick
247      100                        -- # ticks in a timeslice
248  );
249
250end SPTEST;
Note: See TracBrowser for help on using the repository browser.