Commit Graph

309 Commits

Author SHA1 Message Date
hathach
e0b192b633 - use CFG_TUH_MIDI as number of midi host instance
- comment out tuh_descriptor_device_cb/tuh_desc_configuration_cb since it is unrelated to this PR
2025-02-12 22:16:08 +07:00
hathach
7c405236cf fix host midi build 2025-02-12 11:50:57 +07:00
hathach
85247e50dd clean up 2025-02-12 11:34:32 +07:00
hathach
87adc63226 Merge branch 'master' into fork/atoktoto/midihost
# Conflicts:
#	hw/bsp/rp2040/family.cmake
#	src/class/midi/midi.h
#	src/class/midi/midi_device.c
#	src/device/usbd_control.c
#	src/host/hcd.h
#	src/host/usbh.c
#	src/host/usbh.h
2025-02-12 11:28:16 +07:00
hathach
3cacb01459 Merge branch 'refs/heads/master' into fork/GuavTek/recover_zero_length_desc 2024-11-28 10:36:17 +07:00
GuavTek
4212db1b83 Move desc_len sanity checks to start of loops 2024-11-27 22:19:42 +01:00
hathach
9e4b855e53 minor clean up 2024-11-27 11:35:21 +07:00
hathach
123f1affb7 update device_info example to work with p4 dcache 2024-11-27 00:01:37 +07:00
hathach
a5f9947a20 msc host work ok with p4 dma 2024-11-26 13:38:03 +07:00
hathach
be25aa31f6 hcd dwc2 add dcache support, usbh correctly use cache line size with TUH_EPBUF_DEF 2024-11-26 10:20:38 +07:00
hathach
5f891e020c usbh use the new tusb_time_delay_ms_api()
fix duplicated device attach for some devices which cause "USBH Defer Attach until current enumeration complete"
include dev0 for tuh_edpt_abort_xfer()
2024-11-04 17:24:49 +07:00
hathach
8461525d48 add tusb_time_millis(), able to reset and enable dwc2 port and get SOF active 2024-10-21 18:18:33 +07:00
GuavTek
ebcd7067c9 Recover host enumeration from zero length descriptors 2024-10-18 18:05:58 +02:00
hathach
1f18be93db change the tusb_rhport_init_t struct, exclude the rhport to make API more consistent 2024-10-14 18:27:52 +07:00
hathach
1587d48e89 hcd_init() take init struct 2024-10-11 17:53:39 +07:00
hathach
92602b9de3 change tusb_init(), tusb_rhport_init() to use init struct for expandability 2024-10-11 13:41:53 +07:00
hathach
57aac432b5 add new tusb_int_handler(rhport, in_isr) as common irq handler
update tusb_init() to take rhport and role, defined as macro with optional argument for backward compatible
2024-10-10 16:28:36 +07:00
Ryzee119
5e58ec127f usbh: Add set address recovery time
Ref USB Spec 9.2.6.3
2024-06-20 09:33:01 +09:30
Ryzee119
d52d659261 usbh: Set interface recipient should be interface 2024-06-18 14:02:36 +09:30
hathach
62331f0207 fix nrfx v3 spim freq when init
fix clang build with nrf
2024-04-22 15:55:50 +07:00
hathach
189080b684 add TU_ASSERT() to check for adding new usb event 2024-04-16 10:40:24 +07:00
hathach
c3c0648456 add class driver deinit 2024-04-08 22:07:56 +07:00
hathach
7d3d60f96d add hcd_configure() to change max NAK dynamically 2024-04-02 16:38:40 +07:00
hathach
ddb1034a9c use hub_addr=0, hub_port=0 for removing root hub port 2024-03-28 21:45:52 +07:00
Scott Shawcroft
d50003e33d Fake unplug devices when a root hub is deinit 2024-03-28 21:41:59 +07:00
hathach
3dcb7362aa fix build when CFG_TUH_HUB == 0 2024-03-28 19:18:20 +07:00
hathach
0da1da942a enhance hub removal using while loop to unroll recursive instead of event queue. 2024-03-28 16:32:02 +07:00
hathach
e84c9f3e22 implement tuh_init()
change usbh driver init() return type from void to bool
2024-03-22 16:12:57 +07:00
hathach
74bd264758 adding deinit() stub for usbh/hcd class driver
add TUSB_VERSION_BUILD, also add TUSB_VERSION_NUMBER
2024-03-22 11:42:33 +07:00
hathach
1d3969acbd - usbh enumeration: move _parse_configuration_descriptor after SET_CONFIGURATION is successful
- usbh: abort all pending xfer when SET_CONFIGURATION is complete
- use tu_edpt_release in tuh_edpt_abort_xfer instead of usbh_edpt_release
- rename _xfer_complete -> _control_xfer_complete
2024-03-04 17:44:53 +07:00
hathach
ff76eca311 code reformat 2024-03-04 17:38:44 +07:00
IngHK
4d4e20b71e missing \r\n after TU_LOG_BUF => moved \r\n to tu_print_buf() 2024-02-08 12:00:44 +01:00
IngHK
a066002731 Merge remote-tracking branch 'remotes/hathach/master' into improve_debug_prints 2024-02-07 10:11:42 +01:00
IngHK
e784e20b93 changes after review 2024-02-07 10:11:28 +01:00
hathach
290f4bea91 - change tuh_event_hook_cb, tud_event_hook_cb to weak default implementation
- change code style
2024-01-12 15:47:08 +07:00
Ryzee119
d39d06e6d9 [HUB] Prevent status request to invalid ep_num 2024-01-09 16:36:32 +10:30
IngHK
a39be99a58 improved hex debug print, improved USBH debug prints, added pid/vid debug print 2023-12-26 12:24:54 +01:00
IngHK
4d88f146e3 Merge remote-tracking branch 'remotes/hathach/master' into HostLogsFixes 2023-12-08 16:44:58 +01:00
IngHK
b8881a3a14 fixed compile errors due to untreated CFG_TUH_LOG_LEVEL 2023-11-24 22:34:28 +01:00
hathach
188fbd8ed9 add optional event hook callback tud_event_hook_cb() and tuh_event_hook_cb() 2023-11-24 18:21:24 +07:00
Angus Gratton
68894398af Add optional hooks for DCD and HCD events
These are intended to allow bare metal platforms with one-shot scheduling
capabilities to schedule the TinyUSB task handlers whenever they know there is
work for them to do.

