Lely core libraries  2.3.4
io_user_can_chan Struct Reference

The implementation of a user-defined CAN channel. More...

Collaboration diagram for io_user_can_chan:

Data Fields

const struct io_dev_vtbldev_vptr
 A pointer to the virtual table for the I/O device interface.
 
const struct io_can_chan_vtblchan_vptr
 A pointer to the virtual table for the CAN channel interface.
 
struct io_svc svc
 The I/O service representing the channel.
 
io_ctx_tctx
 A pointer to the I/O context with which the channel is registered.
 
ev_exec_texec
 A pointer to the executor used to execute all I/O tasks.
 
int flags
 The flags specifying which CAN bus features are enabled.
 
int txtimeo
 The timeout (in milliseconds) when writing a CAN frame asynchronously.
 
io_user_can_chan_write_tfunc
 A pointer to the function to be invoked when a CAN frame needs to be written.
 
void * arg
 The user-specific value to be passed as the second argument to func.
 
struct ev_task read_task
 The task responsible for initiating read operations.
 
struct ev_task write_task
 The task responsible for initiating write operations.
 
mtx_t p_mtx
 The mutex protecting the receive queue producer.
 
cnd_t p_cond
 The condition variable used to wake up the receive queue producer.
 
mtx_t c_mtx
 The mutex protecting the receive queue consumer.
 
cnd_t c_cond
 The condition variable used to wake up the receive queue consumer.
 
struct spscring rxring
 The ring buffer used to control the receive queue.
 
struct io_user_can_framerxbuf
 The receive queue.
 
mtx_t mtx
 The mutex protecting the channel and the queues of pending operations.
 
unsigned shutdown: 1
 A flag indicating whether the I/O service has been shut down.
 
unsigned read_posted: 1
 A flag indicating whether read_task has been posted to exec.
 
unsigned write_posted: 1
 A flag indicating whether write_task has been posted to exec.
 
struct sllist read_queue
 The queue containing pending read operations.
 
struct sllist write_queue
 The queue containing pending write operations.
 
struct ev_taskcurrent_read
 The read operation currently being executed.
 
struct ev_taskcurrent_write
 The write operation currently being executed.
 

Detailed Description

The implementation of a user-defined CAN channel.

Definition at line 105 of file can.c.


The documentation for this struct was generated from the following file: