Introduction¶
The DeepSeek Harness (DSH) ecosystem emphasizes a plugin architecture, and developers frequently need to debug embedded devices such as Arduino, STM32, and ESP32. Traditional methods require manually copying serial logs or writing scripts to read them, which is inefficient. The dsh-serial plugin connects the computer’s serial port to the DSH environment, allowing AI to directly read hardware runtime output, achieving dual-channel monitoring via the panel and AI tools.
Plugin Overview¶
- Name: dsh-serial
- Maintainer: Canye-zdm
- Category: Networking Tools
- License: MIT
- Version: v0.1.7
- Core Value: Connects the computer’s serial port to DeepSeek Harness, enabling AI to see runtime output from Arduino/STM32/ESP32/51 microcontrollers (dual-channel: panel + AI tools).
Core Features¶
The plugin provides two channels that work together to serve serial communication:
-
Floating Ball Panel (for humans)
- After installation, a floating ball appears in the bottom-right corner of the interface, which can be dragged to reposition.
- Supports selecting serial port connections and viewing logs in real time.
- Provides “Demo Mode” (test without hardware), manual data sending, log copying, and other features.
-
AI Tool Channel (for AI)
serial_list_ports: Lists all serial ports on the local machine (Bluetooth, virtual ports, etc.).serial_read: Reads serial port data and automatically analyzes it.
-
Shared Instance
- The panel and AI tools share the same serial port service instance. Data opened by the panel is read directly from the instance’s real-time buffer by AI tools, avoiding conflicts.
Installation and Activation¶
The installation process includes two steps: dependency installation and plugin registration.
- Install Dependencies
Run the following command in the plugin source directory:
npm install --registry=https://registry.npmmirror.com
The plugin depends on the `serialport` library.
- Register Plugin
Use the official CLI to install the plugin into the dsh desktop profile:
dsh plugin --profile desktop add link:<absolute path to this directory>
- Restart Application
After executing the above commands, restart the DeepSeek Harness desktop version to take effect.
Usage Examples¶
You can verify and experience the functionality step by step through the following four levels.
Level 1 · Panel Channel (Demo Mode)
After restarting dsh, click the “Serial” floating ball in the bottom-right corner to enter the panel. Click “Demo Mode” to see simulated serial data scrolling, verifying that the panel link is working properly.
Level 2 · AI Tool Channel (List Serial Ports)
In a new dsh session, directly ask the AI: “List the serial ports on my computer.”
Expected: AI calls the serial_list_ports tool and returns a list of local serial ports.
Level 3 · Full Loop (Read Serial Port)
Assuming the board is printing logs to COM3, ask in the session: “Read COM3 for five seconds and tell me what the board is printing.”
Expected: AI returns the raw log content and provides its own interpretation.
Level 4 · Create a Fault (AI Diagnosis)
Deliberately set the read baud rate to 115200 (inconsistent with the program’s 9600), then ask AI to read.
Expected: AI receives garbled text and proactively suggests “possible baud rate mismatch,” demonstrating the value of AI-assisted hardware diagnosis.
Technical Details and Notes¶
- No Build Process: The plugin is pure JS source code, which is the running product. Host-side code is in the
lib/directory, and Browser-side code is in theclient/directory. Changes take effect after refreshing, but there is no type checking. - Permissions and Runtime Environment: The plugin runs with dsh process permissions. If using the desktop version, ensure the serial port is not occupied by other programs.
- License: Follows the MIT License.
Conclusion¶
dsh-serial lowers the barrier to hardware debugging through its dual-channel design of panel and AI tools. Developers can directly use AI to analyze serial logs or leverage AI capabilities to assist in diagnosing hardware faults.
- GitHub Repository: https://github.com/Canye-zdm/dsh-serial
- Community Directory: https://www.skillhub.cn/plugins/Canye-zdm/dsh-serial