Owner's request (2026-10-30): the 3D bench and world are far behind
Proteus, KiCad and Microchip's tools. Find what they have, plan how to get
there, then build it. This plan follows ADR-027 (the bench is a second
editor of the same nets), ADR-028 (frame budgets), ADR-029 (licences) and
the visual benchmark (docs/research/visual-workbench-benchmark.md).
| Tool | What its 3D view does | Sources |
|---|---|---|
| KiCad 3D viewer | The board's real stack-up: copper, solder mask, silkscreen, paste, board thickness, plated holes. Each footprint carries a STEP/VRML model with an offset, rotation and scale. Standard views (top, bottom, front, back, left, right) with an orthographic toggle. Layer visibility (each layer, through-hole, SMD, virtual parts, models outside the courtyard). Material modes (realistic, solid, CAD). A ray tracer for renders. Export to STEP, VRML and GLB, and render to an image. | 3D viewer, development highlight, 3D model library and its licence |
| Proteus 3D visualizer | Board thickness, component models, silkscreen, mask, tracks and vias. A bare-board mode. A height plane (a semi-transparent box at a given height) to find parts too tall for the enclosure. STEP/IGES per footprint, fetched from its library. STEP assembly export. | 3D viewer, 3D visualization, STEP |
| Altium Designer | A section view (cutting planes dragged through the board and parts). 3D measurement (object to object, face to face, object to board). 3D clearance checking between bodies. Enclosure STEP imported for fit. Rigid-flex folding. | 3D view, 3D measuring |
| Microchip MPLAB / Fritzing / Tinkercad / Wokwi | Board pictures with live LEDs and displays, breadboard wiring with real connector positions. They run firmware, but none is a 3D engineering view. | the benchmark's table |
What sets these tools apart from our bench today:
- Real geometry. Every package is drawn at its JEDEC/IPC dimensions (or from the manufacturer's STEP), not as a box of its size.
- The board's stack-up. Copper under a translucent mask, ENIG or HASL pads, silkscreen, a FR-4 edge, plated holes. Our boards are a picture on a box.
- Inspection tools. Standard and orthographic views, sections, measurement, height planes, layer visibility.
- Exchange. Models in (STEP/VRML/glTF), assemblies out (STEP/GLB), renders at print resolution.
- Render quality. Ambient occlusion, soft shadows, anti-aliasing and physically based metals and plastics; a ray-traced mode for stills.
EmbSIM has what they do not: the circuit runs. LEDs light from the engine's luminance, displays show the firmware's pixels, buttons press, jumpers are nets, and the world's objects are what sensors see. The plan keeps that and adds the five points above.
- Rendering. Three.js (r186) with ACES tone mapping, a RoomEnvironment for reflections, one shadowed sun, PCF shadows and MSAA.
- Geometry. Procedural bodies (
parts3d.ts): resistor bands from the value, LED domes, TO-92, TO-220, DIP, SMD, buttons, pots, modules. - Boards. A box with the 2D artwork as its texture, and headers.
- Camera. Perspective only, with "frame", "top" and "perspective".
- Tools. No measurement, section, height check, layer visibility or export beyond a screenshot.
Every stage must be usable when it lands (owner, 2026-10-17). Each stage is one PR, with its tests and gallery shots.
- Views. Top, bottom, front, back, left, right and isometric, each framed on the bench or the selection. Perspective and orthographic projections, with the same controls. Keys as KiCad's: Z top, Shift+Z bottom, Y front, Shift+Y back, X left, Shift+X right, I isometric, O projection.
- Measure. A tool: two clicks on any surface (snapped to a pin or hole within 1.5 mm) give the distance in mm with its Δx, Δy and Δz, drawn in the scene until cleared. Altium's object-to-object measurement in its simplest form.
- Section. A cutting plane across X, Y or Z at a chosen position, either side kept (Altium's section view). The bench's objects and their shadows are clipped; the desk stays whole. The cut faces are capped (done 2026-10-31: a stencil count per closed body and a cap on the plane).
- Height plane. A semi-transparent plane at a height above the desk. Parts whose bodies rise through it are outlined and listed (Proteus's height check, for an enclosure's lid).
- Layers. Show or hide boards, parts, breadboards, jumpers, the world's bodies and labels (KiCad's render options).
- Render quality. Draft (as today) or quality, a choice per user,
presentation only:
- quality adds ambient occlusion (GTAO), bloom on what emits light (a second render of only the emissive surfaces feeds it, so a bright desk does not bloom), 4× multisampling and a 4096² shadow map;
- quality falls back to draft when frames miss the budget (ADR-028).
- Export.
- A still at 2× or 4× the view's resolution (for documentation).
- The scene as GLB (glTF binary) for Blender or an MCAD tool, in millimetres, with each part a named node.
- STEP export needs a B-rep kernel (OpenCascade: LGPL, a referee only under ADR-029) and is left for later.
Exit:
- each view, measurement, section, height check and export works from the toolbar and the keyboard;
- the pure functions (view placement, measurement, height check, section) have unit tests;
- a Playwright spec measures between two known holes (2.54 mm × n);
- gallery shots before and after.
- A package generator in TypeScript, as KiCad's (packages3D-generator) is
in Python, from the standards' dimension tables:
- SOIC/SOP/TSSOP/MSOP (MS-012, MO-153), QFP/LQFP/TQFP (MS-026), QFN/DFN (MO-220), SOT-23/SOT-223/SOT-89;
- TO-92/TO-220/TO-252, chip passives 0402 to 2512, MELF;
- electrolytic and ceramic disc capacitors, HC-49 crystals, pin and socket headers, JST and Dupont housings;
- USB-B, USB-C and micro-B, DC barrel jacks, tactile switches and trimmers.
- Each with its pin 1 mark, mould draft, lead bends (gull-wing, J-lead), exposed pad and marking text from the part's name.
- A catalog part names its package and variant (
package: "SOIC-8"); the bench draws that and its legs land at the pads' positions. - Unit tests:
- each body's extents against the standard's;
- each lead's tip against its pad;
- the pin order against the part's pin table.
Done (2026-10-31): gull-wing leads on QFPs; SOIC (MS-012), VSSOP (MO-187) and TSSOP (MO-153) bodies, drawn on an SO-to-DIP breakout when the part stands on a breadboard; quad packages marked with their part number; board features at any angle (the NUCLEO-64's 45° MCUs).
component.jsonmay name a glTF model (model3d: {file, offset, rotation, scale}) beside the catalog part. Each model's licence and source are recorded in the part's provenance (ADR-029).- A converter tool turns a KiCad VRML model into glTF with its materials, offline. KiCad's packages3D is CC-BY-SA 4.0 with an exception for designs, so converted models are separate assets with their attribution, never merged into code.
- A loader caches models and instances repeated parts, so one model serves a hundred LEDs.
Done (first step):
bench.model3dincomponent.jsonnames a VRML file beside the part, with its scale, offset, rotation, source and licence (the schema requires the last two). KiCad's VRML is loaded directly (three.js's VRMLLoader, MIT), so no conversion step is needed yet; glTF stays the plan for models from other sources.catalog.getreturns the file's text asfiles.model3d; the bench stands the model up (KiCad is Z-up in 2.54 mm units, origin at pad 1), puts its origin on the part's first pin, and draws it instead of the built body. A control (a trimmer's adjuster) keeps its gesture. Phong materials become physical ones: a grey with a bright, tight specular is metal.- Each file is parsed once; every part using it shares its geometry and materials.
- The Bourns 3296W trimmers (10 kΩ and 100 kΩ) and the 12 × 9.5 mm buzzer use KiCad's models, copied with KiCad's licence beside them.
models3d.test.ts: each model's legs stand in its pins' holes (a turn of 180° fails it), a file that does not parse keeps the built body, and the material conversion.
- From the board's artwork:
- FR-4 core with its edge colour and thickness;
- copper (traces from the artwork's copper layer);
- solder mask as a physical clearcoat over the copper, the copper showing through;
- ENIG or HASL pads and plated through-holes with barrels;
- silkscreen in its ink;
- real holes cut through the board (mounting holes, header holes).
- The Uno, NUCLEO, Pico and ESP32-C3 boards drawn from their published layouts where the licence allows (the Uno's is CC-BY-SA, Arduino's reference design).
- An outline on the selection and on hover (the outline pass): done, drawn after tone mapping in draft and in quality.
- Cross-probing: select in the schematic and the 3D view frames it, and the reverse.
- An exploded view (each part lifted off its host): done, up to 25 mm.
- A view cube in a corner: done (a CSS cube turned by the camera's rotation; its faces frame the standard views).
- Jumpers that sag as wire does: done for spans of 70 mm or more, which drape onto the desk or the parts under them; short ones still arc.
- A room around the bench: floor, walls, table, window light, a sun by the time of day.
- Bodies with physics (Rapier, Apache-2.0, ADR-029), and a robot on the floor. First step done (2026-10-31): bodies move in virtual time in the engine (a velocity, a travel back and forth), seen by the distance sensors and drawn by the bench; then paths of waypoints walked at a speed, looped or there and back (a person round the table); then gravity: a body let go falls, bounces off the table or the floor and rests, solved in closed form in the engine. Collisions between bodies are next (Rapier when they come).
- Temperature and light as fields drawn when asked (a heat map over the bench).
- The world's objects are what the sensors' rays hit, as today.
Done (first step, 2026-10-31): the bench's surface is the top of a 750 mm
lab table with a 1400 x 700 mm mat, in a 5.2 x 4.4 x 2.7 m room with a
window on the left; walls face inwards so none hides the bench; the light
follows the world's illuminance (room.ts, room.test.ts). Then the room's
size and window direction (world.room) and the sun by latitude, date and
solar time (world.sun, sun.ts): the key light is the sun when its beam
reaches the table through the window, window daylight when not, the lamp at
night. Then the window's patch: walls, ceiling and bars cast shadows from a
sun whose shadow camera starts outside the room. Then floor shadows: the
shadow map is framed on what the camera shows (shadowfit.ts), tight on
the bench close in and the whole room standing back, the shell shading
only the sun. Still to do: physics.
- Instancing for breadboard holes and repeated parts, level of detail by distance, frames drawn on demand as today.
- A Playwright harness measures frame times on the reference scenes and enforces ADR-028's budgets (8.3 ms at 120 Hz, a 16.7 ms floor).
- The visual benchmark's V1 to V4 qualifications.
Done (first step, 2026-10-31): each frame's render is a User Timing
measure (frames.ts); e2e/frame-budget.spec.ts orbits the demo bench in
draft and quality and reports p50/p95/p99 and the share of frames over
8.3 and 16.7 ms, enforcing the 95th percentile with
EMBSIM_FRAME_BUDGET=enforce (CI renders on the CPU, so it reports only).
The time is the CPU's; GPU timer queries
(EXT_disjoint_timer_query_webgl2) add the GPU's where the browser has them
(GpuTimer, done 2026-10-31).
Done (2026-10-31): static batching per part (batch.ts): the meshes in the
shared static materials merged, one per material (the NUCLEO: 581 to 22
meshes). Still to do: instancing across parts, level of detail.
- A full ray tracer in the browser. Quality mode's ambient occlusion and soft shadows cover the bench, and GLB export hands stills to Blender's Cycles.
- STEP export, until a permissively licensed B-rep path exists.