Signed-off-by: Angus Gratton <angus@redyak.com.au>
2023-11-23 14:42:51 +11:00
hathach
9377fd6901 fix -Werror=null-dereference warning 2023-11-03 22:34:49 +07:00
hathach
4b9320e40e fix race condition when dev0 is removed while enumerating 2023-11-03 22:22:13 +07:00
hathach
277852afc1 fix esp32 msc example 2023-09-28 10:56:38 +07:00
hathach
f6ca86c3dd tested cdc_msc_hid_freertos with samd51
add -Wno-error=format for espressif
wrap up cdc_msc_hid_freertos
2023-09-26 19:09:36 +07:00
hathach
a7c136c03f adding host/cdc_msc_hid_freertos example 2023-09-25 16:53:11 +07:00
hathach
21ab40bab2 - wrap up hcd max3421, work well with nrf52840
- also add usbh_defer_func()
2023-09-07 12:38:18 +07:00
hathach
1b9108ea0d minor debug clean up 2023-09-06 17:11:35 +07:00
hathach
3b7d5aa042 improve connection & disconnection detection. But there is still issue when CONDETIRQ occurs but we are disabled interrupt (for osal queue access). 2023-08-31 16:52:09 +07:00
hathach
502b1bdda6 more update to transaction 2023-08-27 23:45:34 +07:00