IgH EtherCAT Master  1.5.3
fsm_slave.h File Reference

EtherCAT slave request state machine. More...

Go to the source code of this file.

Data Structures

struct  ec_fsm_slave
 Finite state machine of an EtherCAT slave. More...
 

Typedefs

typedef struct ec_fsm_slave ec_fsm_slave_t
 

Functions

void ec_fsm_slave_init (ec_fsm_slave_t *, ec_slave_t *)
 Constructor.
 
void ec_fsm_slave_clear (ec_fsm_slave_t *)
 Destructor.
 
int ec_fsm_slave_exec (ec_fsm_slave_t *, ec_datagram_t *)
 Executes the current state of the state machine. More...
 
void ec_fsm_slave_set_ready (ec_fsm_slave_t *)
 Sets the current state of the state machine to READY.
 
int ec_fsm_slave_is_ready (const ec_fsm_slave_t *)
 Returns, if the FSM is currently not busy and ready to execute. More...
 

Detailed Description

EtherCAT slave request state machine.

Definition in file fsm_slave.h.

Typedef Documentation

◆ ec_fsm_slave_t

typedef struct ec_fsm_slave ec_fsm_slave_t
See also
ec_fsm_slave

Definition at line 50 of file fsm_slave.h.

Function Documentation

◆ ec_fsm_slave_exec()

int ec_fsm_slave_exec ( ec_fsm_slave_t fsm,
ec_datagram_t datagram 
)

Executes the current state of the state machine.

Returns
1 if datagram was used, else 0.
Parameters
fsmSlave state machine.
datagramNew datagram to use.

Definition at line 121 of file fsm_slave.c.

◆ ec_fsm_slave_is_ready()

int ec_fsm_slave_is_ready ( const ec_fsm_slave_t fsm)

Returns, if the FSM is currently not busy and ready to execute.

Returns
Non-zero if ready.
Parameters
fsmSlave state machine.

Definition at line 162 of file fsm_slave.c.