TinyUSB Toggle between HID_PROTOCOL_BOOT and HID_PROTOCOL_REPORT #1632
Labels
No labels
bazel
bluetooth
board settings
boot_stage2
bug
build
c++
can't reproduce
clang
clib-interface
cmsis
code cleanliness
code size
compiler version issues
cyw43_driver
debug
discussion
documentation
duplicate
dynamic_clock
elf2uf2
enhancement
errata
filesystem
flash layout
floating point
FreeRTOS
hardware_adc
hardware_claim
hardware_clocks
hardware_dma
hardware_exception
hardware_flash
hardware_gpio
hardware_i2c
hardware_irq
hardware_pio
hardware_pwm
hardware_rcp
hardware_rtc
hardware_spi
hardware_sync
hardware_uart
hardware_vreg
hardware_watchdog
hardware_xosc
help wanted
host
IAR
installation
invalid
linker scripts
lto
lwip
mbedtls
missing API
needs reporter detail
networking
newlib
newlib-multicore
non-c
non-cmake
non-gcc
openocd
orphan PR
OS integration
pico_async_context
pico_base
pico_binary_info
pico_flash
picolibc
pico_lwip
pico_malloc
pico_multicore
pico_printf
pico_runtime
pico_stdio
pico_stdio_usb
pico_sync
pico_time
pico_util
pioasm
port
question
review
review2
rtos interop
runtime init
static library
svd
test
tinyusb
vscode
wifi integration
wontfix
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-raspberrypi/pico-sdk#1632
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Toggling mouse interface protocol between boot and report on Logitech K270/M185 blocks the ongoing interrupt endpoint transfer. This works for several KM devices. The only difference between those device and the Logitech K270/M185 or K220/M150 is the the wMaxPacketSize parameter. On the Logitech combo devices the value is 20 bytes for mouse endpoint and 8 bytes for keyboard endpoint. For the other devices the wMaxPacketSize is less than or equal to 8 bytes.
I have modified the tinyusb bare api example to add the protocol toggling.
ex_host_bare_api.zip
This issue might look trivial but It looks like an issue with the hardware controller. After toggling the report protocol, the keyboard endpoint get blocked. The host sends request to the keyboard endpoint and the keyboard is replying the IN request but the host is not sending the ACK and restart the IN transfer without firing any interrupt.
@P33M does this make any sense to you?
Hello @peterharperuk, @P33M @hathach,
Do you have any idea of what is going on here?
You can easily reproduce the issue by building the attached example project.
After building the project, you can load the UF2 file on the pico board then connect a Logitech wireless KM (ex. K270/M185 or K220/M150) and click "R" to switch mouse to report mode or "B" to switch it to boot mode.
You can also connect a wired keyboard using a hub since the PICO has only one USB port and in this case the switching works. The switching works also with combo devices from microsoft.
The only difference between the logitech combo devices and other tested devices is that the the mouse interface wMaxPacketSize is 20 bytes where it is 8bytes or less for other devices.
No. You might have to do better to convince me this is a Pico issue and not just a tinyusb problem
moving to none until we know this is an SDK issue