GadgetSeed  0.9.6
event.h
[詳解]
1 /** @file
2  @brief イベント待ちタスクキューの操作
3 
4  @date 2011.03.20
5  @author Takashi SHUDO
6 */
7 
8 #ifndef EVENT_H
9 #define EVENT_H
10 
11 #include "queue.h"
12 #include "fifo.h"
13 #include "task.h"
14 
15 struct st_event {
16  struct st_queue list; ///< イベントキューのキュー
17  struct st_queue proc_head; ///< イベント待ちタスクキュー
18  struct st_fifo event; ///< イベントデータバッファ
19  unsigned int size; ///< 1イベントのサイズ
20  const char *name; ///< イベント名文字列
21 }; ///< イベント
22 
23 void eventqueue_register_ISR(struct st_event *evtque, const char *name, void *args, unsigned int arg_size, int arg_count);
24 void eventqueue_unregister_ISR(struct st_event *evtque);
25 
26 void event_wait_ISR(void *sp, struct st_event *evtque, void *arg, unsigned int timeout);
27 int event_check_ISR(void *sp, struct st_event *evtque);
28 void event_clear_ISR(void *sp, struct st_event *evtque);
29 void event_push_ISR(void *sp, struct st_event *evtque, void *arg);
30 void event_set_ISR(void *sp, struct st_event *evtque);
31 void event_wakeup_ISR(void *sp, struct st_event *evtque, void *arg);
32 
33 #endif // EVENT_H
void event_clear_ISR(void *sp, struct st_event *evtque)
イベントカウンタをクリアリセットする
Definition: task.c:838
struct st_fifo event
イベントデータバッファ
Definition: event.h:18
汎用FIFO
Definition: fifo.h:12
void eventqueue_unregister_ISR(struct st_event *evtque)
イベントキューを登録解除する
Definition: event.c:58
void eventqueue_register_ISR(struct st_event *evtque, const char *name, void *args, unsigned int arg_size, int arg_count)
イベントキューを登録する
Definition: event.c:36
void event_wakeup_ISR(void *sp, struct st_event *evtque, void *arg)
イベントキューにイベントを登録し、イベント待ちタスクを起動する
Definition: task.c:923
キュー構造
Definition: queue.h:13
タスクキュー操作
struct st_queue proc_head
イベント待ちタスクキュー
Definition: event.h:17
int event_check_ISR(void *sp, struct st_event *evtque)
イベントカウントを取得する
Definition: task.c:814
イベント
Definition: event.h:15
struct st_queue list
イベントキューのキュー
Definition: event.h:16
汎用リングバッファ
タスク制御
const char * name
イベント名文字列
Definition: event.h:20
void event_push_ISR(void *sp, struct st_event *evtque, void *arg)
イベントFIFOにイベントを登録する
Definition: task.c:857
void event_set_ISR(void *sp, struct st_event *evtque)
イベント待ちタスクを起動する
Definition: task.c:879
unsigned int size
1イベントのサイズ
Definition: event.h:19