Through the EtherCAT device interface, EtherCAT-capable network device drivers are able to connect their device(s) to the master, pass received frames and notify the master about status changes. The master on his part, can send his frames through connected devices.
Functions | |
| void | ecdev_receive (ec_device_t *device, const void *data, size_t size) |
| Accepts a received frame. | |
| void | ecdev_link_state (ec_device_t *device, uint8_t state) |
| Sets a new link state. | |
| ec_device_t * | ecdev_register (unsigned int master_index, struct net_device *net_dev, ec_isr_t isr, struct module *module) |
| Connects an EtherCAT device to a certain master. | |
| void | ecdev_unregister (unsigned int master_index, ec_device_t *device) |
| Disconnect an EtherCAT device from the master. | |
| int | ecdev_start (unsigned int master_index) |
| Starts the master associated with the device. | |
| void | ecdev_stop (unsigned int master_index) |
| Stops the master associated with the device. | |
|
||||||||||||||||
|
Accepts a received frame. Forwards the received data to the master. The master will analyze the frame and dispatch the received commands to the sending instances.
|
|
||||||||||||
|
Sets a new link state. If the device notifies the master about the link being down, the master will not try to send frames using this device.
|
|
||||||||||||||||||||
|
Connects an EtherCAT device to a certain master. The master will use the device for sending and receiving frames. It is required that no other instance (for example the kernel IP stack) uses the device.
|
|
||||||||||||
|
Disconnect an EtherCAT device from the master. The device is disconnected from the master and all device ressources are freed.
|
|
|
Starts the master associated with the device. This function has to be called by the network device driver to tell the master that the device is ready to send and receive data. The master will enter the idle mode then.
|
|
|
Stops the master associated with the device. Tells the master to stop using the device for frame IO. Has to be called before unregistering the device.
|
1.4.6