← Case studies

A Sensor Probe Board — Closing the Loop

From a mechanical drawing to a placed fab order, with the engineer at two gates

The finished board, ray-traced from the KiCad project

The Challenge

A client's handheld sensor needed a small interposer board: three spring probe pins on a 5 mm pitch, carried to a three-conductor cable, inside a printed housing with almost no free volume. The inputs were a mechanical engineer's drawing and STEP model of the housing, a bill of materials naming a pin and a socket, and a paragraph of intent from the hardware engineer (the operator). There was no schematic, no footprint for the socket, and no layout.

The board is simple on purpose. What makes it a useful test is everything around it: the inputs had to be reconciled, the socket had to be given a footprint and a place the housing leaves room for, the fabricator's file set had to be right, and the order had to be placed without a person re-typing options into a web form.

The mechanical engineer's drawing: outline, pin positions, keep-away zones and notes

The Platform

Hapimatic runs each AI session as a persistent, observable process with its own working tree, tools and memory, and lets one session start and supervise others. The tools here were KiCad 9 driven headless (kicad-cli and its Python API), FreeCAD for STEP geometry, distributor APIs for part data, a command-line client for the fabricator's API, and Google Drive and Gmail for the hand-off. Skills, hooks and a written PCB doctrine supply the house rules; every result is committed to the client's repository.

The Working Method

A chat assistant produces a design description. This session produced files, checked them with the same tools an engineer would, and stopped at two gates for the operator's decision.

  • Read — the drawing, the DXF outline, the housing STEP and the bill of materials, directly from the project's Drive folder.
  • Model — slice the housing STEP to find what space the board really has.
  • Design — generate the KiCad schematic, footprints and layout from the drawing's dimensions with a script, so every change is a re-run.
  • Check — ERC, DRC, the doctrine lint, and an interference check of the board's STEP against the housing.
  • Gate 1: design review — the operator reviews rendered images and marks up what he wants changed.
  • Package — build the fabrication files and refuse to package unless their size and drill table are right.
  • Fab-side check — upload to the fabricator, read back its own file analysis and preview.
  • Gate 2: order approval — the operator approves exact options, shipping and address.
  • Order — a dry run, a line-by-line comparison with what was approved, then one confirmed request.
  • Hand off and record — exports for the mechanical model, a design record, and tracked follow-ups.

How to Read This Report

Every factual claim below carries a reference [L#] that resolves to a row in the References appendix at the end. Each row is tagged with a confidence tier:

  • ✅ verified — a tool call, commit, file or message directly shows it.
  • 🟡 inferred — a reasonable interpretation connecting verified facts, labelled as such.
  • ❓ asserted-unverified — claimed but not evidenced. This report contains none.

The client and project are anonymised. The board's model number is a placeholder in every render and drawing, and the client's prefix of it is removed from every photo.

What the AI Actually Did

Problem 1 — The board's real envelope was not on the drawing

Problem The drawing gave an outline and "keep away zones", but the housing's nut bosses, screw heads and a slot under the board decide where copper, holes and labels can go.
Capability Mechanical-envelope extraction from CAD (T4 engineering output).
How it works The session sliced the housing STEP at heights above and below the board with FreeCAD and plotted the free space at each height.
How it addressed the problem An envelope map of the cable side was committed before any layout existed, and the same outlines later went onto the board's assembly layers. [L1]

Problem 2 — The specified pin could not reach the socket's contact

Problem The bill of materials named a spring pin and a socket. Read against the maker's drawings, the pin's tail is 1.75 mm long and the socket's contact sits about 2.1 mm deep.
Capability Part research against primary sources (T3 rigor).
How it works The session pulled 969 receptacle listings and 256 spring-pin listings from the maker's range through a distributor API and filtered them by tail and contact geometry.
How it addressed the problem It reported the mismatch, proposed two pins from the same body family with longer tails, and built a ready-to-order cart of the pin and receptacle options. [L2]

Problem 3 — A hole size quoted from one field of a product page

Problem The session first quoted a 1.12 mm mounting hole for the socket, and the operator approved it. He then asked for a screenshot as proof.
Capability Self-correction under an operator's challenge (T3 rigor).
How it works Opening the maker's product page and application note directly showed two mounting options with opposite orientations; the quoted figure belonged to the one where the lead enters from the top.
How it addressed the problem The session reported its own error, saved captures of both sources, and the design changed: the sockets moved to the pin side of the board, in a 1.35 mm non-plated hole. The rule "read every mounting option before quoting a footprint" was saved to memory and filed for the PCB doctrine. [L3]

Problem 4 — Turning dimensions into a checked KiCad project

Problem No schematic, symbol, footprint or layout existed.
Capability Autonomous design generation with tool-verified results (T2 autonomy, T4 output).
How it works A Python script holds the drawing's dimensions as constants and writes the schematic, the project library and the board through KiCad's API. The session then runs KiCad's own checks.
How it addressed the problem The first layout was committed for review after 38 minutes of model time. The released board passes ERC, DRC and the doctrine lint with zero findings, and an interference check against the housing STEP runs from a script. [L4] [L5]

Problem 5 — The operator's review

Problem Two review rounds found things no rule check had: the wrong identification text, mechanical outlines on the wrong layers, labels hidden under hardware, silkscreen too close to the edge, and review images where a hole looked like blank page.
Capability Turning review feedback into enforced rules (T3 rigor).
How it works Each correction became a constant in the generator, and where possible a check: silkscreen clearance rules in KiCad's rule file, text measured on its drawn outline, and review images with the board body filled so holes read as holes.
How it addressed the problem Three commits reworked the silkscreen and labels; the board still passes every check; and the operator approved the layout. His conventions were saved to memory and filed as doctrine issues so the next board starts with them. [L6] [L7]
The operator's marked-up review image (model number obscured)

The pin side of the board at three points in the repository history, and the released cable side:

Problem 6 — A fabrication package that would have been built as a sheet of paper

Problem The shared fabrication job set reported "7 jobs succeeded", but every Gerber layer, including the outline, carried the drawing sheet's border: 259 x 196 mm for a 14.7 x 15.2 mm board.
Capability Independent verification of generated output (T3 rigor).
How it works The session noticed that two empty layers were as large as the copper layers, traced it to a missing setting, and wrote a packaging script that compares the outline's true extents with the board size KiCad records separately.
How it addressed the problem The package is built from a project job set, the script refuses the defective one, and the defect was filed against the shared tooling. The session also corrected its own first check, which had passed the bad files because it used the outline as its own reference. [L8]

Problem 7 — No way to place the order without a browser

Problem The fabricator's command-line client could quote but could not upload files or create an order.
Capability Orchestration of a second session to build the missing tool, then use of it (T2 autonomy).
How it works The design session filed the gap, started a peer session to build it, and acted as its project manager: it ruled on review findings and verified each approval gate against the repository before releasing it. The tool places an order only after a dry run and a matching fingerprint.
How it addressed the problem The tool merged with 170 tests. The fabricator's own file check returned two layers, 14.66 x 15.22 mm, nine files recognised, no errors. After the operator approved the options, shipping and address, the session ran the dry run, compared it with his conditions on 18 points, and sent one confirmed request. The order for 20 boards existed seven seconds later. Payment was left to the operator. [L9] [L10] [L11]

Problem 8 — The mechanical engineer needed the board in his model

Problem The lead mechanical engineer asked for a DXF in millimetres and a transparent image of the silkscreen. KiCad's own DXF export put about 10,000 loose line segments on one layer.
Capability Purpose-built export tooling and a labelled hand-off (T4 output).
How it works A script writes named layers in his drawing's frame: the outline as true arcs, holes as circles, pads and silkscreen as closed polylines. A second script renders transparent images cropped to exactly the board's bounding box.
How it addressed the problem The exported outline matched his own DXF to three decimal places. The files went to the project's Drive folder and an email, sent from the operator's account and labelled as written by his AI assistant, linked each one. [L12] [L13]

Worked Examples

"Do the listed pin and socket actually go together?"

Observation The parts list named a pin and a socket that looked compatible by description.
Measurement Maker's drawings: pin tail 1.75 mm, socket contact about 2.1 mm deep. Maker's application note: two mounting options, 1.12 mm and 1.52 mm holes, with opposite entry directions.
Diagnosis The pin was too short for the socket, and the first hole size belonged to the wrong orientation. A single catalogue field had been read as if it were a footprint.
Verification Both findings were reported to the operator with the dimensions from the maker's drawings. The board was redrawn with the socket on the pin side, an interference check was run against the housing model, and the pin and receptacle options went into a ready-to-order cart.
References [L2] [L3] [L5]; see Problems 2 and 3 above.

"Is this file set really what the fabricator will build?"

Observation The export tool said every job succeeded.
Measurement Layer extents: 259 x 196 mm for a 14.7 x 15.2 mm board. After the fix, the fabricator's own analysis: 14.66 x 15.22 mm, two layers, nine files, no errors, and its preview of both sides.
Diagnosis A missing export setting added the drawing border to every layer. A viewer alone would not have settled it: one rendering tool drew a correct arc as a straight line.
Verification A packaging script that fails on the defect, a test that proves it fails, and the fabricator's file check before the order.
References [L8] [L10]; see Problems 6 and 7 above.

"Can I drop the board into my CAD model?"

Observation The lead mechanical engineer needed pad and hole positions he could trust, and artwork he could place as decals.
Measurement DXF outline extents equal to his own drawing's to three decimals; images 14.667 x 15.217 mm at 2400 x 2490 pixels.
Diagnosis A layered DXF in his frame and to-scale images remove the manual alignment step.
Verification His reply, three hours after the email: "Thanks! The DXF let me match your pad sizes and hole locations exactly, and the PNGs were added as 'decals' on each side of the board." He also noted that the 3D renders were not to a fixed scale, which is now a requested change to the export tool.
References [L12] [L13] [L14]; see Problem 8 above.
The lead mechanical engineer's screenshot: the board and its decals in the housing model

After the Order: The Boards on the Bench

All twenty boards arrived, as single boards rather than a panel. On 2026-11-24 the operator reported the outline and thickness correct, the finish ENIG on every board, the silkscreen good, and that the holes "accepted the parts just fine". The photos show one he assembled that day: a socket head-up in each of its three 1.35 mm holes, from the pin side, soldered at its head to the ring pad around the hole. That is the footprint that Problem 3's correction produced. [L17] [L20]

In that socket he tried three spring pins by hand: the one the parts list named, and the two longer-tailed pins the session had proposed in Problem 2. He reported the listed pin and the shorter of the two proposals insufficient, and chose the pin with the longest tail. In his words: "It feels nice and sturdy and the pin insertion going past the socket helps the pin stay aligned and makes it easier to insert." Putting the pin into the socket "was easy and smooth", and his first note from the bench was that the two parts "work perfectly". [L20]

By the maker's dimensions, the chosen pin's 5.97 mm tail passes the socket's head and the board and comes out of the cable side by about 3.5 mm; the photo of that side shows the three tails. In the housing model, read with FreeCAD, the free height on that side is 26.2 mm over the two outer pins, up to the strain-relief boot, and nothing lies within 40 mm over the centre pin. The model carries no cable or wires. [L19]

Before he started, the operator asked for a drawing of which part goes into which side of the board. A later session rendered ten 3D views from the board's own KiCad export, with the tails, shoulders and three of the four socket heads at the maker's catalogue size, one socket's head height assumed, and the pin barrels drawn approximately: the two faces told apart by their printing, each socket option mounted, and each pin seated, with cut-away views of how far each tail reaches. [L18]

The pin insertion guide

The ten views are instructions, drawn before the bench for every pin and socket in the parts cart; the published variant marks the pin he later chose. The results above are the operator's, for the three pins in the first socket (SKT-1) only. [L18] [L20]

The Takeaway

On this board the operator's inputs were a kickoff, two rounds of review, a layout approval and an order approval. Between them the session read the source files, found and reported two fit problems, generated and checked the design, built and verified the fabrication package, had the missing ordering tool built and reviewed, placed the order, and gave the mechanical engineer files he could use the same afternoon. Eleven days after the order, a board was on the bench, assembled with the socket the session's footprint was drawn for and one of the two pins it had proposed [L17] [L20]. The session's turn records show about 92 minutes of model time from the kickoff to the approved layout [L4], and about 129 minutes for all of the board work [L15].

The run also changed the pipeline: 17 improvement issues were filed against the shared tooling, 13 during the run and four at its close, each from a problem met on this board [L16]. All but one of the references below are verified from a commit, file, tool output or message; the total-time figure is an inference and is marked as one.

References

Ref Claim Primary source Tier
L1 Envelope map from housing STEP slices, committed before layout A commit in the client repository ✅ verified
L2 Pin tail vs contact depth; survey of 969 receptacles and 256 pins; two candidates; test cart The part survey, the finalists list, and the test cart in the client repository ✅ verified
L3 Hole size corrected after the operator asked for proof; sockets moved to the pin side Saved captures of the maker's product page and application note, a client-repo commit, a session memory note, and a tooling issue ✅ verified
L4 First layout after 38 minutes of model time; 92 minutes to the approved layout The session's turn ledger, the first-layout commit, and the operator's approval message ✅ verified
L5 ERC 0, DRC 0, lint exit 0; interference check script The ERC, DRC, lint, and interference-check reports in the client repository ✅ verified
L6 Review corrections implemented in three commits; silkscreen clearance rules Three client-repo commits and the silkscreen-clearance rule file ✅ verified
L7 Operator's conventions saved and filed as doctrine issues A session memory note and three tooling issues ✅ verified
L8 Drawing sheet on every Gerber layer (259 x 196 mm); packaging check with an independent size reference; first check corrected Two client-repo commits, the packaging script, and a tooling issue ✅ verified
L9 Ordering tool built by a supervised peer session; 170 tests; merged before the order A tooling issue, its merged pull request, and the tester report on it ✅ verified
L10 Fabricator's file check: 2 layers, 14.66 x 15.22 mm, nine files, no errors The fabricator's file-check output and its preview image ✅ verified
L11 Dry run compared on 18 points; one confirmed request; order for 20 boards created in seven seconds; payment left to the operator The session transcript's order tool calls and the committed order record ✅ verified
L12 Layered DXF in the engineer's frame; outline extents equal to his DXF to three decimals; KiCad's native export about 10,000 segments on one layer A client-repo commit and the session's DXF inspection output ✅ verified
L13 Files placed on Drive and emailed, labelled as written by the AI assistant The email sent from the operator's work account ✅ verified
L14 The lead mechanical engineer's reply and screenshot The engineer's reply in the same email thread, quoted with the operator's permission ✅ verified
L15 About 129 minutes of model time on the board work The session's turn ledger, with each turn's time split between board and tooling work (the split is a judgement) 🟡 inferred
L16 17 improvement issues filed from this run The tooling issues filed during the run and at its close ✅ verified
L17 20 boards received as single boards; outline and thickness correct, and the holes took the parts; the photos show one assembled on 2026-11-24, with the pin-side socket and the longest-tailed proposed pin The operator's four photos, published with the client's prefix of the model number removed, and his inspection note ✅ verified
L18 Ten 3D assembly views rendered from the board's KiCad export for the operator's bench test The bench-orientation views and their render script in the client repository, published in a variant with parts named by role ✅ verified
L19 Tail about 3.5 mm out on the cable side, calculated from the maker's dimensions; in the housing model, free height 26.2 mm over the outer pins and nothing within 40 mm over the centre pin The maker's drawings, the board's thickness, and a FreeCAD reading of the housing model ✅ verified
L20 Three pins tried by hand in the pin-side socket; the listed pin and the shorter proposal "insufficient"; the chosen pin "nice and sturdy", its insertion "easy and smooth"; the two parts "work perfectly" The operator's two bench notes, quoted as his report ✅ verified (his report)

← Back to all case studies