提示词:补齐 G64 naivecam tolerance 源链接覆盖
This commit is contained in:
@@ -336,6 +336,12 @@ CNC_SIM_RS274_VAR="$var_file" \
|
||||
CNC_SIM_RS274_VAR="$var_file" \
|
||||
"$build_dir/linuxcnc_rs274_source_dump" tests/gcode/linuxcnc_motion_modes.ngc \
|
||||
>"$output_dir/cnc_sim_linuxcnc_source_motion_modes.json"
|
||||
# Source basis: LinuxCNC src/emc/rs274ngc/interp_convert.cc
|
||||
# convert_control_mode() sends G64 P through SET_MOTION_CONTROL_MODE()
|
||||
# and G64 Q through SET_NAIVECAM_TOLERANCE(), defaulting Q to P when Q is omitted.
|
||||
CNC_SIM_RS274_VAR="$var_file" \
|
||||
"$build_dir/linuxcnc_rs274_source_dump" tests/gcode/linuxcnc_control_mode_tolerances.ngc \
|
||||
>"$output_dir/cnc_sim_linuxcnc_source_control_mode_tolerances.json"
|
||||
CNC_SIM_RS274_VAR="$var_file" \
|
||||
"$build_dir/linuxcnc_rs274_source_dump" tests/gcode/linuxcnc_tool_length.ngc \
|
||||
>"$output_dir/cnc_sim_linuxcnc_source_tool_length.json"
|
||||
@@ -1840,6 +1846,23 @@ expected_override_states = [
|
||||
if override_states != expected_override_states:
|
||||
raise SystemExit(f"unexpected source-linked M48-M53 override states: {override_states!r}")
|
||||
|
||||
control_mode_tolerances = json.loads((OUTPUT_DIR / "cnc_sim_linuxcnc_source_control_mode_tolerances.json").read_text())
|
||||
control_mode_tolerance_states = [
|
||||
(event["line"], event["reserved"], event["feed"])
|
||||
for event in control_mode_tolerances
|
||||
if event["type"] == "comment" and event["reserved"] in {611, 612, 640, 641}
|
||||
]
|
||||
expected_control_mode_tolerance_states = [
|
||||
(2, 640, 0.05),
|
||||
(2, 641, 0.02),
|
||||
(3, 640, 0.03),
|
||||
(3, 641, 0.03),
|
||||
(4, 611, 0),
|
||||
(5, 612, 0),
|
||||
]
|
||||
if control_mode_tolerance_states != expected_control_mode_tolerance_states:
|
||||
raise SystemExit(f"unexpected source-linked G64 P/Q control mode tolerance states: {control_mode_tolerance_states!r}")
|
||||
|
||||
modal_state = json.loads((OUTPUT_DIR / "cnc_sim_linuxcnc_source_modal_state.json").read_text())
|
||||
if not any(
|
||||
event["type"] == "rapid" and
|
||||
|
||||
Reference in New Issue
Block a user