source: rtems/cpukit/rtems/include/rtems/rtems/event.h @ 067a96a

4.104.114.95
Last change on this file since 067a96a was 067a96a, checked in by Joel Sherrill <joel.sherrill@…>, on 04/18/08 at 15:02:20

2008-04-18 Joel Sherrill <joel.sherrill@…>

  • rtems/include/rtems.h, rtems/include/rtems/rtems/asr.h, rtems/include/rtems/rtems/attr.h, rtems/include/rtems/rtems/barrier.h, rtems/include/rtems/rtems/barriermp.h, rtems/include/rtems/rtems/cache.h, rtems/include/rtems/rtems/clock.h, rtems/include/rtems/rtems/config.h, rtems/include/rtems/rtems/dpmem.h, rtems/include/rtems/rtems/event.h, rtems/include/rtems/rtems/eventmp.h, rtems/include/rtems/rtems/eventset.h, rtems/include/rtems/rtems/intr.h, rtems/include/rtems/rtems/message.h, rtems/include/rtems/rtems/modes.h, rtems/include/rtems/rtems/mp.h, rtems/include/rtems/rtems/msgmp.h, rtems/include/rtems/rtems/object.h, rtems/include/rtems/rtems/options.h, rtems/include/rtems/rtems/part.h, rtems/include/rtems/rtems/partmp.h, rtems/include/rtems/rtems/ratemon.h, rtems/include/rtems/rtems/region.h, rtems/include/rtems/rtems/regionmp.h, rtems/include/rtems/rtems/rtemsapi.h, rtems/include/rtems/rtems/sem.h, rtems/include/rtems/rtems/semmp.h, rtems/include/rtems/rtems/signal.h, rtems/include/rtems/rtems/signalmp.h, rtems/include/rtems/rtems/status.h, rtems/include/rtems/rtems/support.h, rtems/include/rtems/rtems/taskmp.h, rtems/include/rtems/rtems/tasks.h, rtems/include/rtems/rtems/timer.h, rtems/include/rtems/rtems/types.h, rtems/inline/rtems/rtems/asr.inl, rtems/inline/rtems/rtems/attr.inl, rtems/inline/rtems/rtems/barrier.inl, rtems/inline/rtems/rtems/dpmem.inl, rtems/inline/rtems/rtems/event.inl, rtems/inline/rtems/rtems/eventset.inl, rtems/inline/rtems/rtems/message.inl, rtems/inline/rtems/rtems/modes.inl, rtems/inline/rtems/rtems/options.inl, rtems/inline/rtems/rtems/part.inl, rtems/inline/rtems/rtems/ratemon.inl, rtems/inline/rtems/rtems/region.inl, rtems/inline/rtems/rtems/sem.inl, rtems/inline/rtems/rtems/status.inl, rtems/inline/rtems/rtems/support.inl, rtems/inline/rtems/rtems/tasks.inl, rtems/inline/rtems/rtems/timer.inl: Initial conversion of Classic API header files to Doxygen.
  • rtems/Doxyfile: New file.
  • Property mode set to 100644
