fp@922: /****************************************************************************** fp@922: * fp@922: * $Id$ fp@922: * fp@1326: * Copyright (C) 2006-2008 Florian Pose, Ingenieurgemeinschaft IgH fp@922: * fp@922: * This file is part of the IgH EtherCAT Master. fp@922: * fp@1326: * The IgH EtherCAT Master is free software; you can redistribute it and/or fp@1326: * modify it under the terms of the GNU General Public License version 2, as fp@1326: * published by the Free Software Foundation. fp@1326: * fp@1326: * The IgH EtherCAT Master is distributed in the hope that it will be useful, fp@1326: * but WITHOUT ANY WARRANTY; without even the implied warranty of fp@1326: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General fp@1326: * Public License for more details. fp@1326: * fp@1326: * You should have received a copy of the GNU General Public License along fp@1326: * with the IgH EtherCAT Master; if not, write to the Free Software fp@922: * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA fp@922: * fp@1363: * --- fp@1363: * fp@1363: * The license mentioned above concerns the source code only. Using the fp@1363: * EtherCAT technology and brand is only permitted in compliance with the fp@1363: * industrial property and similar rights of Beckhoff Automation GmbH. fp@922: * fp@922: *****************************************************************************/ fp@922: fp@922: /** fp@922: \file fp@922: EtherCAT master character device IOCTL commands. fp@922: */ fp@922: fp@922: /*****************************************************************************/ fp@922: fp@922: #ifndef __EC_IOCTL_H__ fp@922: #define __EC_IOCTL_H__ fp@922: fp@971: #include fp@971: fp@989: #include "globals.h" fp@989: fp@971: /*****************************************************************************/ fp@971: fp@1082: /** \cond */ fp@1082: fp@1079: #define EC_IOCTL_TYPE 0xa4 fp@1079: fp@1079: #define EC_IO(nr) _IO(EC_IOCTL_TYPE, nr) fp@1079: #define EC_IOR(nr, type) _IOR(EC_IOCTL_TYPE, nr, type) fp@1079: #define EC_IOW(nr, type) _IOW(EC_IOCTL_TYPE, nr, type) fp@1079: #define EC_IOWR(nr, type) _IOWR(EC_IOCTL_TYPE, nr, type) fp@1079: fp@1826: /** EtherCAT master ioctl() version magic. fp@1826: * fp@1826: * Increment this when changing the ioctl interface! fp@1826: */ fp@1963: #define EC_IOCTL_VERSION_MAGIC 8 fp@1826: fp@1259: // Command-line tool fp@1826: #define EC_IOCTL_MODULE EC_IOR(0x00, ec_ioctl_module_t) fp@1826: #define EC_IOCTL_MASTER EC_IOR(0x01, ec_ioctl_master_t) fp@1826: #define EC_IOCTL_SLAVE EC_IOWR(0x02, ec_ioctl_slave_t) fp@1826: #define EC_IOCTL_SLAVE_SYNC EC_IOWR(0x03, ec_ioctl_slave_sync_t) fp@1826: #define EC_IOCTL_SLAVE_SYNC_PDO EC_IOWR(0x04, ec_ioctl_slave_sync_pdo_t) fp@1826: #define EC_IOCTL_SLAVE_SYNC_PDO_ENTRY EC_IOWR(0x05, ec_ioctl_slave_sync_pdo_entry_t) fp@1826: #define EC_IOCTL_DOMAIN EC_IOWR(0x06, ec_ioctl_domain_t) fp@1826: #define EC_IOCTL_DOMAIN_FMMU EC_IOWR(0x07, ec_ioctl_domain_fmmu_t) fp@1826: #define EC_IOCTL_DOMAIN_DATA EC_IOWR(0x08, ec_ioctl_domain_data_t) fp@1826: #define EC_IOCTL_MASTER_DEBUG EC_IO(0x09) fp@1961: #define EC_IOCTL_MASTER_RESCAN EC_IO(0x0a) fp@1961: #define EC_IOCTL_SLAVE_STATE EC_IOW(0x0b, ec_ioctl_slave_state_t) fp@1961: #define EC_IOCTL_SLAVE_SDO EC_IOWR(0x0c, ec_ioctl_slave_sdo_t) fp@1961: #define EC_IOCTL_SLAVE_SDO_ENTRY EC_IOWR(0x0d, ec_ioctl_slave_sdo_entry_t) fp@1961: #define EC_IOCTL_SLAVE_SDO_UPLOAD EC_IOWR(0x0e, ec_ioctl_slave_sdo_upload_t) fp@1961: #define EC_IOCTL_SLAVE_SDO_DOWNLOAD EC_IOWR(0x0f, ec_ioctl_slave_sdo_download_t) fp@1961: #define EC_IOCTL_SLAVE_SII_READ EC_IOWR(0x10, ec_ioctl_slave_sii_t) fp@1961: #define EC_IOCTL_SLAVE_SII_WRITE EC_IOW(0x11, ec_ioctl_slave_sii_t) fp@1961: #define EC_IOCTL_SLAVE_REG_READ EC_IOWR(0x12, ec_ioctl_slave_reg_t) fp@1961: #define EC_IOCTL_SLAVE_REG_WRITE EC_IOW(0x13, ec_ioctl_slave_reg_t) fp@1961: #define EC_IOCTL_SLAVE_FOE_READ EC_IOWR(0x14, ec_ioctl_slave_foe_t) fp@1961: #define EC_IOCTL_SLAVE_FOE_WRITE EC_IOW(0x15, ec_ioctl_slave_foe_t) fp@1961: #define EC_IOCTL_SLAVE_SOE_READ EC_IOWR(0x16, ec_ioctl_slave_soe_read_t) fp@1961: #define EC_IOCTL_SLAVE_SOE_WRITE EC_IOWR(0x17, ec_ioctl_slave_soe_write_t) fp@1961: #define EC_IOCTL_CONFIG EC_IOWR(0x18, ec_ioctl_config_t) fp@1961: #define EC_IOCTL_CONFIG_PDO EC_IOWR(0x19, ec_ioctl_config_pdo_t) fp@1961: #define EC_IOCTL_CONFIG_PDO_ENTRY EC_IOWR(0x1a, ec_ioctl_config_pdo_entry_t) fp@1961: #define EC_IOCTL_CONFIG_SDO EC_IOWR(0x1b, ec_ioctl_config_sdo_t) fp@1516: #ifdef EC_EOE fp@1961: #define EC_IOCTL_EOE_HANDLER EC_IOWR(0x1c, ec_ioctl_eoe_handler_t) fp@1516: #endif fp@1244: fp@1259: // Application interface fp@1961: #define EC_IOCTL_REQUEST EC_IO(0x1d) fp@1961: #define EC_IOCTL_CREATE_DOMAIN EC_IO(0x1e) fp@1961: #define EC_IOCTL_CREATE_SLAVE_CONFIG EC_IOWR(0x1f, ec_ioctl_config_t) fp@1961: #define EC_IOCTL_ACTIVATE EC_IOR(0x20, size_t) fp@1961: #define EC_IOCTL_DEACTIVATE EC_IO(0x21) fp@1961: #define EC_IOCTL_SEND EC_IO(0x22) fp@1961: #define EC_IOCTL_RECEIVE EC_IO(0x23) fp@1961: #define EC_IOCTL_MASTER_STATE EC_IOR(0x24, ec_master_state_t) fp@1961: #define EC_IOCTL_APP_TIME EC_IOW(0x25, ec_ioctl_app_time_t) fp@1961: #define EC_IOCTL_SYNC_REF EC_IO(0x26) fp@1961: #define EC_IOCTL_SYNC_SLAVES EC_IO(0x27) fp@1961: #define EC_IOCTL_SYNC_MON_QUEUE EC_IO(0x28) fp@1961: #define EC_IOCTL_SYNC_MON_PROCESS EC_IOR(0x29, uint32_t) fp@1961: #define EC_IOCTL_SC_SYNC EC_IOW(0x2a, ec_ioctl_config_t) fp@1961: #define EC_IOCTL_SC_WATCHDOG EC_IOW(0x2b, ec_ioctl_config_t) fp@1961: #define EC_IOCTL_SC_ADD_PDO EC_IOW(0x2c, ec_ioctl_config_pdo_t) fp@1961: #define EC_IOCTL_SC_CLEAR_PDOS EC_IOW(0x2d, ec_ioctl_config_pdo_t) fp@1961: #define EC_IOCTL_SC_ADD_ENTRY EC_IOW(0x2e, ec_ioctl_add_pdo_entry_t) fp@1961: #define EC_IOCTL_SC_CLEAR_ENTRIES EC_IOW(0x2f, ec_ioctl_config_pdo_t) fp@1961: #define EC_IOCTL_SC_REG_PDO_ENTRY EC_IOWR(0x20, ec_ioctl_reg_pdo_entry_t) fp@1961: #define EC_IOCTL_SC_DC EC_IOW(0x31, ec_ioctl_config_t) fp@1961: #define EC_IOCTL_SC_SDO EC_IOW(0x32, ec_ioctl_sc_sdo_t) fp@1961: #define EC_IOCTL_SC_SDO_REQUEST EC_IOWR(0x33, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_SC_VOE EC_IOWR(0x34, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_SC_STATE EC_IOWR(0x35, ec_ioctl_sc_state_t) fp@1961: #define EC_IOCTL_SC_IDN EC_IOW(0x36, ec_ioctl_sc_idn_t) fp@1961: #define EC_IOCTL_DOMAIN_OFFSET EC_IO(0x37) fp@1961: #define EC_IOCTL_DOMAIN_PROCESS EC_IO(0x38) fp@1961: #define EC_IOCTL_DOMAIN_QUEUE EC_IO(0x39) fp@1961: #define EC_IOCTL_DOMAIN_STATE EC_IOWR(0x3a, ec_ioctl_domain_state_t) fp@1961: #define EC_IOCTL_SDO_REQUEST_TIMEOUT EC_IOWR(0x3b, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_SDO_REQUEST_STATE EC_IOWR(0x3c, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_SDO_REQUEST_READ EC_IOWR(0x3d, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_SDO_REQUEST_WRITE EC_IOWR(0x3e, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_SDO_REQUEST_DATA EC_IOWR(0x3f, ec_ioctl_sdo_request_t) fp@1961: #define EC_IOCTL_VOE_SEND_HEADER EC_IOW(0x40, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_REC_HEADER EC_IOWR(0x41, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_READ EC_IOW(0x42, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_READ_NOSYNC EC_IOW(0x43, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_WRITE EC_IOWR(0x44, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_EXEC EC_IOWR(0x45, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_VOE_DATA EC_IOWR(0x46, ec_ioctl_voe_t) fp@1961: #define EC_IOCTL_SET_SEND_INTERVAL EC_IOW(0x47, size_t) fp@1259: fp@1259: /*****************************************************************************/ fp@990: fp@990: #define EC_IOCTL_STRING_SIZE 64 fp@978: fp@978: /*****************************************************************************/ fp@978: fp@978: typedef struct { fp@1826: uint32_t ioctl_version_magic; fp@1826: uint32_t master_count; fp@1826: } ec_ioctl_module_t; fp@1826: fp@1826: /*****************************************************************************/ fp@1826: fp@1826: typedef struct { fp@978: uint32_t slave_count; fp@990: uint32_t config_count; fp@1001: uint32_t domain_count; fp@1516: #ifdef EC_EOE fp@1485: uint32_t eoe_handler_count; fp@1516: #endif fp@1029: uint8_t phase; fp@1530: uint8_t active; fp@1447: uint8_t scan_busy; fp@1857: struct ec_ioctl_device { fp@957: uint8_t address[6]; fp@957: uint8_t attached; fp@1401: uint8_t link_state; fp@1863: uint64_t tx_count; fp@1863: uint64_t rx_count; fp@1863: uint64_t tx_bytes; fp@1863: uint64_t tx_errors; fp@1857: uint32_t tx_frame_rates[EC_RATE_COUNT]; fp@1857: uint32_t tx_byte_rates[EC_RATE_COUNT]; fp@1851: int32_t loss_rates[EC_RATE_COUNT]; fp@957: } devices[2]; fp@1415: uint64_t app_time; fp@1415: uint16_t ref_clock; fp@957: } ec_ioctl_master_t; fp@957: fp@957: /*****************************************************************************/ fp@957: fp@935: typedef struct { fp@935: // input fp@935: uint16_t position; fp@935: fp@935: // outputs fp@922: uint32_t vendor_id; fp@922: uint32_t product_code; fp@938: uint32_t revision_number; fp@938: uint32_t serial_number; fp@922: uint16_t alias; fp@1337: uint16_t boot_rx_mailbox_offset; fp@1337: uint16_t boot_rx_mailbox_size; fp@1337: uint16_t boot_tx_mailbox_offset; fp@1337: uint16_t boot_tx_mailbox_size; fp@1337: uint16_t std_rx_mailbox_offset; fp@1337: uint16_t std_rx_mailbox_size; fp@1337: uint16_t std_tx_mailbox_offset; fp@1337: uint16_t std_tx_mailbox_size; fp@989: uint16_t mailbox_protocols; fp@989: uint8_t has_general_category; fp@989: ec_sii_coe_details_t coe_details; fp@989: ec_sii_general_flags_t general_flags; fp@989: int16_t current_on_ebus; fp@1425: struct { fp@1425: ec_slave_port_desc_t desc; fp@1425: ec_slave_port_link_t link; fp@1425: uint32_t receive_time; fp@1425: uint16_t next_slave; fp@1425: uint32_t delay_to_next_dc; fp@1425: } ports[EC_MAX_PORTS]; fp@1379: uint8_t fmmu_bit; fp@1379: uint8_t dc_supported; fp@1379: ec_slave_dc_range_t dc_range; fp@1419: uint8_t has_dc_system_time; fp@1426: uint32_t transmission_delay; fp@1148: uint8_t al_state; fp@987: uint8_t error_flag; fp@935: uint8_t sync_count; fp@965: uint16_t sdo_count; fp@978: uint32_t sii_nwords; fp@1109: char group[EC_IOCTL_STRING_SIZE]; fp@1109: char image[EC_IOCTL_STRING_SIZE]; fp@1109: char order[EC_IOCTL_STRING_SIZE]; fp@990: char name[EC_IOCTL_STRING_SIZE]; fp@935: } ec_ioctl_slave_t; fp@935: fp@935: /*****************************************************************************/ fp@935: fp@935: typedef struct { fp@935: // inputs fp@935: uint16_t slave_position; fp@978: uint32_t sync_index; fp@935: fp@935: // outputs fp@935: uint16_t physical_start_address; fp@935: uint16_t default_size; fp@935: uint8_t control_register; fp@935: uint8_t enable; fp@935: uint8_t pdo_count; fp@1079: } ec_ioctl_slave_sync_t; fp@935: fp@935: /*****************************************************************************/ fp@935: fp@935: typedef struct { fp@935: // inputs fp@935: uint16_t slave_position; fp@978: uint32_t sync_index; fp@978: uint32_t pdo_pos; fp@935: fp@935: // outputs fp@935: uint16_t index; fp@935: uint8_t entry_count; fp@990: int8_t name[EC_IOCTL_STRING_SIZE]; fp@1079: } ec_ioctl_slave_sync_pdo_t; fp@935: fp@935: /*****************************************************************************/ fp@935: fp@935: typedef struct { fp@935: // inputs fp@935: uint16_t slave_position; fp@978: uint32_t sync_index; fp@978: uint32_t pdo_pos; fp@978: uint32_t entry_pos; fp@935: fp@935: // outputs fp@935: uint16_t index; fp@935: uint8_t subindex; fp@935: uint8_t bit_length; fp@990: int8_t name[EC_IOCTL_STRING_SIZE]; fp@1079: } ec_ioctl_slave_sync_pdo_entry_t; fp@922: fp@922: /*****************************************************************************/ fp@922: fp@948: typedef struct { fp@948: // inputs fp@1507: uint32_t index; fp@1507: fp@1507: // outputs fp@1507: uint32_t data_size; fp@1507: uint32_t logical_base_address; fp@1507: uint16_t working_counter; fp@1507: uint16_t expected_working_counter; fp@978: uint32_t fmmu_count; fp@948: } ec_ioctl_domain_t; fp@948: fp@948: /*****************************************************************************/ fp@948: fp@949: typedef struct { fp@949: // inputs fp@1507: uint32_t domain_index; fp@1507: uint32_t fmmu_index; fp@950: fp@950: // outputs fp@950: uint16_t slave_config_alias; fp@950: uint16_t slave_config_position; fp@1055: uint8_t sync_index; fp@1055: ec_direction_t dir; fp@1507: uint32_t logical_address; fp@978: uint32_t data_size; fp@950: } ec_ioctl_domain_fmmu_t; fp@950: fp@950: /*****************************************************************************/ fp@950: fp@950: typedef struct { fp@950: // inputs fp@1507: uint32_t domain_index; fp@978: uint32_t data_size; fp@990: uint8_t *target; fp@1079: } ec_ioctl_domain_data_t; fp@949: fp@949: /*****************************************************************************/ fp@949: fp@960: typedef struct { fp@960: // inputs fp@1507: uint16_t slave_position; fp@1148: uint8_t al_state; fp@960: } ec_ioctl_slave_state_t; fp@960: fp@960: /*****************************************************************************/ fp@960: fp@965: typedef struct { fp@965: // inputs fp@965: uint16_t slave_position; fp@965: uint16_t sdo_position; fp@965: fp@965: // outputs fp@965: uint16_t sdo_index; fp@965: uint8_t max_subindex; fp@990: int8_t name[EC_IOCTL_STRING_SIZE]; fp@1079: } ec_ioctl_slave_sdo_t; fp@965: fp@965: /*****************************************************************************/ fp@965: fp@965: typedef struct { fp@965: // inputs fp@965: uint16_t slave_position; fp@968: int sdo_spec; // positive: index, negative: list position fp@965: uint8_t sdo_entry_subindex; fp@965: fp@965: // outputs fp@965: uint16_t data_type; fp@965: uint16_t bit_length; fp@1382: uint8_t read_access[EC_SDO_ENTRY_ACCESS_COUNT]; fp@1382: uint8_t write_access[EC_SDO_ENTRY_ACCESS_COUNT]; fp@990: int8_t description[EC_IOCTL_STRING_SIZE]; fp@1079: } ec_ioctl_slave_sdo_entry_t; fp@965: fp@965: /*****************************************************************************/ fp@965: fp@968: typedef struct { fp@968: // inputs fp@968: uint16_t slave_position; fp@968: uint16_t sdo_index; fp@968: uint8_t sdo_entry_subindex; fp@978: uint32_t target_size; fp@968: uint8_t *target; fp@968: fp@968: // outputs fp@978: uint32_t data_size; fp@1037: uint32_t abort_code; fp@1079: } ec_ioctl_slave_sdo_upload_t; fp@968: fp@968: /*****************************************************************************/ fp@968: fp@974: typedef struct { fp@974: // inputs fp@974: uint16_t slave_position; fp@974: uint16_t sdo_index; fp@974: uint8_t sdo_entry_subindex; fp@978: uint32_t data_size; fp@974: uint8_t *data; fp@1037: fp@1037: // outputs fp@1037: uint32_t abort_code; fp@1079: } ec_ioctl_slave_sdo_download_t; fp@974: fp@974: /*****************************************************************************/ fp@974: fp@978: typedef struct { fp@978: // inputs fp@978: uint16_t slave_position; fp@978: uint16_t offset; fp@978: uint32_t nwords; fp@978: uint16_t *words; fp@1079: } ec_ioctl_slave_sii_t; fp@978: fp@978: /*****************************************************************************/ fp@978: fp@990: typedef struct { fp@990: // inputs fp@1200: uint16_t slave_position; fp@1200: uint16_t offset; fp@1200: uint16_t length; fp@1200: uint8_t *data; fp@1388: } ec_ioctl_slave_reg_t; fp@1200: fp@1200: /*****************************************************************************/ fp@1200: fp@1200: typedef struct { fp@1200: // inputs fp@1335: uint16_t slave_position; fp@1335: uint16_t offset; fp@1335: uint32_t buffer_size; fp@1335: uint8_t *buffer; fp@1335: fp@1335: // outputs fp@1335: uint32_t data_size; fp@1336: uint32_t result; fp@1336: uint32_t error_code; fp@1335: char file_name[32]; fp@1335: } ec_ioctl_slave_foe_t; fp@1335: fp@1335: /*****************************************************************************/ fp@1335: fp@1335: typedef struct { fp@1335: // inputs fp@1831: uint16_t slave_position; fp@1952: uint8_t drive_no; fp@1831: uint16_t idn; fp@1831: uint32_t mem_size; fp@1831: uint8_t *data; fp@1831: fp@1831: // outputs fp@1831: uint32_t data_size; fp@1831: uint16_t error_code; fp@1837: } ec_ioctl_slave_soe_read_t; fp@1837: fp@1837: /*****************************************************************************/ fp@1837: fp@1837: typedef struct { fp@1837: // inputs fp@1837: uint16_t slave_position; fp@1952: uint8_t drive_no; fp@1837: uint16_t idn; fp@1837: uint32_t data_size; fp@1837: uint8_t *data; fp@1837: fp@1837: // outputs fp@1837: uint16_t error_code; fp@1837: } ec_ioctl_slave_soe_write_t; fp@1831: fp@1831: /*****************************************************************************/ fp@1831: fp@1831: typedef struct { fp@1831: // inputs fp@990: uint32_t config_index; fp@990: fp@990: // outputs fp@990: uint16_t alias; fp@990: uint16_t position; fp@990: uint32_t vendor_id; fp@990: uint32_t product_code; fp@1055: struct { fp@1055: ec_direction_t dir; fp@1509: ec_watchdog_mode_t watchdog_mode; fp@1055: uint32_t pdo_count; fp@1509: uint8_t config_this; fp@1082: } syncs[EC_MAX_SYNC_MANAGERS]; fp@1509: uint16_t watchdog_divider; fp@1509: uint16_t watchdog_intervals; fp@990: uint32_t sdo_count; fp@1147: int32_t slave_position; fp@1455: uint16_t dc_assign_activate; fp@1455: ec_sync_signal_t dc_sync[EC_SYNC_SIGNAL_COUNT]; fp@990: } ec_ioctl_config_t; fp@990: fp@990: /*****************************************************************************/ fp@990: fp@990: typedef struct { fp@990: // inputs fp@990: uint32_t config_index; fp@1055: uint8_t sync_index; fp@1055: uint16_t pdo_pos; fp@990: fp@990: // outputs fp@990: uint16_t index; fp@990: uint8_t entry_count; fp@990: int8_t name[EC_IOCTL_STRING_SIZE]; fp@990: } ec_ioctl_config_pdo_t; fp@990: fp@990: /*****************************************************************************/ fp@990: fp@990: typedef struct { fp@990: // inputs fp@990: uint32_t config_index; fp@1055: uint8_t sync_index; fp@1055: uint16_t pdo_pos; fp@1055: uint8_t entry_pos; fp@990: fp@990: // outputs fp@990: uint16_t index; fp@990: uint8_t subindex; fp@990: uint8_t bit_length; fp@990: int8_t name[EC_IOCTL_STRING_SIZE]; fp@990: } ec_ioctl_config_pdo_entry_t; fp@990: fp@990: /*****************************************************************************/ fp@990: fp@1526: /** Maximum size for displayed SDO data. fp@1526: * \todo Make this dynamic. fp@1526: */ fp@1526: #define EC_MAX_SDO_DATA_SIZE 1024 fp@1526: fp@990: typedef struct { fp@990: // inputs fp@990: uint32_t config_index; fp@990: uint32_t sdo_pos; fp@990: fp@990: // outputs fp@990: uint16_t index; fp@990: uint8_t subindex; fp@990: uint32_t size; fp@1526: uint8_t data[EC_MAX_SDO_DATA_SIZE]; fp@990: } ec_ioctl_config_sdo_t; fp@990: fp@990: /*****************************************************************************/ fp@990: fp@1516: #ifdef EC_EOE fp@1516: fp@1255: typedef struct { fp@1485: // input fp@1485: uint16_t eoe_index; fp@1485: fp@1485: // outputs fp@1507: char name[EC_DATAGRAM_NAME_SIZE]; fp@1507: uint16_t slave_position; fp@1507: uint8_t open; fp@1507: uint32_t rx_bytes; fp@1507: uint32_t rx_rate; fp@1507: uint32_t tx_bytes; fp@1507: uint32_t tx_rate; fp@1507: uint32_t tx_queued_frames; fp@1507: uint32_t tx_queue_size; fp@1485: } ec_ioctl_eoe_handler_t; fp@1485: fp@1516: #endif fp@1516: fp@1485: /*****************************************************************************/ fp@1485: fp@1485: typedef struct { fp@1255: // inputs fp@1255: uint32_t config_index; fp@1255: uint16_t pdo_index; fp@1255: uint16_t entry_index; fp@1255: uint8_t entry_subindex; fp@1255: uint8_t entry_bit_length; fp@1255: } ec_ioctl_add_pdo_entry_t; fp@1255: fp@1255: /*****************************************************************************/ fp@1255: fp@1255: typedef struct { fp@1255: // inputs fp@1255: uint32_t config_index; fp@1255: uint16_t entry_index; fp@1255: uint8_t entry_subindex; fp@1255: uint32_t domain_index; fp@1255: fp@1255: // outputs fp@1255: unsigned int bit_position; fp@1255: } ec_ioctl_reg_pdo_entry_t; fp@1255: fp@1255: /*****************************************************************************/ fp@1255: fp@1255: typedef struct { fp@1255: // inputs fp@1255: uint32_t config_index; fp@1255: uint16_t index; fp@1255: uint8_t subindex; fp@1255: const uint8_t *data; fp@1255: size_t size; fp@1526: uint8_t complete_access; fp@1255: } ec_ioctl_sc_sdo_t; fp@1255: fp@1255: /*****************************************************************************/ fp@1255: fp@1259: typedef struct { fp@1259: // inputs fp@1259: uint32_t config_index; fp@1259: fp@1259: // outputs fp@1259: ec_slave_config_state_t *state; fp@1259: } ec_ioctl_sc_state_t; fp@1259: fp@1259: /*****************************************************************************/ fp@1259: fp@1259: typedef struct { fp@1259: // inputs fp@1862: uint32_t config_index; fp@1952: uint8_t drive_no; fp@1862: uint16_t idn; fp@1945: ec_al_state_t al_state; fp@1862: const uint8_t *data; fp@1862: size_t size; fp@1862: } ec_ioctl_sc_idn_t; fp@1862: fp@1862: /*****************************************************************************/ fp@1862: fp@1862: typedef struct { fp@1862: // inputs fp@1259: uint32_t domain_index; fp@1259: fp@1259: // outputs fp@1259: ec_domain_state_t *state; fp@1259: } ec_ioctl_domain_state_t; fp@1259: fp@1259: /*****************************************************************************/ fp@1259: fp@1264: typedef struct { fp@1264: // inputs fp@1264: uint32_t config_index; fp@1264: fp@1264: // inputs/outputs fp@1352: uint32_t request_index; fp@1352: uint16_t sdo_index; fp@1352: uint8_t sdo_subindex; fp@1352: size_t size; fp@1352: uint8_t *data; fp@1352: uint32_t timeout; fp@1352: ec_request_state_t state; fp@1352: } ec_ioctl_sdo_request_t; fp@1352: fp@1352: /*****************************************************************************/ fp@1352: fp@1352: typedef struct { fp@1352: // inputs fp@1352: uint32_t config_index; fp@1352: fp@1352: // inputs/outputs fp@1264: uint32_t voe_index; fp@1264: uint32_t *vendor_id; fp@1264: uint16_t *vendor_type; fp@1264: size_t size; fp@1264: uint8_t *data; fp@1264: ec_request_state_t state; fp@1264: } ec_ioctl_voe_t; fp@1264: fp@1264: /*****************************************************************************/ fp@1264: fp@1455: typedef struct { fp@1455: // inputs fp@1455: uint64_t app_time; fp@1455: } ec_ioctl_app_time_t; fp@1455: fp@1455: /*****************************************************************************/ fp@1455: fp@1082: /** \endcond */ fp@1082: fp@922: #endif