Terminal
Zeo includes an integrated terminal for direct interaction with the application. Press Ctrl + ` (backtick) to toggle the terminal panel.
Zeo Shell
Python REPL with direct access to the Zeo API through the kipy module.
Getting Started
Enter shell mode by typing python or ipc:
>>> python
Python 3.11 (Zeo embedded interpreter)
>>>
Pre-defined Variables
The shell has these variables pre-imported:
| Variable | Description |
|---|---|
kicad | KiCad connection |
sch | Current schematic (if open) |
board | Current board (if open) |
project | Current project |
Quick Examples
Count components:
>>> symbols = sch.symbols.get_all()
>>> print(f"Schematic has {len(symbols)} symbols")
Schematic has 42 symbols
Find a component:
>>> r1 = sch.symbols.find_by_reference("R1")
>>> fields = sch.symbols.get_fields(r1)
>>> print(fields)
{'Reference': 'R1', 'Value': '10k', 'Footprint': 'Resistor_SMD:R_0603'}
Run DRC:
>>> errors, warnings, _ = board.drc.run()
>>> print(f"DRC: {len(errors)} errors, {len(warnings)} warnings")
DRC: 0 errors, 3 warnings
Export Gerbers:
>>> board.export.gerbers("/path/to/output/")
Gerbers exported successfully
Multi-line Input
For multi-line code, end a line with : or \:
>>> for r in sch.symbols.get_all():
... if r.reference.startswith("R"):
... print(r.reference, r.value)
R1 10k
R2 4.7k
Running Scripts
Load and execute Python files:
>>> exec(open("/path/to/script.py").read())
Or use the run command:
>>> run /path/to/script.py
History
Use Up/Down arrows to navigate command history. History persists across sessions.
Zeo Monitor
Real-time event monitoring for debugging and understanding design operations.
Event Log Location
Events are logged to: ~/Library/Logs/Zeo/agent-monitor.jsonl
Event Types
Schematic Events:
[SCH] Symbol added: R1 (Device:R) at (50, 50)mm
[SCH] Wire created: (50, 52) to (75, 52)
[SCH] ERC completed: 0 errors, 0 warnings
PCB Events:
[PCB] Footprint placed: U1 (Package_QFP:LQFP-48) at (100, 100)mm
[PCB] Track routed: Net "VCC" on F.Cu, length 25.4mm
[PCB] DRC completed: 0 errors, 2 warnings
Agent Events:
[AGENT] Request: "Add decoupling capacitors near U1"
[AGENT] Action: Placing C1 at (95, 95)mm
[AGENT] Completed: Added 2 capacitors
Use Cases
- Debugging scripts — See what operations were performed
- Learning the API — Watch events while using the GUI to understand how operations work
- Audit trail — Complete record of design session for documentation
Viewing the Log
tail -f ~/Library/Logs/Zeo/agent-monitor.jsonl
Quick Reference
| Command | Description |
|---|---|
Ctrl + ` | Toggle terminal panel |
python | Enter Python REPL |
ipc | Enter IPC Python Shell |
exit | Return to system shell |
clear | Clear terminal output |
| Up/Down arrows | Navigate command history |
| Tab | Auto-complete (in Python mode) |
Ctrl+C | Cancel running command |