summaryrefslogtreecommitdiff
path: root/examples/device/hid_boot_interface
AgeCommit message (Collapse)Author
2026-07-07Add SuperSpeed descriptors to all bulk/interrupt class drivers and exampleshathach
Class drivers: skip and account the SS endpoint companion descriptor in every descriptor walk (hid, midi, midi2, ecm_rndis, printer, mtp, usbtmc), via a shared usbd_skip_ss_ep_companion() helper in usbd_pvt.h (cdc/ncm already handled; vendor/dfu naturally tolerant). usbtmc buffer grows to 1024 at SS to satisfy its packet-multiple assert. bth/audio/video are left FS/HS-only (ISO-centric; ISO is unsupported on the CH569 dcd). usbd.h: new SS template macros TUD_HID_SS_DESCRIPTOR(+INOUT), TUD_MIDI_SS_DESCRIPTOR (+ DESC_EP_SS part), TUD_MIDI2_DESC_ALT1_EP_SS, TUD_PRINTER_SS_DESCRIPTOR, TUD_MTP_SS_DESCRIPTOR, TUD_USBTMC_BULK_SS_DESCRIPTORS/INT_SS_DESCRIPTOR, with _SS_DESC_LEN counterparts (bulk endpoints hardcode 1024, companion after every EP). Examples: 17 bulk/interrupt examples gain the full SS descriptor set (EP0 512/64 clamp, SS device descriptor bcdUSB 3.20 mps0=2^9, SS config with companions, BOS caps, speed-switched callbacks): cdc_dual_ports, cdc_msc_freertos, dfu, dfu_runtime, dynamic_configuration, hid_boot_interface, hid_composite(+freertos), hid_generic_inout, hid_multiple_interface, midi_test(+freertos), midi2_device, msc_dual_lun, mtp, printer_to_cdc, usbtmc, webusb_serial. msc_dual_lun is un-skipped for CH569 using read-only flash disks (16KB RAM can't hold two 8KB RAM disks, same as ch32v10x/v20x boards). Validation: full example sweep green for hydrausb3_v1 (SPEED=super, 19 device ELFs) and raspberry_pi_pico; wTotalLength == sizeof() verified for every SS configuration array in the built ELFs; ceedling 65/65; pre-commit clean; code-size delta +0.0% on rp2040 (SS code folds out on non-SS builds). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_019MRGjBT2NBkCoWwyDT4LaE
2026-06-29docs: add build-doc tooling and a README for every examplehathach
Documentation tooling: - Add the `build-doc` skill and `tools/build_doc.py` wrapper for local Sphinx builds (clean / -W / open). - Enable Markdown (MyST) in conf.py and auto-collect examples/{device,host,dual}/*/README.md into a 3-level Examples nav (Examples > Device/Host/Dual > example), noting each page's source location and normalizing headings to a single H1. - Remove the stale `.claude/commands/build-doc.md`; point the AGENTS.md Documentation section at the skill. Example docs: - Add a README.md for every device/host/dual example: what it does, USB interface table, notable tusb_config.h settings, generic CMake + Make build steps, and how to try it. - Fold each *_freertos variant into its base README, noting the FreeRTOS source path and any RTOS-specific behavior. Generated docs/examples/ output is git-ignored. Builds clean with `sphinx-build -W`. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
2026-06-22hw/bsp+wch: rename the CH58x family to ch583 and OPT_MCU_CH58X to OPT_MCU_CH583hathach
The BSP family and MCU option were named "ch58x"/"CH58X", but the supported part is the CH583/CH582 (and the SDK repo is openwch/ch583); CH585 is a separate MCU family, so the CH58x umbrella was misleading. Rename to the specific family: - hw/bsp/ch58x -> hw/bsp/ch583 (dir), and the BSP-local files ch58x_it.* -> ch583_it.*, system_ch58x.* -> system_ch583.* (include guards/refs updated). The vendor SDK files (CH58x_common.h, CH58x_*.c in hw/mcu/wch/ch583) keep their names. - OPT_MCU_CH58X -> OPT_MCU_CH583 in tusb_option.h, tusb_mcu.h, and the shared WCH USBFS driver (ch32_usbfs_reg.h, dcd_ch32_usbfs.c). OPT_MCU_CH582 is kept as an alias (same value), so either name selects the same code. - FAMILY_MCUS CH58X -> CH583, CFG_TUSB_MCU=OPT_MCU_CH583, mcu:CH58X -> mcu:CH583 in the example skip lists, the CI build matrix (ci_set_matrix.py), the get_deps family tag, and docs/reference/boards.rst. Board names (ch582m_evt, yd-ch582m) are unchanged. Verified: make + cmake build for ch582m_evt, and ci.lan HIL (all device examples pass). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
2026-03-05add IAR warning flags to cmake build and fix themhathach
2026-02-28replace board_millis() with tusb_time_millis_api()hathach
2025-12-19clean up cmake, remove family_get_project_name()hathach
2025-11-05added .clang-formathathach
fix more alerts disable IAR CStat since pvs-studio check is better integrated with clion
2025-10-28fix Identifiers that start with '__' or '_[A-Z]' are reserved.hathach
fix compiling with nuc family
2025-10-28fix descriptor warning when shifting zerohathach
2025-10-24fix several warningshathach
2025-10-14more make refactorhathach
2025-10-14move make.mk to hw/bsp/family_support.mkhathach
2025-09-17Fix board_init_after_tusbHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2025-02-09Add CMake presets.HiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2025-01-21bump up cmake min to 3.20hathach
2024-10-14change the tusb_rhport_init_t struct, exclude the rhport to make API more ↵hathach
consistent
2024-10-11change tusb_init(), tusb_rhport_init() to use init struct for expandabilityhathach
2024-10-10add new tusb_int_handler(rhport, in_isr) as common irq handlerhathach
update tusb_init() to take rhport and role, defined as macro with optional argument for backward compatible
2024-08-28Fix compiler warning in hid_boot_interface exampleAndrew Scheller
2023-11-23move make.mk and rules.mk to build_system/makehathach
2023-08-09Merge pull request #2202 from Rocky04/patch-4Ha Thach
Invoke unmounted state on configuration reset
2023-08-07Update examplesRocky04
2023-08-04update all examples to use unique ID as serial if avaialblehathach
2023-08-04Merge branch 'master' into enhance-bsphathach
2023-08-03add lpc43 familyhathach
2023-07-31enable USBMC for uno r4, add board_init_after_tusb() APIhathach
add BOARD_UPPERCASE for board detection
2023-06-27rework cmake with rtos support add RTOS to ↵hathach
family_configure_device/host/dual_example()
2023-04-21update most examples cmake to build with imxrthathach
2023-03-17fix trailing space and new linehathach
temporarily disable codespell
2023-03-06integrate top.mk into make.mkhathach
2023-02-04change length in tud_hid_report_complete_cb() from uint8 to uint16hathach
2022-12-04Fix typosBastien Nocera
2022-07-17temporarily revert len back to uint8_t in tud_hid_report_complete_cb() for ↵hathach
up coming release
2022-07-12RP@040: rework CMake for compiler warningsgraham sanderson
2022-06-27Merge branch 'master' into add-more-warningshathach
2022-06-27change report len in hid API from uint8_t to uint16_thathach
since HS interrupt endpoint can be up to 1024, 8-bit is not enough. affected APIs are: - tud_hid_n_report() / tud_hid_report() - tud_hid_report_complete_cb()
2022-06-27fix most warnings with rp2040 -wconversionhathach
2022-06-06more example updatehathach
2022-06-01rename board specific macro for examplehathach
- BOARD_DEVICE/HOST_RHPORT_NUM to BOARD_TUD/H_RHPORT - BOARD_DEVICE/HOST_RHPORT_SPEED to BOARD_TUD/H_MAX_SPEED
2022-04-27clean uphathach
2022-04-27add TU_ATTR_FAST_FUNC for rp2040 __not_in_flash() sectionhathach
2022-04-15pio device works wellhathach
2022-04-14catch up with pio libhathach
2022-04-08proof of concpet that device pio-usb work with host pio-usbhathach
2022-02-25auto detect max rhport speed based on mcuhathach
2021-12-08Add FT9xx to more examples which support High-SpeedGordon McNab
2021-09-25add CFG_TUSB_OS_INC_PATH for os include pathhathach
useful for freertos/ prefix with esp IDF
2021-08-17fix ci buildhathach
2021-08-17add hid_boot_interface examplehathach