mirror of
https://github.com/synthetos/g2.git
synced 2026-09-21 02:05:17 +08:00
Checkpoint
This commit is contained in:
@@ -540,8 +540,8 @@ stat_t mp_exec_aline(mpBuf_t *bf)
|
||||
st_request_forward_plan();
|
||||
}
|
||||
}
|
||||
copy_vector(mr->end_position, mr->position); // record end position
|
||||
copy_vector(mp->position, mr->position); // record end position
|
||||
//+++++ copy_vector(mr->end_position, mr->position); // record end position
|
||||
copy_vector(mp->position, mr->position); // record actual end position of the move
|
||||
}
|
||||
return (status);
|
||||
}
|
||||
@@ -1027,14 +1027,13 @@ static stat_t _exec_aline_feedhold(mpBuf_t *bf)
|
||||
cm->hold_state = FEEDHOLD_OFF;
|
||||
}
|
||||
|
||||
// In a regular p1 hold
|
||||
// In a regular p1 hold. Motion has stopped, so we can rely on positions and other values to be stable
|
||||
else {
|
||||
|
||||
// Reset the state of the p1 planner regardless of how hold will ultimately be exited.
|
||||
bf->length = get_axis_vector_length(mr->position, mr->target); // get remaining length in move
|
||||
copy_vector(mp->position, mr->position); // update planner position from runtime
|
||||
copy_vector(mr->end_position, mr->position);// record end position
|
||||
|
||||
copy_vector(mp->position, mr->position); // update planner position from runtime position
|
||||
|
||||
bf->block_state = BLOCK_INITIAL_ACTION; // tell _exec to re-use the bf buffer
|
||||
mr->block_state = BLOCK_INACTIVE; // invalidate mr buffer to reset the new move
|
||||
bf->plannable = true; // needed so black can be adjusted
|
||||
@@ -1045,7 +1044,7 @@ static stat_t _exec_aline_feedhold(mpBuf_t *bf)
|
||||
// Set state to enable transition to p2 and perform entry actions in the p2 planner
|
||||
cm->hold_state = FEEDHOLD_ACTIONS_START; // executes entirely out of p2 planner
|
||||
}
|
||||
|
||||
|
||||
sr_request_status_report(SR_REQUEST_IMMEDIATE);
|
||||
cs.controller_state = CONTROLLER_READY; // remove controller readline() PAUSE
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user