File size: 4.0 KB
Line 
1/**
2 * @file rtems/rtems/event.h
3 *
4 *  This include file contains the information pertaining to the Event
5 *  Manager.  This manager provides a high performance method of communication
6 *  and synchronization.
7 *
8 *  Directives provided are:
9 *
10 *     - send an event set to a task
11 *     - receive event condition
12 *
13 */
14
15/*  COPYRIGHT (c) 1989-2008.
16 *  On-Line Applications Research Corporation (OAR).
17 *
18 *  The license and distribution terms for this file may be
19 *  found in the file LICENSE in this distribution or at
20 *  http://www.rtems.com/license/LICENSE.
21 *
22 *  $Id$
23 */
24
25#ifndef _RTEMS_RTEMS_EVENT_H
26#define _RTEMS_RTEMS_EVENT_H
27
28#ifndef RTEMS_EVENT_EXTERN
29#define RTEMS_EVENT_EXTERN extern
30#endif
31
32#ifdef __cplusplus
33extern "C" {
34#endif
35
36#include <rtems/score/object.h>
37#include <rtems/rtems/status.h>
38#include <rtems/rtems/types.h>
39#include <rtems/rtems/options.h>
40#include <rtems/score/thread.h>
41#include <rtems/score/threadsync.h>
42#include <rtems/score/watchdog.h>
43#include <rtems/rtems/eventset.h>
44
45/**
46 *  @defgroup ClassicEvent Classic API Event
47 *
48 *  This encapsulates functionality which XXX
49 */
50/**@{*/
51
52/**
53 *  This constant is passed as the event_in to the
54 *  rtems_event_receive directive to determine which events are pending.
55 */
56#define EVENT_CURRENT  0
57
58/**
59 *  @brief Event_Manager_initialization
60 *
61 *  This routine performs the initialization necessary for this manager.
62 */
63void _Event_Manager_initialization( void );
64
65/**
66 *  @brief rtems_event_send
67 *
68 *  This routine implements the rtems_event_send directive.  It sends
69 *  event_in to the task specified by ID.  If the task is blocked
70 *  waiting to receive events and the posting of event_in satisfies
71 *  the task's event condition, then it is unblocked.
72 */
73rtems_status_code rtems_event_send (
74  Objects_Id         id,
75  rtems_event_set event_in
76);
77
78/**
79 *  @brief rtems_event_receive
80 *
81 *  This routine implements the rtems_event_receive directive.  This
82 *  directive is invoked when the calling task wishes to receive
83 *  the event_in event condition.  One of the fields in the option_set
84 *  parameter determines whether the receive request is satisfied if
85 *  any or all of the events are pending.   If the event condition
86 *  is not satisfied immediately, then the task may block with an
87 *  optional timeout of TICKS clock ticks or return immediately.
88 *  This determination is based on another field in the option_set
89 *  parameter.  This directive returns the events received in the
90 *  event_out parameter.
91 */
92rtems_status_code rtems_event_receive (
93  rtems_event_set  event_in,
94  rtems_option     option_set,
95  rtems_interval   ticks,
96  rtems_event_set *event_out
97);
98
99/**
100 *  @brief Event_Seize
101 *
102 *  This routine determines if the event condition event_in is
103 *  satisfied.  If so or if the no_wait option is enabled in option_set,
104 *  then the procedure returns immediately.  If neither of these
105 *  conditions is true, then the calling task is blocked with an
106 *  optional timeout of ticks clock ticks.
107 */
108void _Event_Seize (
109  rtems_event_set  event_in,
110  rtems_option     option_set,
111  rtems_interval   ticks,
112  rtems_event_set *event_out
113);
114
115/**
116 *  @brief Event_Surrender
117 *
118 *  This routine determines if the event condition of the_thread
119 *  has been satisfied.  If so, it unblocks the_thread.
120 */
121void _Event_Surrender (
122  Thread_Control *the_thread
123);
124
125/**
126 *  @brief Event_Timeout
127 *
128 *  This routine is invoked when a task's event receive request
129 *  has not been satisfied after the specified timeout interval.
130 *  The task represented by ID will be unblocked and its status
131 *  code will be set in it's control block to indicate that a timeout
132 *  has occurred.
133 */
134void _Event_Timeout (
135  Objects_Id  id,
136  void       *ignored
137);
138
139/**
140 *  @brief he following defines the synchronization flag used by the
141 */
142RTEMS_EVENT_EXTERN volatile Thread_blocking_operation_States _Event_Sync_state;
143
144#if defined(RTEMS_MULTIPROCESSING)
145#include <rtems/rtems/eventmp.h>
146#endif
147#ifndef __RTEMS_APPLICATION__
148#include <rtems/rtems/event.inl>
149#endif
150
151#ifdef __cplusplus
152}
153#endif
154
155/**@}*/
156
157#endif
158/* end of include file */
Note: See TracBrowser for help on using the repository browser.