From: EMC C. s. <cv...@cv...> - 2006-09-14 20:47:44
|
Modified file emc2/src/emc/task/taskintf.cc Full file: <http://cvs.linuxcnc.org/cvs/emc2/src/emc/task/taskintf.cc?rev=1.47> Difference: <http://cvs.linuxcnc.org/cvs/emc2/src/emc/task/taskintf.cc.diff?r1=1.46;r2=1.47> Branch: HEAD Log: revision 1.47 date: 2006/09/14 20:47:38; author: jepler; state: Exp; lines: +7 -2 Add sequential homing of multiple axes using [AXIS_*]HOME_SEQUENCE to specify the sequence. Add shared limit switches, which prevents homing on an axis when the switch begins closed, using [AXIS_*]HOME_IS_SHARED. --- taskintf.cc 2006/09/11 19:00:49 1.46 +++ taskintf.cc 2006/09/14 20:47:38 1.47 @@ -367,7 +367,8 @@ int emcAxisSetHomingParams(int axis, double home, double offset, double search_vel, double latch_vel, - int use_index, int ignore_limits) + int use_index, int ignore_limits, int is_shared, + int sequence) { if (axis < 0 || axis >= EMCMOT_MAX_AXIS) { return 0; @@ -380,12 +381,16 @@ emcmotCommand.search_vel = search_vel; emcmotCommand.latch_vel = latch_vel; emcmotCommand.flags = 0; + emcmotCommand.home_sequence = sequence; if (use_index) { emcmotCommand.flags |= HOME_USE_INDEX; } if (ignore_limits) { emcmotCommand.flags |= HOME_IGNORE_LIMITS; } + if (is_shared) { + emcmotCommand.flags |= HOME_IS_SHARED; + } #ifdef ISNAN_TRAP if (isnan(emcmotCommand.home) || isnan(emcmotCommand.offset) || @@ -585,7 +590,7 @@ int emcAxisHome(int axis) { - if (axis < 0 || axis >= EMCMOT_MAX_AXIS) { + if (axis < -1 || axis >= EMCMOT_MAX_AXIS) { return 0; } Modified file emc2/src/emc/task/emctaskmain.cc Full file: <http://cvs.linuxcnc.org/cvs/emc2/src/emc/task/emctaskmain.cc?rev=1.69> Difference: <http://cvs.linuxcnc.org/cvs/emc2/src/emc/task/emctaskmain.cc.diff?r1=1.68;r2=1.69> Branch: HEAD Log: revision 1.69 date: 2006/09/14 20:47:38; author: jepler; state: Exp; lines: +3 -2 Add sequential homing of multiple axes using [AXIS_*]HOME_SEQUENCE to specify the sequence. Add shared limit switches, which prevents homing on an axis when the switch begins closed, using [AXIS_*]HOME_IS_SHARED. --- emctaskmain.cc 2006/09/11 18:57:43 1.68 +++ emctaskmain.cc 2006/09/14 20:47:38 1.69 @@ -1511,8 +1511,9 @@ set_homing_params_msg->search_vel, set_homing_params_msg->latch_vel, set_homing_params_msg->use_index, - set_homing_params_msg-> - ignore_limits); + set_homing_params_msg->ignore_limits, + set_homing_params_msg->is_shared, + set_homing_params_msg->home_sequence); break; /*! \todo Another #if 0 */ |