#include <stdio.h>
#include <string.h>
#include <sys/time.h>
#include <unistd.h>
#include "ethercattype.h"
#include "nicdrv.h"
#include "ethercatbase.h"
#include "ethercatmain.h"
#include "ethercatcoe.h"
#include "ethercatconfig.h"
#include "ethercatconfiglist.h"
Data Structures | |
struct | ec_configlist_t |
Defines | |
#define | EC_DEFAULTMBXSM0 0x00010026 |
#define | EC_DEFAULTMBXSM1 0x00010022 |
#define | EC_DEFAULTDOSM0 0x00010044 |
Functions | |
int | ec_findconfig (uint32 man, uint32 id) |
int | ec_config_init (uint8 usetable) |
int | ec_config_map (void *pIOmap) |
int | ec_config (uint8 usetable, void *pIOmap) |
Variables | |
static ec_eepromSMt | ec_SM |
static ec_eepromFMMUt | ec_FMMU |
After successful initialisation with ec_init() or ec_init_redundant() the slaves can be auto configured with this module.
#define EC_DEFAULTDOSM0 0x00010044 |
standard SM0 flags configuration for digital output slaves
#define EC_DEFAULTMBXSM0 0x00010026 |
standard SM0 flags configuration for mailbox slaves
#define EC_DEFAULTMBXSM1 0x00010022 |
standard SM1 flags configuration for mailbox slaves
int ec_config | ( | uint8 | usetable, | |
void * | pIOmap | |||
) |
Enumerate / map and init all slaves.
[in] | usetable | = TRUE when using configtable to init slaves, FALSE otherwise |
[out] | pIOmap | = pointer to IOmap |
int ec_config_init | ( | uint8 | usetable | ) |
Enumerate and init all slaves.
[in] | usetable | = TRUE when using configtable to init slaves, FALSE otherwise |
int ec_config_map | ( | void * | pIOmap | ) |
Map all PDOs from slaves to IOmap.
[out] | pIOmap | = pointer to IOmap |
Find slave in standard configuration list ec_configlist[]
[in] | man | = manufacturer |
[in] | id | = ID |
ec_eepromFMMUt ec_FMMU [static] |
buffer for EEPROM FMMU data
ec_eepromSMt ec_SM [static] |
buffer for EEPROM SM data