A Linux/Qt6 CAD/CAM application for Carbide Create .c2d files and GRBL
machines (Shapeoko) — a Carbide-Create-and-Carbide-Motion-free workflow on
Linux, built on the reverse-engineered format documentation in
shapeoko-c2d.
sudo apt install build-essential cmake qt6-base-dev qt6-base-dev-tools \
libqt6sql6-sqlite qt6-serialport-dev zlib1g-dev libgl1-mesa-dev \
libboost-dev
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build -j$(nproc)
./build/phobicccp yourfile.c2dcmake --build build also builds every test program. To update just the program,
build only its target, which is much quicker:
cmake --build build -j$(nproc) --target phobicccpInstall (binary + start-menu launcher + icon + .c2d file association):
sudo cmake --install build # system-wide, /usr/local
cmake --install build --prefix ~/.local # or per-user, no rootAfter that phobiCCCP shows up in the application menu (search "phobic")
and .c2d files open with it on double-click (Syntexophobic .cccp projects too, as their
finished part: sketches as vectors, the part as an STL model). For the Machine dock you also
need serial access: sudo usermod -aG dialout $USER, then log out and in.
Clipper2 is fetched at configure time (disable with
-DPHOBICCCP_WITH_CLIPPER2=OFF). libboost-dev provides the header-only
Boost.Polygon Voronoi builder for the medial-axis v-carve; without it the
build falls back to depth-graded ring approximation.
Tests: ctest --test-dir build (set QT_QPA_PLATFORM=offscreen without a
display). GitHub Actions runs the same build and suite on every push and pull
request (.github/workflows/ci.yml).
The same program builds as an Android app with Qt for Android (6.8, arm64), the
Android SDK (platform 34) and NDK 26.1; qt-android/ holds its manifest and icon (not Android/, the Flutter app:
the two names would clash on Windows and macOS).
CI builds it on every push (the android-qt job; the APK is in the run's
artifacts).
/path/to/Qt/6.8.3/android_arm64_v8a/bin/qt-cmake -S . -B build-android -G Ninja \
-DCMAKE_BUILD_TYPE=Release -DQT_HOST_PATH=/path/to/Qt/6.8.3/gcc_64 \
-DANDROID_SDK_ROOT=$ANDROID_SDK_ROOT -DANDROID_NDK_ROOT=$ANDROID_SDK_ROOT/ndk/26.1.10909125
cmake --build build-android # build-android/android-build/build/outputs/apk/release/Touch: hold a finger still to right-click, pinch with two fingers to zoom and pan the canvas. File > Send to phobiCCCP… sends the design to the computer by the machine (which needs File > Receive from Syntexophobic and pads on), and can start the cut there. There is no serial port on a pad, so the Machine side there has nothing to connect to. V-carve is the same medial-axis one as on a computer (Boost.Polygon headers, taken from the build machine). The other way, File > Send to pad… on a computer lists the pads running this program and opens the design there.
Four modes, in the order of the work: Design → Toolpaths → Simulate → Machine (Ctrl+1…4, or the switch at the top right). Made for a touchscreen on the shop PC.
| Design | Toolpaths |
|---|---|
![]() |
![]() |
| Simulate | Machine |
|---|---|
![]() |
![]() |
- Design – open a
.c2d(or start on the blank design sized to the machine in Settings), draw or import SVG/DXF, edit nodes, arrange. - Toolpaths – select vectors, press a toolpath kind in the top bar (Contour, Pocket, Drill, V-Carve, Adaptive, …). Each button's tooltip says what the cut does. Edit depth, tool and feeds in the list on the right; G1 Preview draws the result on the canvas.
- Simulate – the program is rebuilt and simulated by itself: the 3D route on the left, the material-removal heightmap on the right. Orbit, play, read X/Y/Z of the cut surface under the cursor.
- Machine – Connect, Initialize (homes, then parks front right), mount the bit, set zero with the BitZero (corner / Z / X / Y) or the Zero buttons, Measure bit on the BitSetter, then Start. Tool changes park the spindle, prompt, measure the new bit and continue. For a table or board that is not flat, Surface map on the BitZero page touches the plate at a grid of points; with Surface map ticked under the job, every Z follows it.
Examples of the command line (screenshots, headless export, probing) are under CLI.
Files
- Opens modern (v7/v8, SQLite container)
.c2dfiles natively - Saves them back so Carbide Create 8 still opens them (round-trip verified); toolpath edits and newly created toolpaths are written into the container
- All 5 element types render: circle, rectangle, regular polygon, path, text
Parametric sketching (Fusion style)
- Constrain (G, hold for the list): coincident, horizontal, vertical, parallel, perpendicular, tangent, equal, collinear, concentric, midpoint, fix and symmetric; the drawing obeys at once, one undo step each
- Dimension (D): lengths, distances (horizontal, vertical or aligned by
where the label goes), diameters (Shift: radius) and angles; type a value
or an expression such as
plate_w / 2 - 10 - Parameters tab: user parameters with expressions and comments, the
stock size as
stock_w,stock_h,stock_t, every dimension and constraint, and a chip that says fully constrained / degrees of freedom left / what can't hold. Fully constrained shapes turn teal - Toolpath number fields take expressions (
1/4 in,stock_t / 2); one that names a parameter stays bound (violet, ƒx) and follows it - Saved inside the
.c2d; Carbide Create ignores it
Vector editing (Carbide Create parity)
- Booleans: Union (weld), Subtract, Intersect (Edit → Vectors, icon bar); Offset inside/outside by distance; Align left/right/top/bottom/ centres, Center on stock, Distribute — all single undo steps, and toolpaths that referenced the inputs follow the results
- Mirror horizontally / vertically, Grid array (columns × rows, edge-to-edge gap) and Circular array (count, center, full turn or arc, rotate copies or not) and Pattern on path (along the vector selected last, spread or by spacing, turning with it); copies can join the originals' toolpaths
- Fillet and Chamfer corners, Rotate, Scale (percent or target size) and Move / Copy by exact distance (Edit → Vectors → Modify); shapes stay circles / rectangles / polygons wherever they can
- Bezier splines: pen-style Path tool (click = corner, drag = smooth handles) and a Node edit tool (N): drag anchors/handles, insert (double-click), delete, corner/smooth/symmetric, convert shapes and text to paths
- Text on arc (radius, angle offset, top/bottom) plus font family, bold, italic in the Properties panel
- Import SVG and DXF (File menu or drag-and-drop): paths with beziers, transforms, units; DXF LINE/LWPOLYLINE/ARC/CIRCLE/ELLIPSE/SPLINE/INSERT
- Background image under the grid (position, width, rotation, opacity, lock; stored in the .c2d the way CC does) and Trace image (threshold, blur, despeckle, simplify, smoothing) to closed vector paths
- Original tools still there:
- Tools: Select (V), Circle (C: center, 2-point, 3-point, 2- and 3-tangent), Rectangle (R: 2-point, 3-point, center), Polygon (P: inscribed, circumscribed, edge), Path/polyline (L), fit-point Spline (K), Conic (Q), Point (O), Text (T), Ellipse (E, Ctrl-drag from the center), Slot (S: center to center, overall, center point, 3-point arc), Arc (A: 3-point, center point, tangent); Construction (Shift+X) makes vectors dashed reference geometry that is never machined; Trim (X), Extend (J) and Break (B) at the crossings with other curves; Measure (M) — with live preview, grid + snap (Shift+G), zoom (wheel / F to fit), middle-mouse pan
- Select / rubber-band, drag to move, drag the amber handle to resize, Del to delete, full undo/redo (Ctrl+Z / Ctrl+Shift+Z)
- Properties panel: numeric center / radius / W×H / sides / rotation
- New elements are written in CC's exact JSON schema (key-verified against CC-853 specimens), so toolpaths and CC itself accept them
CAM — every Carbide Create toolpath type, plus engraving and 3D
- Create, duplicate, rename, enable, reorder and delete toolpaths (the Toolpaths panel's New menu covers all seven CC types plus Engrave)
- Engrave: outline, hatch fill (spacing, angle, crosshatch) or both
- Face (flatten the stock), Bore (helical, per circle), Thread milling (internal or external, any pitch and hand) and 2D Chamfer (V-bit bevel along edges, inside or outside), Fusion-style
- Lead-in / lead-out arcs on contours, so the cutter enters and leaves the cut on the air side instead of plunging on the wall
- Finishing passes and a spring pass on contours, helical entry into pockets, and drilling dwell and chip-breaking pecks
- 2D Slot (ramped down each slot's centreline) and Circular (round pockets and bosses in full laps), Fusion-style
- Setup sheet (File menu): a printable page of the stock, tools and every toolpath with its depths, feeds and estimated time
- Adaptive clearing (Fusion's 2D Adaptive): pockets with a light, steady radial bite at a deep stepdown, helix entries, no slotting
- 3D modelling (Model tab): components from vectors (flat / round / angle / dome / smooth), images as heightmaps, tiled textures, STL import; the relief is stored in the .c2d and drives the 3D toolpaths
- 3D roughing and finishing: Z-level clearing and raster finishing on the tool-compensated surface (ball, flat, V), boundary vectors, stepover in mm or %, raster angle, zigzag/climb/conventional, optional cross pass
- Waterline finishing (3D Finish, Strategy: Waterline): Z-level passes that follow every wall once per stepdown along the tool-compensated contour, climb or conventional, linked on the surface where clear
- Terrace levels: 3D roughing (and waterline) put a level exactly on every flat terrace of the model as well as every stepdown, so a flat between two levels is not left with up to a stepdown of material
- Tool library with Carbide 3D's cutters and per-material speeds & feeds (Toolpaths → Tool library…; values that are guesses are flagged as such)
- Rest machining for pockets (
enable_rest/rest_diameter) - No re-cutting: a pocket or adaptive toolpath that overlaps what the
toolpaths above it already cleared cuts only what is left (
rest_auto, on by default), each pass skipping the area already cut to that depth - Area tool works like a fill: a click selects just the area it lands in, bounded by every shape around it; where shapes overlap, that piece is added as a closed path so a toolpath cuts only it
- Toolpath tiling (File → Export G-code (tiled)… or
--export-tiled): one complete program per tile, Y-shifted, cuts split cleanly at the boundary - 3D Simulation tab: material-removal heightmap of the whole program (end mill / ball / V-bit / bull-nose), shaded top-down view with depth readout and through-cut warning
- Gouge check: with a 3D model, every cell where the simulated cut goes below the relief (more than 0.05 mm, measured across the surface) is drawn red and reported with its area and depth
- Rapids into material: every G0 is checked against the stock as cut so far (as the sender executes it: across then down, or up then across); a rapid through stock is reported with its depth, position and toolpath
- Toolpaths panel: edit any toolpath parameter (depths, feeds, stepover,
tool…) and assign the canvas selection as a toolpath's vectors; edits are
saved back into the
.c2din place - G-code export (File → Export G-code, Ctrl+G, or
phobicccp --export in.c2d out.nc) in Carbide Create's own GRBL dialect:- pocket: connected-component inset rings, innermost-first, stay-down linking, alternating pass direction (no track-back), plunge-once-per-depth
- contour: no-offset / inside / outside; cutout:
cut_depth + break_through, auto-tabs, ramp entries - drilling: peck cycles; keyhole: plunge + slide + return; texture: deterministic random hatch strokes
- advanced v-carve: true medial-axis carving (segment Voronoi) — the V-bit rides the skeleton with continuously varying depth, runs out into sharp corners, and clears flat bottoms where it maxes out
- v-carve inlay: one click generates the mirrored male (inverse region in a border, depths shifted by the glue gap) from the female toolpath
- exact offsetting via Clipper2; circular rings become true G2/G3 arcs and all other curves are greedily arc/line-fitted (0.01 mm tolerance), so the GRBL planner never starves on 1 mm segment chatter
- jobs ordered nearest-neighbor to minimize rapids; consecutive same-tool toolpaths are interleaved per site (counterbore + through-hole at one hole, then the next), keeping document order wherever jobs overlap
- On-canvas toolpath preview (Ctrl+P): rapids dashed, cuts colored by depth, plunge markers
- Export/run shows job stats: extents, cut/rapid length, time estimate
Machine control (Machine dock)
-
Connects to a GRBL controller over serial (115200) — hardware-verified against a Shapeoko 5 Pro (GRBL 1.1h). Ports are listed with their USB description; a device path can also be typed by hand.
-
Live status: state, work and machine position side by side (WCO tracked from the status reports), feed / spindle, tool-length offset, probe-pin indicator.
-
Jog: step sizes 0.1 / 1 / 10 / 100 mm and speeds slow / medium / fast / rapid. Click = one step, press and hold = continuous jog cancelled on release (
$J=+ jog-cancel 0x85). Arrow keys jog X/Y and PgUp/PgDn jog Z the same way while the panel has focus. -
Work zero: Zero X / Y / Z / XY / all (
G10 L20), "→ X0 Y0" (raise to safe Z, then rapid to work zero), Home, Unlock. -
BitSetter (tool-length probe): configure the button's machine coordinates ("use current" while parked over it), safe Z, fast/slow probe feeds and a tool-change spot. Measure tool goes there, probes twice (
G38.2, fast then slow), and comes back. The first measurement after Zero Z is the reference tool; every later measurement applies the length difference as aG43.1offset, so a new tool cuts to the same Z0 without re-zeroing. The offset survives resets and unlocks (re-applied automatically) and the reference is remembered between sessions. -
Streaming with tool changes: every
M0 ;T<n>the post emits parks the machine (spindle off, safe Z, tool-change spot), prompts for the tool, measures it on the BitSetter, applies the offset and continues — no manual Resume needed. Character-counting protocol, feed-hold / resume / soft-reset, realtime feed override, progress bar and console. -
USB gamepad (SNES-style pads and anything else the kernel exposes as a joystick): jog from the machine rather than from the keyboard, with no window focus needed. Plug it in at any time — it is found within a second or two and picked up again after unplugging; unplugging mid-jog cancels the motion. Read straight from
/dev/input/js*, which is world-readable on a stock desktop, so there is no udev rule to install and no group to join.control action D-pad ←→ / ↑↓ jog X / Y (tap = one step, hold = continuous) L / R jog Z down / up Select cycle the jog step (0.1 / 1 / 10 / 100 mm) Start Hold / Resume B Stop A zero XY X zero Z Y Unlock ( $X)Starting a program is deliberately not on the pad: a bumped button must never begin a cut. Clones number their buttons differently, so Map buttons… in the Jog box opens a mapping dialog: press a button on the pad to find its row, pick what it does, save (or reset to the defaults above). The pad does nothing else while the dialog is open. Every press is also logged to the machine console with its number, and the mapping is stored in the settings under
gamepad/<number>as one ofx+ x- y+ y- z+ z- step hold stop zeroxy zeroz unlock, ornone. A joystick reporting fewer than two buttons is ignored, which is how a MacBook's lid accelerometer (also ajsdevice) is kept away from the jog. -
Air-cut mode: rehearse any program with all spindle commands stripped and every Z lifted by a chosen amount; every run shows a stats + spindle-warning confirmation first.
-
Rehearse tool change (BitSetter box): runs one tool change on its own, spindle off and nothing cut: park at the tool-change spot, prompt, measure on the BitSetter, apply the offset, back to safe Z. It goes through the same streamer and panel code a job's tool change does, and ends with the offset it measured (with the same tool still in, that should be about zero). Needs a reference tool first (Zero Z with the BitSetter enabled).
-
Verification status: connection, jogging, zeroing and streaming are hardware-verified on a Shapeoko 5 Pro; the BitSetter measurement and the automatic tool-change flow have so far been verified against
tools/grblsim.pyonly (tools/flowtest.sh). Use Rehearse tool change on the machine, then an air-cut run with a real tool change, before trusting them on a job.
From Syntexophobic (File → Receive from Syntexophobic, on by default):
Syntexophobic's File → Send to
phobiCCCP… sends a project here over the local network (phobiCCCP is found by itself)
or Tailscale (its Tailscale name or address is typed in). phobiCCCP asks before it
opens anything, then starts a new design the size of the sent stock with the part as a
3D model and every XY sketch as vectors; the files and the Syntexophobic project with
its history (.cccp) are kept in Documents/phobiCCCP/Received/<name>. The link uses
port 47652 (TCP for the transfer, UDP for being found); src/projectreceiver.h
describes the protocol.
Several machines (Machine menu): add a machine for every router this computer drives. Each keeps its own size, serial port, BitSetter and tool-change spots, reference and surface map; picking one in the menu (or from the pad app) switches to its settings and reconnects.
PhobiCCCP for pads (Android/, Flutter, see Android/README.md):
design on an Android tablet or iPad, synced automatically both ways with every phobiCCCP
on the same network, and sent to any of them, on any of its machines. A design from a pad
stays linked to its .c2d: saving it here updates the pads, and a later pad edit rebuilds
the file while it holds only what the pad can. A pad can also start the cut straight away
when Machine › Pads may start cutting is on (off by default); the machine still has to
be connected, homed and idle. The other way, File › Send to pad… sends the open design
to a pad that is in touch (it opens there within a few seconds), and the pad's edits come
back to the same file.
Isometric preview (Preview tab): the generated route drawn in 3D over the stock — rapids dashed, cuts coloured by depth — with orbit / zoom, and an animated tool marker with play / pause / speed and a position slider. The machine's live work position is drawn on it while connected.
phobicccp file.c2d # open the GUI on a file
phobicccp --export file.c2d out.nc # headless g-code exportThe self-check, screenshot and machine bring-up modes are for testing, so
they are only in phobicccp-dev, which the build makes next to the program
and never installs or ships:
phobicccp-dev --selftest in.c2d out.c2d # 10-stage create/save/export self-check
phobicccp-dev --shot file.c2d out.png [preview] # render the GUI to a PNG
phobicccp-dev --grbl-check /dev/ttyACM0 # safe GRBL handshake (no motion)
phobicccp-dev --grbl-probe /dev/ttyACM0 -20 -20 [safeZ] # BitSetter measurement (machine XY)
phobicccp-dev --grbl-run /dev/ttyACM0 job.nc [bsX bsY] # stream with automatic tool changes
phobicccp-dev --grbl-rehearse /dev/ttyACM0 -20 -20 [safeZ] # reference + one tool change, spindle off
python3 tools/grblsim.py # GRBL 1.1h simulator on a pty for testingThe .c2d container is SQLite: params (key/value), items (zlib-compressed
J1 JSON payloads for layers, elements, toolpaths, models), sqlar (previews,
encrypted g-code — regenerated by CC, safely blanked on save). Carbide Create
is itself a Qt6 QtWidgets app, which is why the format is full of Qt idioms
(QFont descriptors, row-major QTransform arrays). Full documentation,
specimens and tools live in the
shapeoko-c2d repo.
Safety: this is an independent implementation — offsets, depths and orderings
are close to CC's but not identical. Preview the .nc (e.g. ncviewer.com)
and use the Machine dock's air-cut mode before trusting a new program.
Copyright (c) 2026 Phobic (phobicdotno).
phobiCCCP is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0 (CC BY-NC-SA 4.0); the full text is in LICENSE. In plain words:
- Free for everyone to use, copy, change and share, as long as you credit phobiCCCP.
- Noncommercial: no commercial use. For a commercial license, contact the copyright holder (Phobic).
- Share-alike: anything you build from it must be shared under the same license, so it can never be made proprietary.
Bundled third-party parts keep their own licenses: third_party/clipper2 (Boost Software License 1.0,
see its LICENSE) and the pad app fonts (see Android/fonts/LICENSE.txt). Qt is used under the LGPL.





