Skip to main content

Serial port debug tool for humans and AI agents

Project description

ttypal

Serial port debug tool designed for both humans and AI agents.

Features

  • Interactive terminal (like minicom, but better)
  • Auto-logging with timestamps and rotation
  • External command injection via Unix socket (for AI/scripts)
  • ZMODEM file transfer over serial
  • Record/replay serial sessions
  • Macro recording and playback (F1-F12 hotkeys)
  • Board config management
  • Claude Code skill for AI-driven serial debugging

Install

pip install ttypal-ai

Platform-specific setup:

  • Linux — 原生支持,需配置串口权限
  • macOS — 原生支持,即插即用(未测试)
  • Windows — 通过 WSL2 + usbipd-win 运行(未测试)

Quick Start

# Interactive mode
ttypal

# Headless daemon (for AI automation)
ttypal-daemon start -b myboard

# Send commands from another process
ttypal-send --wait "# " "uname -a"

# Read recent serial output
ttypal-tail -n 50

Macros

Bind command sequences to F1-F12 keys in your board config:

[macro]
F1 = ["echo hello", "sleep 0.5", "ls -la"]
F2 = ["reboot"]

Or record interactively: Ctrl-T r to start, Ctrl-T s to stop and save.

Claude Code Integration

Clone this repo and open it with Claude Code — the /ttypal skill loads automatically from .claude/skills/.

cd /path/to/ttypal-ai
claude
# Then use /ttypal skill or just ask AI to operate the serial port

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ttypal_ai-0.4.6.tar.gz (36.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ttypal_ai-0.4.6-py3-none-any.whl (30.4 kB view details)

Uploaded Python 3

File details

Details for the file ttypal_ai-0.4.6.tar.gz.

File metadata

  • Download URL: ttypal_ai-0.4.6.tar.gz
  • Upload date:
  • Size: 36.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for ttypal_ai-0.4.6.tar.gz
Algorithm Hash digest
SHA256 357c4b443b5bdd4976ad901bb287e70d30203b4c2c7f3bdc34336714a0da4275
MD5 d847a931cb489589a032e9c6d038e5df
BLAKE2b-256 d7b0d96c9e33995790a6bb7a6f6cbda0c4e451a6e7681b19f2ef2268559919bd

See more details on using hashes here.

File details

Details for the file ttypal_ai-0.4.6-py3-none-any.whl.

File metadata

  • Download URL: ttypal_ai-0.4.6-py3-none-any.whl
  • Upload date:
  • Size: 30.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for ttypal_ai-0.4.6-py3-none-any.whl
Algorithm Hash digest
SHA256 565b01f26f8df66a2932060e2b542c8b8db6a08992bbf1d1c44a69a75e386c51
MD5 7d282245c537bd12a0d18a655d429a69
BLAKE2b-256 488c473356c2fd68c4fef17079341b3ff8ed8ed49060d6741ebd2f9ed0eff368

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page