Skip to content

Wire the GUI to the existing planning backend - #185

Merged
mountainarcwelding merged 1 commit into
mainfrom
feat/gui-job-flow
Nov 15, 2026
Merged

mountainarcwelding merged 1 commit into
mainfrom
feat/gui-job-flow

Conversation

@mountainarcwelding

Copy link
Copy Markdown
Owner

Wires campanion-gui to the existing planning backend so a 2D cutting job can be opened, planned, and exported from the preview. CAMpanion remains primarily command-line driven; the GUI is still in development and does not talk to a machine.

What this includes

  • campanion-cli is now a library (campanion_cli) with a small public engine the GUI can call. The campanion binary is unchanged in behavior.
  • File > Open / Import can load a campanion-job/1 file or a 2D part (DXF/SVG, same as the CLI). File > Save / Save As writes the job file. Opening a job keeps unused fields (rotary, nest, tilt, and so on) by patching the original JSON.
  • The process tree can add tools and profile operations. The properties panel binds only to parameters the backend already supports. Material values and other numeric fields start empty; the GUI does not invent feeds, depths, or machine limits.
  • Generate toolpaths and Export G-code use the same planner and posts as campanion run. The Process tab suggests grbl_laser for laser jobs (and the matching built-in post for plasma, waterjet, oxy-fuel, and wire EDM). Milling is left without a suggested post because several mill posts exist.
  • Backend warnings and refusals are shown in the UI, including omitted laser power (posts S0, never full scale) and a slot narrower than the kerf.
  • A banner, the status bar, and Help > About state: "Preview: CAMpanion is primarily command-line driven; the GUI is still in development."
  • The Run tab, STOP, and all machine I/O stay inert. Resin (SLA) tabs and FDM remain placeholders. Per-contour kerf and lead-in overrides are not in the job format and stay as a labeled placeholder.
  • examples/laser_rect.svg and examples/laser_rect.job.json are a small 20×10 mm laser job that posts with grbl_laser.

scripts/check.sh (fmt, clippy, tests, wasm, cargo-deny) was run locally and passed (1294 tests passed, 1 ignored).

Refs: GUI job flow.

campanion-cli is now a library the graphical workspace can call. The
preview can open or import a 2D part or job, edit tools and profile
operations, generate toolpaths, choose a post, preview G-code, and
export .ngc or .gcode through the same planner the CLI uses. Material
values stay blank until the user enters them. Backend warnings and
refusals (omitted laser power, narrow slots) are shown in the UI.

CAMpanion remains primarily command-line driven; the GUI is still in
development and does not talk to a machine. The Run tab, STOP, and
all machine I/O stay inert. Resin and FDM remain placeholders.
Per-contour kerf and lead-in overrides are not in the job format and
stay as a labeled placeholder.

Also adds examples/laser_rect.svg and examples/laser_rect.job.json
for a small laser job that posts with grbl_laser.
@mountainarcwelding
mountainarcwelding merged commit 926989d into main Nov 15, 2026
1 check passed
mountainarcwelding added a commit that referenced this pull request Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant