libethercat - an embeddable realtime EtherCAT-master library
Communicate with EtherCAT slaves attached to a Network interface.
Loading...
Searching...
No Matches
ec_mbx Struct Reference

Data Fields

osal_uint32_t handler_flags
 Flags signalling handler recv of send action.
 
osal_mutex_t sync_mutex
 Sync mutex for handler flags.
 
osal_binary_semaphore_t sync_sem
 Mailbox sync semaphore.
 
int handler_running
 Mailbox handler thread running flag.
 
ec_tpec
 Pointer to ethercat master structure.
 
int slave
 Number of EtherCAT slave.
 
osal_task_t handler_tid
 Mailbox handler thread handle.
 
osal_mutex_t lock
 mailbox lock
 
int seq_counter
 mailbox sequence counter
 
pool_t message_pool_send_queued
 Pool with mailbox buffers ready to be sent.
 
osal_uint32_t sm_state_bitno
 
osal_uint8_t * sm_state
 Sync manager state of read mailbox.
 
osal_uint8_t mbx_state
 State if not mapped.
 

Field Documentation

◆ lock

osal_mutex_t ec_mbx::lock

mailbox lock

Only one simoultaneous access to the EtherCAT slave mailbox is possible at the moment.

◆ pec

ec_t* ec_mbx::pec

Pointer to ethercat master structure.

Used by handler thread wrapper to call mailbox handler function.

◆ slave

int ec_mbx::slave

Number of EtherCAT slave.

Used by handler thread wrapper to call mailbox handler function.

◆ sm_state

osal_uint8_t* ec_mbx::sm_state

Sync manager state of read mailbox.

The field is used to receive the mailbox sync manager state. This is useful to determine if the mailbox is full or empty without the need to poll the state manually.


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