SOEM  v1.2.8
Macros | Functions
ethercatconfig.h File Reference

Headerfile for ethercatconfig.c. More...

Macros

#define EC_NODEOFFSET   0x1000
#define EC_TEMPNODE   0xffff

Functions

int ec_config_init (uint8 usetable)
int ec_config_map (void *pIOmap)
int ec_config_map_group (void *pIOmap, uint8 group)
int ec_config (uint8 usetable, void *pIOmap)
int ec_recover_slave (uint16 slave, int timeout)
int ec_reconfig_slave (uint16 slave, int timeout)

Detailed Description

Headerfile for ethercatconfig.c.


Macro Definition Documentation

#define EC_NODEOFFSET   0x1000
#define EC_TEMPNODE   0xffff

Function Documentation

int ec_config ( uint8  usetable,
void *  pIOmap 
)

Enumerate / map and init all slaves.

Parameters:
[in]usetable= TRUE when using configtable to init slaves, FALSE otherwise
[out]pIOmap= pointer to IOmap
Returns:
Workcounter of slave discover datagram = number of slaves found
int ec_config_init ( uint8  usetable)

Enumerate and init all slaves.

Parameters:
[in]usetable= TRUE when using configtable to init slaves, FALSE otherwise
Returns:
Workcounter of slave discover datagram = number of slaves found
int ec_config_map ( void *  pIOmap)

Map all PDOs from slaves to IOmap.

Parameters:
[out]pIOmap= pointer to IOmap
Returns:
IOmap size
int ec_config_map_group ( void *  pIOmap,
uint8  group 
)

Map all PDOs in one group of slaves to IOmap.

Parameters:
[out]pIOmap= pointer to IOmap
[in]group= group to map, 0 = all groups
Returns:
IOmap size
int ec_reconfig_slave ( uint16  slave,
int  timeout 
)

Reconfigure slave.

Parameters:
[in]slave= slave to reconfigure
[in]timeout= local timeout f.e. EC_TIMEOUTRET
Returns:
Slave state
int ec_recover_slave ( uint16  slave,
int  timeout 
)

Recover slave.

Parameters:
[in]slave= slave to recover
[in]timeout= local timeout f.e. EC_TIMEOUTRET
Returns:
>0 if successful