master/slave.h
changeset 182 8c0bc99229a9
parent 175 2e4b18203ade
child 183 8ae1e011e96c
--- a/master/slave.h	Tue Apr 11 09:08:10 2006 +0000
+++ b/master/slave.h	Tue Apr 11 09:12:00 2006 +0000
@@ -12,6 +12,7 @@
 #define _EC_SLAVE_H_
 
 #include <linux/list.h>
+#include <linux/kobject.h>
 
 #include "globals.h"
 #include "command.h"
@@ -188,11 +189,15 @@
 
 struct ec_slave
 {
+    struct list_head list; /**< Noetig fuer Slave-Liste im Master */
+    struct kobject kobj; /**< Kernel-Object */
     ec_master_t *master; /**< EtherCAT-Master, zu dem der Slave gehört. */
 
     // Addresses
     uint16_t ring_position; /**< Position des Slaves im Bus */
     uint16_t station_address; /**< Konfigurierte Slave-Adresse */
+    uint16_t buscoupler_index; /**< Letzter Buskoppler */
+    uint16_t index_after_buscoupler; /**< Index hinter letztem Buskoppler */
 
     // Base data
     uint8_t base_type; /**< Slave-Typ */
@@ -242,8 +247,8 @@
 /*****************************************************************************/
 
 // Slave construction/destruction
-void ec_slave_init(ec_slave_t *, ec_master_t *);
-void ec_slave_clear(ec_slave_t *);
+int ec_slave_init(ec_slave_t *, ec_master_t *, uint16_t, uint16_t);
+void ec_slave_clear(struct kobject *);
 
 // Slave control
 int ec_slave_fetch(ec_slave_t *);