Draw circuits by talking to your agent.
FidoCadAI gives you and your AI agent a shared drawing canvas. Ask for a circuit, inspect the result, then answer on the canvas itself: select a component, move a label or adjust a wire. Your selections and edits are shared automatically, so the next request can refer to what you just touched.
The conversation stays in your terminal. The drawing stays open beside it, and you can edit it by hand at any point.
I've used FidoCadJ since high school, through university and in the years since. It has been a blank page for thinking: somewhere to sketch circuits, systems and ideas of all kinds. FidoCadAI brings an agent into that way of working.
You can use it to draw schematics and design simple PCB layouts, or as a companion for exploring an idea. The drawing gives the conversation something concrete to work with: a way to explore an arrangement, question it and develop it further.
Drawing a buck converter with Pi:
I come from chip design, so I wanted the interface to feel a bit like Cadence Virtuoso, with controls such as pressing Space to fit the drawing in view. The interface also borrows ideas from Omarchy Linux and macOS for keyboard and trackpad interaction. FidoCadJ has been a major influence too, particularly its rulers and keybindings for drawing primitives.
The interface is deliberately simple. The drawing fills the window, with tools available from the keyboard when you need them. You can move between conversation and direct editing without leaving the drawing or interrupting the session. The aim is to keep your attention on the idea you are working through.
FidoCadAI ships with a skill: written instructions that teach an agent how to use the tools. It carries some of my own preferences in schematic drawing as a starting point. Memory and style learning are enabled by default: the agent learns from your feedback, remembers your preferences across sessions and applies them to later drawings. Over time, the drawings reflect more of your own style.
A FidoCad drawing is plain, human-readable text. Its simple commands make it possible for a language model to infer how to draw from examples, even before reading the specification. The essentials of the drawing language fit on a single page, so explaining it takes little of the agent's context and leaves room for the design itself. You can also read the files yourself, track changes in Git and share drawings that remain editable.
I chose C over Rust because of its long history and the large body of established code available for language models to learn from. I wanted the implementation to be straightforward for agents to read and extend, as well as fast to run. The core and command-line tool are lean C11 programs with no external dependencies beyond the C standard library. The drawing window uses Qt6.
The agent works through the command-line tool, fcai, while you see the result in fcai-gui. It shows the first symbols or wires as soon as they are available, then builds, checks and refines the circuit in the open window. You can follow and steer the drawing while it is still in progress.
The language model interprets your requests and makes the design decisions, so results depend on the model you use. The tools let it inspect the drawing's syntax, wire geometry and appearance; those checks do not establish that a circuit will work electrically.
These examples range from circuit details to a house energy system and a portrait. Each uses the same text-based drawing format. Editable sources live in playground/; click an image to open the full-resolution render.
The buck-boost pair shows a schematic and a PCB layout. The ADC drawings use repeated circuit elements and labels to describe more detailed structures.
| Buck-Boost Schematic | Buck-Boost PCB Layout |
|---|---|
![]() |
![]() |
| Power-stage topology and component labels. FidoCad source | Copper tracks, pads, and silkscreen. FidoCad source |
| VCO-Based Sigma-Delta ADC | Capacitive SAR ADC |
|---|---|
![]() |
![]() |
| Modulator and current-starved ring oscillator. FidoCad source | Binary-weighted capacitor array and SAR register. FidoCad source |
Solar + Storage House — Single-Line Drawing
This drawing brings electrical and thermal systems onto one canvas: rooftop solar, battery storage, a hybrid inverter, house circuits and heat-pump heating. Colours and line styles distinguish power, control signals and heat flow.
Editable drawing and symbol library · Blue: AC power · Gold: PV DC · Green: battery / PE · Violet dashes: logical controls · Orange: thermal flow
Enrico Fermi Portrait
The same lines used for circuits can also describe a face. This portrait is made of editable outlines and cross-hatching, with no embedded photograph.
Editable artwork and reference photograph
FidoCadAI runs on Linux and macOS with a coding agent such as Pi, Codex or Claude Code. Give your agent this repository and ask it to install FidoCadAI, read the included skill and open a drawing. Building requires a C11 compiler, Make and Qt6 for the drawing window; the installer and agent instructions cover setup and use.
The desktop canvas uses Qt's OpenGL paint engine for vector geometry, grid,
overlays, and image textures. Labels (including TeX) are prepared as transparent
textures using the core's font metrics. Panning and zooming transform the retained
scene without rasterizing the whole viewport. Building the GUI requires the Qt6
OpenGL Widgets module as well as Widgets (on Debian/Ubuntu, libqt6opengl6-dev
in addition to qt6-base-dev). Headless runs use the CPU renderer; set
FCAI_RENDERER=software to select it explicitly on a desktop. PNG/PPM exports
continue to use the core renderer.
A first request can be as simple as “Draw an inverting buck-boost converter.” Once the drawing is open, select something you want to change and continue the conversation.
Run make test for the core, CLI, session, and GUI suites. With Qt6 Widgets, OpenGL Widgets and
Qt6 Test installed, make test-gui runs the GUI suites alone, offscreen.
make test-gpu requires a desktop display and checks the actual OpenGL canvas,
including framebuffer pixels, pan/zoom, edit invalidation, and inline editing.
It prints the GL renderer reported by the driver; a software GL driver such as
llvmpipe does not provide hardware acceleration.
The UI end-to-end suite sends mouse and keyboard events through the application window, letting Qt route them to the canvas, symbol picker, properties fields, and shortcut sheet. It checks every drawing tool and documented shortcut, placement with snapping on/off and pan/zoom, handle dragging for every primitive type, component rotation/mirroring, selection, clipboard edits, undo/redo, rulers, and saved files. It runs at normal and double display scaling. Explicit double-click and release events also cover dropped final points and drags without a final move event. These tests exercise Qt input dispatch; they do not automate a desktop compositor or physical input device.
- Core & GUI: Licensed under GPLv3.
- Reference Projects: FidoCadJ (Java) by Davide Bucci and FidoCadJS (TypeScript).
- Rasterizer & Fonts: Vendors stb (
stb_truetype,stb_image_write), mimeTeX (GPLv3+) for native LaTeX math, and Liberation Fonts (SIL Open Font License 1.1).
Import PNG/JPEG pictures with Shift+I and enter a file path, drop image files
onto the canvas, or paste an image with Ctrl+V. Pictures are embedded in the
.fcd file, so the original image file is no longer needed. Select a picture to
move it, resize it with its corner handles, rotate or mirror it, or press P
to edit its dimensions, rotation, opacity and layer. Undo/redo and copy/paste
include pictures.
The CLI can embed pictures too (omitting one dimension preserves aspect ratio; omitting both gives a width of 100 drawing units):
fcai image sketch.fcd --from photo.png --at 20 30 --width 100 -o illustrated.fcd
fcai render illustrated.fcd -o illustrated.pngPNG transparency and layer opacity are respected in the editor and rendered
output. Imports allow up to 24 MiB encoded, 16 megapixels decoded, and 8192 pixels
per side. Pictures use the FJC IMAGE extension; older readers may ignore them,
and --no-extensions output omits them.
Agents can focus the live canvas on a rectangle in drawing coordinates:
fcai session fit-rect /tmp/sketch.session 20 10 80 60 --waitThis centres and fits the region with a 10-unit margin, preserving the drawing
and selection. Use ordered corners (X1 > X0, Y1 > Y0); fractional and
negative coordinates are supported. Space/0 restores fitting the whole drawing.







