| Age | Commit message (Collapse) | Author |
|
# Conflicts:
# lib/rt-thread/port/msc_device_port.c
# src/device/usbd.c
|
|
dcd_edpt_iso_alloc/activate were unimplemented stubs. Since samd is an ISO_ALLOC
port, the stack routes ISO endpoints through them, so every ISO endpoint open
failed: SET_CONFIGURATION with an ISO endpoint returned -EPIPE (can't set config)
and audio SET_INTERFACE(alt=1) stalled at usbd_edpt_iso_activate(). This was
misdiagnosed as a samd51 hardware ISO limitation; it is not.
Implement them mirroring dcd_edpt_open()'s per-direction setup: iso_alloc fixes
the endpoint bank SIZE bucket for the largest packet size (persists across
altsettings); iso_activate sets EPTYPE=ISO, clears stall + data toggle, enables
the transfer-complete interrupt.
metro_m4_express now passes the full usbtest battery 30/30 (was: SET_CONFIG
failed), including ISO 15/16/22/23.
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01HeF2gZ1M7GWkz6Av4BpKPg
|
|
* license: use SPDX identifiers for src/ headers
Replace the full ~20-line MIT license boilerplate on every src/ file with a
two-line SPDX tag (SPDX-FileCopyrightText + SPDX-License-Identifier), following
the REUSE convention used by CircuitPython and the Linux kernel. Removes ~3500
lines of duplicated boilerplate.
|
|
|
|
|
|
Co-authored-by: Copilot <[email protected]>
|
|
Signed-off-by: HiFiPhile <[email protected]>
|
|
Signed-off-by: HiFiPhile <[email protected]>
|
|
Signed-off-by: HiFiPhile <[email protected]>
|
|
Signed-off-by: HiFiPhile <[email protected]>
|
|
|
|
|
|
|
|
|
|
copilot/fix-dcd-edpt-xfer-issue
Signed-off-by: HiFiPhile <[email protected]>
|
|
as default driver implementation. dcd_edpt_close() is deprecated and will be removed from all driver in the future.
|
|
Co-authored-by: Copilot <[email protected]>
|
|
Co-authored-by: HiFiPhile <[email protected]>
|
|
OPT_MCU_SAML22
|
|
Signed-off-by: HiFiPhile <[email protected]>
|
|
enable host example build for samd21/d51
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* change TUD_EPBUF_TYPE_DEF order
* add and fix -Wmissing-prototypes warnings for cmake (skip make)
|
|
|
|
|
|
consistent
|
|
|
|
|
|
|
|
|
|
CFG_TUD_MEM_SECTION is default to CFG_TUSB_MEM_SECTION
|
|
temporarily disable codespell
|
|
|
|
Allow more endpoint packet sizes for SAMD
|
|
|
|
|
|
This PR fixes a transmit lock-up, which happens, when data is received
and sent at the sime time at moderate to high speeds, like code
which just echoes incoming data.
In my case, an issue was reported here:
https://github.com/micropython/micropython/issues/8521
|
|
Tested on SAMD51 - we can allow more packet sizes by checking that the set size value is greater than the requested packet size instead of exactly the same.
|
|
Not having this prevents the device from finishing the mounting process.
Tested on a SAMD51 and didn't seem to need to actually do anything in the close function.
|
|
Add SOF IRQ Handler
|
|
When transfer was finished rx_fifo_read() read all that
was to read RXPKTRDY was cleared allowing next packet to
be received.
Then xfer_complete was called.
Interrupt for OUT endpoint was left enable, that would not
be a problem if data was handled fast and new transfer was
scheduled.
For MSC when host sends a lot of data this interrupt that was
enabled could cause epn_handle_rx_int() to be called after
transfer was completed and next was not scheduled yet.
Without TU_ASSERT that was added to detect this, incoming
data was written past buffer provided by user code resulting
in random memory corruption.
This just blocks RX interrupt when transfer is finished,
and also only unmasked rx interrupts are handled.
|
|
TU_ASSERTS added to detect transfer inconsistency.
|