usb-device-profile

Generate USB device-profile JSON describing endpoint types, directions, and packet sizes from driver source.

2|Updated May 13, 2026
One-click install
npx skills add https://github.com/curtisgalloway/public-skills --skill usb-device-profile-curtisgalloway
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: usb-device-profile
Source: https://github.com/curtisgalloway/public-skills/tree/main/plugins/hardware-lab/skills/usb-device-profile
Command: npx skills add https://github.com/curtisgalloway/public-skills --skill usb-device-profile-curtisgalloway

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When USB captures lack the enumeration phase, decode pipelines cannot determine endpoint transfer types. This Skill generates a device-profile JSON from the device's driver source so the Cynthion decode pipeline can pre-seed endpoint types without enumeration traffic. ## Core Features & Use Cases - Fuchsia driver source analysis: Locates USB function drivers, extracts endpoint and interface descriptors, identifies configurations, and finds VID/PID from component manifests. - CircuitPython boot.py mapping: Translates usb_cdc.enable and usb_hid.enable calls into CDC and HID interface definitions with correct endpoint types. - Uncertainty annotation: Marks endpoint addresses as guidance-only when dynamic allocation (Fuchsia) or registration order (CircuitPython) makes them non-deterministic. - Use Case: You captured USB traffic from a KB2040 device but missed enumeration. Use this Skill to read its boot.py, produce a profile JSON with CDC and HID endpoints, and feed it to the decode pipeline for typed endpoint analysis. ## Quick Start Generate a USB device profile for my device by reading its driver source and produce the profile JSON for the Cynthion decode pipeline.

Frequently Asked Questions about usb-device-profile

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate a USB device profile from driver source code?▼

Locate the function driver files containing usb_endpoint_descriptor_t or usb_interface_descriptor_t structs, extract endpoint addresses, bmAttributes transfer types, and wMaxPacketSize values, then assemble them into the profile JSON format with VID, PID, and configuration entries.

How to decode USB captures without enumeration traffic?▼

Use a device-profile JSON to pre-seed endpoint types in the Cynthion decode pipeline. The profile records static endpoint facts from driver source so the decoder can type endpoints even when the capture missed the descriptor exchange.

Can I generate a USB profile from CircuitPython boot.py?▼

Yes, boot.py fully specifies the USB configuration. Map usb_cdc.enable to CDC communication and data interface pairs, and usb_hid.enable to a composite HID interface, but mark endpoint addresses as uncertain since CircuitPython assigns them dynamically.

Why are endpoint addresses in the profile not authoritative?▼

Fuchsia allocates endpoint addresses dynamically across loaded functions and CircuitPython assigns them in registration order, so addresses derived from source are guidance only. Verify them against a baseline enumeration capture or lsusb output before relying on them.

What USB transfer types does the profile support?▼

The profile supports control, bulk, interrupt, and isochronous transfer types, decoded from bmAttributes bits 1:0 of the endpoint descriptor. Endpoint direction is encoded in address bit 7, with values 128 and above indicating IN endpoints.