22 #ifndef LELY_CO_GW_TXT_H_
23 #define LELY_CO_GW_TXT_H_
28 #define CO_GW_TXT_IMPL_HI 2
31 #define CO_GW_TXT_IMPL_LO 1
72 void *__co_gw_txt_alloc(
void);
73 void __co_gw_txt_free(
void *ptr);
This header file is part of the CANopen library; it contains the gateway declarations (see CiA 309-1 ...
void co_gw_txt_set_send_func(co_gw_txt_t *gw, co_gw_txt_send_func_t *func, void *data)
Sets the callback function used to send requests from the user to a CANopen gateway.
void co_gw_txt_destroy(co_gw_txt_t *gw)
Destroys a CANopen ASCII gateway.
int co_gw_txt_recv_func_t(const char *txt, void *data)
The type of a CANopen ASCII gateway receive callback function, invoked when when an indication of con...
void co_gw_txt_get_recv_func(const co_gw_txt_t *gw, co_gw_txt_recv_func_t **pfunc, void **pdata)
Retrieves the callback function used to forward indications and confirmations received by a CANopen g...
int co_gw_txt_send_func_t(const struct co_gw_req *req, void *data)
The type of a CANopen ASCII gateway send callback function, invoked when a request has been issued by...
void co_gw_txt_get_send_func(const co_gw_txt_t *gw, co_gw_txt_send_func_t **pfunc, void **pdata)
Retrieves the callback function used to send requests from the user to a CANopen gateway.
size_t co_gw_txt_send(co_gw_txt_t *gw, const char *begin, const char *end, struct floc *at)
Sends a user request to a CANopen gateway.
co_gw_txt_t * co_gw_txt_create(void)
Creates a new CANopen ASCII gateway.
void co_gw_txt_set_recv_func(co_gw_txt_t *gw, co_gw_txt_recv_func_t *func, void *data)
Sets the callback function used to forward indications and confirmations received by a CANopen gatewa...
int co_gw_txt_recv(co_gw_txt_t *gw, const struct co_gw_srv *srv)
Receives and forwards an indication or confirmation from a CANopen gateway.
int co_gw_txt_iec(co_gw_txt_t *gw)
Returns (and clears) the last internal error code.
size_t co_gw_txt_pending(const co_gw_txt_t *gw)
Returns the number of pending (i.e., unconfirmed) requests.
The common parameters of a CANopen gateway request.
The common parameters of a CANopen gateway service.
A location in a text file.