QNX?????????????
???????????? ???????[ 2013/8/12 10:48:30 ] ????????
????4????????????API
struct _pulse {
uint16_t type;
uint16_t subtype;
int8_t code;
uint8_t zero [3];
union sigval value;
int32_t scoid;
};
????value???????????
union sigval {
int sival_int;
void *sival_ptr;
};
int MsgReceivePulse (int chid??
void *rmsg??
int rbytes??
struct _msg_info *info);
?????塢?????
????1??????????API
asyncmsg_channel_create()
asyncmsg_channel_destroy()
asyncmsg_connect_attach()
asyncmsg_connect_detach()
asyncmsg_flush()
asyncmsg_put()??
asyncmsg_get()
asyncmsg_free()
asyncmsg_malloc()
????2??API???
int asyncmsg_channel_create (
unsigned flags??
mode_t mode??
size_t buffer_size??
unsigned max_num_buffer??
const struct sigevent *ev??
int (*recvbuf_callback) (
size_t bufsize??
unsigned num_bufs??
void *bufs[]??
int flags??
void *handle )??
void *recvbuf_callback_handle );
????Flags:???????????????????_NTO_CHF_ASYNC?????????_NTO_CHF_ASYNC_NONBLOCK
????????????????asyncmsg_get()??????????????????????????????
????Mode:???????????
????Buff_size:????????????????С
????Max_num_buffer:?????????????????????
????Ev:NULL??????????sigevent????????????????????????????????????????????????????????
????Recvbuf_callback:NULL?????????????????????????????????NULL?????Malloc
????recvbuf_callback_handle???????Recvbuf_callback??????
?????????
??????Recvbuf_callback???NULL?????
??????????????asyncmsg_get()?????????λ??????(flags?????ASYNCMSG_RECVBUF_ALLOC??bufs??????...)???????????????????????1??????0????
???????? asyncmsg_channel_destroy()??????????????????????????????flags?????ASYNCMSG_RECVBUF_FREE??
????int asyncmsg_channel_destroy( int chid );
????chid ?????ID
???????:
??????Recvbuf_callback???NULL???????ε?????????????????free??
?????????:
???????:EOK
???????:-1 ->errno
int asyncmsg_connect_attach (
uint32_t nd??
pid_t pid??
int chid??
unsigned index??
unsigned flags??
const struct _asyncmsg_connection_attr * attr);
???????????:
????Nd/pid/chid:???????/????ID/???ID
????index?????????????ID(????)
????Flags:
????_NTO_COF_NOSHARE:??ó???????????BUFFER?????????asyncmsg_malloc()????????????asyncmsg_put()????????
????_NTO_COF_NONBLOCK:????????????????????????????
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11