master/slave.h
changeset 625 ec69acbbd156
parent 624 11332ad89f47
child 626 a5e838c30733
equal deleted inserted replaced
624:11332ad89f47 625:ec69acbbd156
   122 typedef enum
   122 typedef enum
   123 {
   123 {
   124     EC_RX_PDO, /**< Reveive PDO */
   124     EC_RX_PDO, /**< Reveive PDO */
   125     EC_TX_PDO /**< Transmit PDO */
   125     EC_TX_PDO /**< Transmit PDO */
   126 }
   126 }
   127 ec_sii_pdo_type_t;
   127 ec_pdo_type_t;
   128 
   128 
   129 /*****************************************************************************/
   129 /*****************************************************************************/
   130 
   130 
   131 /**
   131 /**
   132    PDO description (EEPROM).
   132    PDO description.
   133 */
   133 */
   134 
   134 
   135 typedef struct
   135 typedef struct
   136 {
   136 {
   137     struct list_head list; /**< list item */
   137     struct list_head list; /**< list item */
   138     ec_sii_pdo_type_t type; /**< PDO type */
   138     ec_pdo_type_t type; /**< PDO type */
   139     uint16_t index; /**< PDO index */
   139     uint16_t index; /**< PDO index */
   140     uint8_t sync_index; /**< assigned sync manager */
   140     uint8_t sync_index; /**< assigned sync manager */
   141     char *name; /**< PDO name */
   141     char *name; /**< PDO name */
   142     struct list_head entries; /**< entry list */
   142     struct list_head entries; /**< entry list */
   143 }
   143 }
   144 ec_sii_pdo_t;
   144 ec_pdo_t;
   145 
   145 
   146 /*****************************************************************************/
   146 /*****************************************************************************/
   147 
   147 
   148 /**
   148 /**
   149    PDO entry description (EEPROM).
   149    PDO entry description.
   150 */
   150 */
   151 
   151 
   152 typedef struct
   152 typedef struct
   153 {
   153 {
   154     struct list_head list; /**< list item */
   154     struct list_head list; /**< list item */
   155     uint16_t index; /**< PDO index */
   155     uint16_t index; /**< PDO index */
   156     uint8_t subindex; /**< entry subindex */
   156     uint8_t subindex; /**< entry subindex */
   157     char *name; /**< entry name */
   157     char *name; /**< entry name */
   158     uint8_t bit_length; /**< entry length in bit */
   158     uint8_t bit_length; /**< entry length in bit */
   159 }
   159 }
   160 ec_sii_pdo_entry_t;
   160 ec_pdo_entry_t;
   161 
   161 
   162 /*****************************************************************************/
   162 /*****************************************************************************/
   163 
   163 
   164 /**
   164 /**
   165    FMMU configuration.
   165    FMMU configuration.
   265 // SII categories
   265 // SII categories
   266 int ec_slave_fetch_sii_strings(ec_slave_t *, const uint8_t *);
   266 int ec_slave_fetch_sii_strings(ec_slave_t *, const uint8_t *);
   267 void ec_slave_fetch_sii_general(ec_slave_t *, const uint8_t *);
   267 void ec_slave_fetch_sii_general(ec_slave_t *, const uint8_t *);
   268 int ec_slave_fetch_sii_syncs(ec_slave_t *, const uint8_t *, size_t);
   268 int ec_slave_fetch_sii_syncs(ec_slave_t *, const uint8_t *, size_t);
   269 int ec_slave_fetch_sii_pdos(ec_slave_t *, const uint8_t *, size_t,
   269 int ec_slave_fetch_sii_pdos(ec_slave_t *, const uint8_t *, size_t,
   270         ec_sii_pdo_type_t);
   270         ec_pdo_type_t);
   271 
   271 
   272 // misc.
   272 // misc.
   273 ec_sii_sync_t *ec_slave_get_pdo_sync(ec_slave_t *, ec_direction_t); 
   273 ec_sii_sync_t *ec_slave_get_pdo_sync(ec_slave_t *, ec_direction_t); 
   274 void ec_slave_sync_config(const ec_slave_t *, const ec_sii_sync_t *,
   274 void ec_slave_sync_config(const ec_slave_t *, const ec_sii_sync_t *,
   275         uint8_t *);
   275         uint8_t *);