Skip to content

Ensure real90 axis moves are signed and axis-aligned#2

Open
peterwolf-pl wants to merge 4 commits into
mainfrom
codex/implement-serpentine-mode-for-printing
Open

Ensure real90 axis moves are signed and axis-aligned#2
peterwolf-pl wants to merge 4 commits into
mainfrom
codex/implement-serpentine-mode-for-printing

Conversation

@peterwolf-pl
Copy link
Copy Markdown
Owner

Summary

  • emit signed Y-then-X axis legs for 90° modes to keep serpentine passes strictly horizontal/vertical
  • always snap to the preferred row heading even when no X travel is required

Testing

  • not run (not requested)

Codex Task

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9079744791

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread artacodepng.py Outdated
Comment on lines +372 to +376
if abs(dtheta) > 1e-9:
emit_turn_in_place(out, dtheta, feed_turn)
heading = axis_y
emit_straight(out, abs(dy), feed_lin)
heading = axis_heading
if abs(delta) > 1e-9:
emit_straight(out, delta, feed_lin)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Signed axis legs reverse motion in real90 moves

In axis_move_to, emit_axis_leg now forwards the signed delta to emit_straight after rotating to the target axis heading. When dx/dy is negative (e.g., moving from x=10 to x=0 in real90 mode), the heading is set to π or -π/2 to face the target, but emit_straight receives a negative distance, which drives the robot backwards relative to that heading—moving away from the target instead of toward it. This reverses travel for any negative leg and prevents the plotter from reaching the intended point.

Useful? React with 👍 / 👎.

Base automatically changed from serp to main January 3, 2026 06:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant