Closed feature request

No way to place several library parts on ONE schematic and ONE board: test_board makes a new PcbDoc per call, no schematic placement verb, and altium_eval errors are unreadable modals that kill the endpoint

John Lauer · 1mo ago ·closed by Colby Knox

Ask: place library parts on a schematic and a board without DelphiScript guesswork

Building the ToF sensor library on ConfRoomROG (Altium Designer Develop build, altium-bridge 0.2.9, 2026-09-19) the library half went smoothly: altium_install_library for the adom-lbr SchLib/PcbLib pair, altium_build_footprint from a kicad2altium spec, altium_add_body with the STEP, altium_set_params to link footprints, and altium_show_symbol / altium_show_footprint / altium_show_3d_chip proofs all worked first time.

The second half, "put these three parts on one schematic and one board and show me", has no verb:

  • altium_test_board places exactly one footprint and creates a NEW PcbDoc every call (PCB1, PCB2, ...), so three parts never land on one board. It also returns pcb: "", so the caller cannot even open the board it made.
  • There is no schematic counterpart at all (nothing creates a SchDoc or places a symbol from a SchLib).
  • altium_import_kicad is documented as failing with extension_timeout on AD 26 (tried here as well, see below).
  • altium_eval is the escape hatch, but every runtime error is an unreadable X2 modal (text is painted, dialogs[].body is empty) that halts the engine and drops the bridge HTTP endpoint, and altium_agent_recover needed a Cancel + recover cycle two or three times before the engine came back. Two scripts of mine died this way before their first TStringList.SaveToFile, so nothing could be learned from them. Scripts attached.

Update while filing: adom/altium-bridge#3 says PCBServer.PreProcess / PostProcess are undeclared identifiers on the ADDevelop build, which is exactly what both attached scripts call, so the crash is explained. That makes proposal 3 (readable errors) the important one: the same information in the modal would have cost one retry instead of an afternoon.

Proposals

  1. altium_place_components {boardPath|new, libraryPath, parts:[{footprint, designator, xMm, yMm, rotation}]} and altium_place_symbols {schPath|new, libraryPath, parts:[{libRef, designator, xMil, yMil}]} built on the bridge's own working placement code (the one altium_test_board uses), returning the document paths.
  2. altium_test_board: accept boardPath to add to an existing board, accept footprints: [], and always return the PcbDoc path.
  3. altium_eval: run the statements inside a try/except that writes the exception message to a file the bridge reads back, so a failing script returns {ok:false, error:"<message>", line:n} instead of a modal and a dead endpoint. Also OCR or UIA-read the X2 error modal text into dialogs[].body.
  4. Document which PCBServer / SchServer calls the resident agent supports (LoadCompFromLibrary, TStringList, MMsToCoord ...), or ship a placement.pas helper the AI can call by name.

Repro

Library: adom/vl53l5cx altium/Adom_ToF.SchLib + .PcbLib (three parts). Scripts attached (place.pas, place2.pas). Expected: three components on one board and three symbols on one sheet, with altium_show_schematic / altium_show_3d_board proofs.

place-v1.txt

place-v2.txt

3 Replies

Colby Knox · 1mo ago

Status, proposal by proposal. Most of this issue shipped across 0.2.13-0.2.39; the one missing piece is built and HELD.

  1. Several parts on one document: shipped in 0.2.13 (footprintName/symbolName take a ';' list; everything lands on ONE new board/sheet, saved to pcbPath/schPath), refined through 0.2.14-0.2.18 (sheet sized from the measured parts, title block, designators/comments placed sanely, silkscreen part names on the board).
  2. test_board returns the document path and takes pcbPath: shipped 0.2.13/0.2.14.
  3. Readable eval errors: shipped in depth. 0.2.21/0.2.22 photograph the error box (the text is painted, so the PICTURE is the copy - errorShot on the reply, plus altium_dialog_log {shots:true}), answer it, auto-run the recovery, and return errorCode agent_script_error instead of a dead call. 0.2.26/0.2.27 catch Develop's SILENT parks (no box at all). 0.2.28 fixes the dropped-endpoint half: the bridge served HTTP one request at a time, so one blocked verb took /health and everything else down with it - each request now runs on its own thread. 0.2.23/0.2.24/0.2.39 add altium_selftest_script_error so the net is testable per build.
  4. Documented surface: 0.2.33 documents all 122 verbs (catalog entries enforced by a build test); the engine-halting identifier list is enforced by the release linter (0.2.21), so a template that uses one refuses to build.

The missing piece, APPEND to an existing document, is implemented and shipped to the insiders tier as 0.2.40: test_board {pcbPath} / place_on_sch {schPath} OPEN the document when the path exists and add the parts (placed right of the current ones, designators continuing: U4, U5...; board outline/layers and sheet size/title block untouched), with appended and existingParts on the reply.

HELD, not serving: the live verification run on 2026-09-21 got as far as launch (clean, etiquette fields good) and then hit an expired Develop licence on the test box, so the append path never executed against a real Altium. Colby's call: nothing ships untested. The insiders tier is rolled back to the battery-proven 0.2.39 and 0.2.40 is archived, marked HELD in the tier's release log. This issue stays open until a licensed box runs the proof (create two parts, append a third, both editors).

Colby Knox · 28d ago

Status update: code complete, not closable yet. John ran the licensed test of the held 0.2.41 (see #13). Everything in it passed except altium_panel, which timed out. The fix is staged as 0.2.42 (release asset only; both tiers still serve 0.2.39). We no longer have a licensed Altium, so this issue closes on John's arav-rog battery run of 0.2.42. The exact checks that prove this issue are listed at the end of #13.

Colby Knox · 6d ago

Verified live on a licensed Altium Designer Develop and released in 0.2.45 (insiders). test_board {pcbPath} and place_on_sch {schPath} add parts to an existing board or sheet (right of the current parts, designators continuing); the sheet grows to fit. The run also found and fixed a silent failure: a save into a folder that did not exist wrote nothing, so the next append started a new board. The bridge now creates the folder and checks the file on disk (saved, or errorCode: not_saved).

Log in to reply.