tuya/tuyaopen-dev-skills/debug-helper
Claude Code and agent skill by tuya/tuyaopen-dev-skills
- community
Checking that the SKILL.md file is still in the repository.
Agent-friendly non-blocking serial log capture for TuyaOpen devices. Runs tos.py monitor in the background, writes logs to file, and lets the agent tail or stop it at any time. Use when the agent needs to capture device logs without blocking, run a debug session, or monitor UART output during a build-flash-analyze loop. 后台串口日志、非阻塞监控、设备日志捕获、agent日志分析。
Install
npx vskill@latest install tuya/tuyaopen-dev-skills/debug-helperSKILL.md
TuyaOpen Debug Helper
Provides non-blocking serial log capture for agents using tos.py monitor -l. The monitor runs as a background subprocess; the agent reads log output from a file and stops the process when done.
Script location
No extra dependencies — uses Python stdlib only.
Quick usage
Commands
| Command | Purpose | |
|---|---|---|
start -p <port> [-l <logfile>] | Launch tos.py monitor -l in background; auto-names log file if -l omitted | |
tail [-n N] | Read last N lines from log file (default 200) | |
stop | Terminate the monitor process; release serial port | |
status | Check whether monitor is running |
Add --json before the command for machine-readable output.
Log file location
All logs and session state are written to `<project_dir>/.target_logging/`, where <project_dir> is the directory containing app_default.config (the TuyaOpen project root). The script finds this automatically by searching upward from the current working directory.
This location keeps logs with the project they belong to. The TuyaOpen SDK .gitignore contains .target_logging as an unanchored rule — it matches at any depth in the repository, so logs are always gitignored regardless of where the project lives under the SDK.
Session file
Session state (PID + log file path) is stored in <project_dir>/.target_logging/session.json. Only one monitor session runs at a time — starting a new one automatically stops the previous.
Port selection for T5 dual-UART boards
T5 / T5AI boards expose two serial ports (WCH dual-serial, VID 0x1a86 PID 0x55d2):
- Linux typical:
ttyACM0= flash,ttyACM1= monitor/log - Windows typical: lower COM = flash, higher COM = monitor/log
These are common cases, not guarantees. If log output is absent or garbled after start, try the other port.
List available ports:
Typical agent workflow
Log analysis patterns
| Pattern | Meaning | Action | |
|---|---|---|---|
[... ty E] | Error-level log | Analyze message and source location | |
[... ty W] | Warning | Usually non-fatal; investigate if repeated | |
feed watchdog | Heartbeat (~10s) | Normal — device is alive | |
OPRT_ + negative number | SDK operation failed | Look up in references/ERROR_CODES.md in tuyaopen/dev-loop | |
mqtt connected | Cloud connected | Success | |
| No output after start | Wrong port or wrong baud | Swap ports; check baud rate |
Related skills
tuyaopen/dev-loop— full build→flash→monitor→analyze loop (calls this skill)tuyaopen/device-auth— serial port needed before writing auth credentials
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/tuyaopen/debug-helper/SKILL.md
Popularity
- Repository stars
- 16
- Repository forks
- 3
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/tuya/tuyaopen-dev-skills/debug-helper)