How majorwhiskey/pogo-pin works
pogo is an agent-oriented ESP32 hardware workbench: a CLI and MCP server expose terminating, structured operations over one shared core. The main workflow selects a board, performs flash/reset/serial capture or probe work, then returns JSON results and actionable status. Core stages include discovery and configuration, device operations, transport/probe protocol, and result formatting; hardware-test suites and remote MCP access are additional capabilities. Several core operation implementations are unsampled, so those subsystem links reflect the README’s explicit frontend-parity description rather than inspected call sites.
Main entry points: ops Core operations · main.rs CLI dispatch · lib.rs MCP tools · probe.rs Probe protocol
Components 22
User interfaces
- CLI dispatch
crates/pogo-cli/src/main.rs - CLI arguments
crates/pogo-cli/src/cli/args.rs - Output formatting
crates/pogo-cli/src/output.rs - Launcher menu
crates/pogo-cli/src/menu/mod.rs - MCP tools
crates/pogo-mcp/src/lib.rs - MCP conversion
crates/pogo-mcp/src/convert.rs - HTTP MCP
crates/pogo-mcp/src/http.rs
Core operations
- Device discovery
crates/pogo-core/src/discovery.rs - Core operations
crates/pogo-core/src/ops - Hardware test suites
crates/pogo-core/src/ops/suite.rs
ESP target I/O
- Flash and chip info
crates/pogo-core/src/ops/flash.rs - Serial capture
crates/pogo-core/src/serial/session.rs - Target reset
crates/pogo-core/src/ops/reset.rs
Probe capabilities
- Probe operations
crates/pogo-core/src/ops/probe.rs - Probe protocol
crates/pogo-core/src/probe.rs - Wire codec
crates/pogo-protocol/src/codec.rs
Shared foundation
- Configuration
crates/pogo-core/src/config/load.rs - Byte transports
crates/pogo-core/src/transport/mod.rs - Session recording
crates/pogo-core/src/transport/record.rs - Result envelope
crates/pogo-core/src/envelope.rs - Errors and hints
crates/pogo-core/src/error.rs
Other components
- Agent or user
Connections 23
- Agent or user → CLI dispatch: runs commands
- Agent or user → MCP tools: invokes tools
- CLI dispatch → CLI arguments: parses arguments
crates/pogo-cli/src/main.rs - CLI dispatch → Core operations: dispatches operations
- CLI dispatch → Output formatting: formats results
crates/pogo-cli/src/main.rs - CLI dispatch → Launcher menu: opens when requested
crates/pogo-cli/src/main.rs - Launcher menu → CLI dispatch: runs commands
crates/pogo-cli/src/menu/mod.rs - MCP tools → Core operations: calls shared core
crates/pogo-mcp/src/lib.rs - MCP tools → MCP conversion: converts results
crates/pogo-mcp/src/lib.rs - MCP tools → HTTP MCP: serves over HTTP
crates/pogo-mcp/src/lib.rs - Core operations → Device discovery: selects devices
- Core operations → Configuration: uses settings
- Core operations → Flash and chip info: runs flashing
crates/pogo-core/src/ops/mod.rs - Core operations → Serial capture: captures serial
- Core operations → Target reset: resets target
crates/pogo-core/src/ops/mod.rs - Core operations → Hardware test suites: runs suites
crates/pogo-core/src/ops/mod.rs - Core operations → Probe operations: runs probe tasks
crates/pogo-core/src/ops/mod.rs - Probe operations → Probe protocol: uses probe client
crates/pogo-core/src/ops/probe.rs - Probe protocol → Byte transports: uses transport
crates/pogo-core/src/probe.rs - Byte transports → Session recording: wraps for recording
crates/pogo-core/src/transport/mod.rs - Core operations → Result envelope: returns structured data
crates/pogo-core/src/ops/mod.rs - Core operations → Errors and hints: reports failures
crates/pogo-core/src/ops/mod.rs - Probe protocol → Wire codec: exchanges protocol frames