XWOS API
4.0
XWOS C/C++ API参考手册
|
操作系统抽象层:事件标志 更多...
#include <xwos/standard.h>
#include <xwos/osal/jack/sync/flg.h>
#include <xwos/osal/time.h>
#include <xwos/osal/sync/sel.h>
结构体 | |
struct | xwos_flg |
XWOS API:事件标志对象 更多... | |
struct | xwos_flg_d |
XWOS API:事件标志对象描述符 更多... | |
宏定义 | |
#define | XWOS_FLG_NILD ((xwos_flg_d){NULL, 0,}) |
XWOS API:空的事件标志对象描述符 | |
#define | XWOS_FLG_TRIGGER_SET_ALL XWOSDL_FLG_TRIGGER_SET_ALL |
XWOS API:所有事件位被置1触发 | |
#define | XWOS_FLG_TRIGGER_SET_ANY XWOSDL_FLG_TRIGGER_SET_ANY |
XWOS API:任意事件位被置1触发 | |
#define | XWOS_FLG_TRIGGER_CLR_ALL XWOSDL_FLG_TRIGGER_CLR_ALL |
XWOS API:所有事件位被清0触发 | |
#define | XWOS_FLG_TRIGGER_CLR_ANY XWOSDL_FLG_TRIGGER_CLR_ANY |
XWOS API:任意事件位被清0触发 | |
#define | XWOS_FLG_TRIGGER_TGL_ALL XWOSDL_FLG_TRIGGER_TGL_ALL |
XWOS API:所有事件位发生翻转触发 | |
#define | XWOS_FLG_TRIGGER_TGL_ANY XWOSDL_FLG_TRIGGER_TGL_ANY |
XWOS API:任意事件位发生翻转触发 | |
#define | XWOS_FLG_ACTION_NONE XWOSDL_FLG_ACTION_NONE |
XWOS API:事件触发后不做任何操作 | |
#define | XWOS_FLG_ACTION_CONSUMPTION XWOSDL_FLG_ACTION_CONSUMPTION |
XWOS API:事件触发后清除触发条件 | |
函数 | |
static xwer_t | xwos_flg_init (struct xwos_flg *flg, xwsz_t num, xwbmp_t *bmp, xwbmp_t *msk) |
XWOS API:静态方式初始化事件标志对象 | |
static xwer_t | xwos_flg_fini (struct xwos_flg *flg) |
XWOS API:销毁静态方式初始化的事件标志对象 | |
static xwer_t | xwos_flg_grab (struct xwos_flg *flg) |
XWOS API:增加事件标志对象的引用计数 | |
static xwer_t | xwos_flg_put (struct xwos_flg *flg) |
XWOS API:减少事件标志对象的引用计数 | |
static xwer_t | xwos_flg_create (xwos_flg_d *flgd, xwsz_t num) |
XWOS API:动态方式创建事件标志对象 | |
static xwer_t | xwos_flg_delete (xwos_flg_d flgd) |
XWOS API:删除动态方式创建的事件标志对象 | |
static xwer_t | xwos_flg_acquire (xwos_flg_d flgd) |
XWOS API:检查事件标志对象的标签并增加引用计数 | |
static xwer_t | xwos_flg_release (xwos_flg_d flgd) |
XWOS API:检查事件标志对象的标签并减少引用计数 | |
static xwsq_t | xwos_flg_get_tik (struct xwos_flg *flg) |
XWOS API:获取事件标志对象的标签 | |
static xwos_flg_d | xwos_flg_get_d (struct xwos_flg *flg) |
XWOS API:获取事件标志对象描述符 | |
static xwer_t | xwos_flg_bind (struct xwos_flg *flg, struct xwos_sel *sel, xwsq_t pos) |
XWOS API:绑定事件标志对象到信号选择器 | |
static xwer_t | xwos_flg_unbind (struct xwos_flg *flg, struct xwos_sel *sel) |
XWOS API:从信号选择器上解绑事件标志对象 | |
static xwer_t | xwos_flg_get_num (struct xwos_flg *flg, xwsz_t *numbuf) |
XWOS API:获取事件标志中事件槽的数量 | |
static xwer_t | xwos_flg_s1m (struct xwos_flg *flg, xwbmp_t msk[]) |
XWOS API:同时设置多个事件标志位 | |
static xwer_t | xwos_flg_s1i (struct xwos_flg *flg, xwsq_t pos) |
XWOS API:设置单个事件标志位 | |
static xwer_t | xwos_flg_c0m (struct xwos_flg *flg, xwbmp_t msk[]) |
XWOS API:同时清除多个事件标志位 | |
static xwer_t | xwos_flg_c0i (struct xwos_flg *flg, xwsq_t pos) |
XWOS API:清除单个事件标志位 | |
static xwer_t | xwos_flg_x1m (struct xwos_flg *flg, xwbmp_t msk[]) |
XWOS API:同时翻转多个事件标志位 | |
static xwer_t | xwos_flg_x1i (struct xwos_flg *flg, xwsq_t pos) |
XWOS API:翻转单个事件标志位 | |
static xwer_t | xwos_flg_read (struct xwos_flg *flg, xwbmp_t out[]) |
XWOS API:读取事件标志位图的值 | |
static xwer_t | xwos_flg_wait (struct xwos_flg *flg, xwsq_t trigger, xwsq_t action, xwbmp_t origin[], xwbmp_t msk[]) |
XWOS API:等待事件 | |
static xwer_t | xwos_flg_wait_to (struct xwos_flg *flg, xwsq_t trigger, xwsq_t action, xwbmp_t origin[], xwbmp_t msk[], xwtm_t to) |
XWOS API:限时等待触发事件 | |
static xwer_t | xwos_flg_trywait (struct xwos_flg *flg, xwsq_t trigger, xwsq_t action, xwbmp_t origin[], xwbmp_t msk[]) |
XWOS API:检查触发事件 | |
操作系统抽象层:事件标志
This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
在文件 flg.h 中定义.