source: rtems/c/src/ada/rtems-event.adb @ 1987020

4.115
Last change on this file since 1987020 was 1987020, checked in by Joel Sherrill <joel.sherrill@…>, on Feb 16, 2011 at 3:52:29 PM

2011-02-16 Joel Sherrill <joel.sherrill@…>

  • ada/Makefile.am, ada/preinstall.am, ada/rtems.adb, ada/rtems.ads: Split RTEMS Ada95 binding into a master package and a child package per Manager. This is better Ada style.
  • ada/rtems-barrier.adb, ada/rtems-barrier.ads, ada/rtems-clock.adb, ada/rtems-clock.ads, ada/rtems-cpu_usage.ads, ada/rtems-debug.adb, ada/rtems-debug.ads, ada/rtems-event.adb, ada/rtems-event.ads, ada/rtems-extension.adb, ada/rtems-extension.ads, ada/rtems-fatal.adb, ada/rtems-fatal.ads, ada/rtems-interrupt.ads, ada/rtems-io.adb, ada/rtems-io.ads, ada/rtems-message_queue.adb, ada/rtems-message_queue.ads, ada/rtems-object.adb, ada/rtems-object.ads, ada/rtems-partition.adb, ada/rtems-partition.ads, ada/rtems-port.adb, ada/rtems-port.ads, ada/rtems-rate_monotonic.adb, ada/rtems-rate_monotonic.ads, ada/rtems-region.adb, ada/rtems-region.ads, ada/rtems-semaphore.adb, ada/rtems-semaphore.ads, ada/rtems-signal.adb, ada/rtems-signal.ads, ada/rtems-stack_checker.ads, ada/rtems-tasks.adb, ada/rtems-tasks.ads, ada/rtems-timer.adb, ada/rtems-timer.ads: New files.
  • Property mode set to 100644
File size: 1.6 KB
Line 
1--
2--  RTEMS / Body
3--
4--  DESCRIPTION:
5--
6--  This package provides the interface to the RTEMS API.
7--
8--
9--  DEPENDENCIES:
10--
11--
12--
13--  COPYRIGHT (c) 1997-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.com/license/LICENSE.
19--
20--  $Id$
21--
22
23package body RTEMS.Event is
24
25   --
26   -- Event Manager
27   --
28
29   procedure Send
30     (ID       : in RTEMS.ID;
31      Event_In : in RTEMS.Event_Set;
32      Result   : out RTEMS.Status_Codes)
33   is
34      function Send_Base
35        (ID       : RTEMS.ID;
36         Event_In : RTEMS.Event_Set)
37         return     RTEMS.Status_Codes;
38      pragma Import (C, Send_Base, "rtems_event_send");
39   begin
40
41      Result := Send_Base (ID, Event_In);
42
43   end Send;
44
45   procedure Receive
46     (Event_In   : in RTEMS.Event_Set;
47      Option_Set : in RTEMS.Option;
48      Ticks      : in RTEMS.Interval;
49      Event_Out  : out RTEMS.Event_Set;
50      Result     : out RTEMS.Status_Codes)
51   is
52      function Receive_Base
53        (Event_In   : RTEMS.Event_Set;
54         Option_Set : RTEMS.Option;
55         Ticks      : RTEMS.Interval;
56         Event_Out  : access RTEMS.Event_Set)
57         return       RTEMS.Status_Codes;
58      pragma Import (C, Receive_Base, "rtems_event_receive");
59      Event_Out_Base : aliased RTEMS.Event_Set;
60   begin
61
62      Result    :=
63         Receive_Base
64           (Event_In,
65            Option_Set,
66            Ticks,
67            Event_Out_Base'Access);
68      Event_Out := Event_Out_Base;
69
70   end Receive;
71
72end RTEMS.Event;
Note: See TracBrowser for help on using the repository browser.