Hi all, I have to modify the EtherCAT Master to allow the Eeprom reading, first to go in preop state.
So I have to write the register 0x500 with data 0x01. I read to an old mail, that I have to modify the fsm_slave_config.c file. I try this: void ec_fsm_slave_config_enter_boot_preop( ec_fsm_slave_config_t *fsm /**< slave state machine */ ) { // patch monteleone // ec_slave_t *slave = fsm->slave; // ec_datagram_t *datagram; // ec_datagram_fpwr(datagram, slave->station_address, 0x500, 1); // EC_WRITE_U8(datagram->data, 0x01); // fine patch fsm->state = ec_fsm_slave_config_state_boot_preop; if (fsm->slave->requested_state != EC_SLAVE_STATE_BOOT) { ec_fsm_change_start(fsm->fsm_change, fsm->slave, EC_SLAVE_STATE_PREOP); } else { // BOOT ec_fsm_change_start(fsm->fsm_change, fsm->slave, EC_SLAVE_STATE_BOOT); } ec_fsm_change_exec(fsm->fsm_change); // execute immediately } but is not correct? what I have to do? greatings simone monteleone Alice body {margin:0;padding:0;} #footer { height:13px; font-size:11px; font-family:Arial, FreeSans, sans-serif; color:#ADADAD; margin:0; padding:7px 12px; text-align:right; border-top:1px solid #dcdcdc; } #footer a { text-decoration:none; color:#ADADAD; } #footer a:hover { color:#848484; } Inviato dalla nuova Alice mail
_______________________________________________ etherlab-users mailing list etherlab-users@etherlab.org http://lists.etherlab.org/mailman/listinfo/etherlab-users