master/ioctl.h
changeset 2068 3001f6523e63
parent 2042 8b358effa78b
child 2150 5144a4bc6184
equal deleted inserted replaced
2067:19732da2cf86 2068:3001f6523e63
    54 
    54 
    55 /** EtherCAT master ioctl() version magic.
    55 /** EtherCAT master ioctl() version magic.
    56  *
    56  *
    57  * Increment this when changing the ioctl interface!
    57  * Increment this when changing the ioctl interface!
    58  */
    58  */
    59 #define EC_IOCTL_VERSION_MAGIC 11
    59 #define EC_IOCTL_VERSION_MAGIC 12
    60 
    60 
    61 // Command-line tool
    61 // Command-line tool
    62 #define EC_IOCTL_MODULE                EC_IOR(0x00, ec_ioctl_module_t)
    62 #define EC_IOCTL_MODULE                EC_IOR(0x00, ec_ioctl_module_t)
    63 #define EC_IOCTL_MASTER                EC_IOR(0x01, ec_ioctl_master_t)
    63 #define EC_IOCTL_MASTER                EC_IOR(0x01, ec_ioctl_master_t)
    64 #define EC_IOCTL_SLAVE                EC_IOWR(0x02, ec_ioctl_slave_t)
    64 #define EC_IOCTL_SLAVE                EC_IOWR(0x02, ec_ioctl_slave_t)
   135 #define EC_IOCTL_VOE_READ_NOSYNC       EC_IOW(0x45, ec_ioctl_voe_t)
   135 #define EC_IOCTL_VOE_READ_NOSYNC       EC_IOW(0x45, ec_ioctl_voe_t)
   136 #define EC_IOCTL_VOE_WRITE            EC_IOWR(0x46, ec_ioctl_voe_t)
   136 #define EC_IOCTL_VOE_WRITE            EC_IOWR(0x46, ec_ioctl_voe_t)
   137 #define EC_IOCTL_VOE_EXEC             EC_IOWR(0x47, ec_ioctl_voe_t)
   137 #define EC_IOCTL_VOE_EXEC             EC_IOWR(0x47, ec_ioctl_voe_t)
   138 #define EC_IOCTL_VOE_DATA             EC_IOWR(0x48, ec_ioctl_voe_t)
   138 #define EC_IOCTL_VOE_DATA             EC_IOWR(0x48, ec_ioctl_voe_t)
   139 #define EC_IOCTL_SET_SEND_INTERVAL     EC_IOW(0x49, size_t)
   139 #define EC_IOCTL_SET_SEND_INTERVAL     EC_IOW(0x49, size_t)
       
   140 #define EC_IOCTL_MASTER_SC_STATE        EC_IOR(0x50, ec_master_state_t)
       
   141 #define EC_IOCTL_SC_OVERLAPPING_IO      EC_IOW(0x51, ec_ioctl_config_t)
   140 
   142 
   141 /*****************************************************************************/
   143 /*****************************************************************************/
   142 
   144 
   143 #define EC_IOCTL_STRING_SIZE 64
   145 #define EC_IOCTL_STRING_SIZE 64
   144 
   146 
   276     // inputs
   278     // inputs
   277     uint32_t index;
   279     uint32_t index;
   278 
   280 
   279     // outputs
   281     // outputs
   280     uint32_t data_size;
   282     uint32_t data_size;
       
   283     uint32_t tx_size;
   281     uint32_t logical_base_address;
   284     uint32_t logical_base_address;
   282     uint16_t working_counter;
   285     uint16_t working_counter;
   283     uint16_t expected_working_counter;
   286     uint16_t expected_working_counter;
   284     uint32_t fmmu_count;
   287     uint32_t fmmu_count;
   285 } ec_ioctl_domain_t;
   288 } ec_ioctl_domain_t;
   295     uint16_t slave_config_alias;
   298     uint16_t slave_config_alias;
   296     uint16_t slave_config_position;
   299     uint16_t slave_config_position;
   297     uint8_t sync_index;
   300     uint8_t sync_index;
   298     ec_direction_t dir;
   301     ec_direction_t dir;
   299     uint32_t logical_address;
   302     uint32_t logical_address;
       
   303     uint32_t domain_address;
   300     uint32_t data_size;
   304     uint32_t data_size;
   301 } ec_ioctl_domain_fmmu_t;
   305 } ec_ioctl_domain_fmmu_t;
   302 
   306 
   303 /*****************************************************************************/
   307 /*****************************************************************************/
   304 
   308 
   457         uint32_t pdo_count;
   461         uint32_t pdo_count;
   458         uint8_t config_this;
   462         uint8_t config_this;
   459     } syncs[EC_MAX_SYNC_MANAGERS];
   463     } syncs[EC_MAX_SYNC_MANAGERS];
   460     uint16_t watchdog_divider;
   464     uint16_t watchdog_divider;
   461     uint16_t watchdog_intervals;
   465     uint16_t watchdog_intervals;
       
   466     uint8_t allow_overlapping_pdos;
   462     uint32_t sdo_count;
   467     uint32_t sdo_count;
   463     uint32_t idn_count;
   468     uint32_t idn_count;
   464     int32_t slave_position;
   469     int32_t slave_position;
   465     uint16_t dc_assign_activate;
   470     uint16_t dc_assign_activate;
   466     ec_sync_signal_t dc_sync[EC_SYNC_SIGNAL_COUNT];
   471     ec_sync_signal_t dc_sync[EC_SYNC_SIGNAL_COUNT];