Skip to content

feat(ameba-rtos-m): add machine.USBSerial (USB CDC-ACM) for EV8711FLM - #2

Open
wangbaizhe wants to merge 1 commit into
mainfrom
dev
Open

feat(ameba-rtos-m): add machine.USBSerial (USB CDC-ACM) for EV8711FLM#2
wangbaizhe wants to merge 1 commit into
mainfrom
dev

Conversation

@wangbaizhe

Copy link
Copy Markdown
Collaborator

Add a USB CDC-ACM virtual serial port bound to ameba-rtos's usbd_cdc_acm stack, gated to EV8711FLM only (CONFIG_AMEBAGREEN2 + CONFIG_USBD_CDC_ACM). Implements construct/init/deinit/isconnected/any/read/write, and wires it into the boot console alongside the existing os.dupterm/WebREPL path.

write() blocks on a mutex-serialized TX-done semaphore to stay safe with DMA-direct transmit (CONFIG_CDC_ACM_BULK_TX_SKIP_MEMCPY=1).

Disabled by default (CONFIG_USB_OTG_EN_MENU/CONFIG_USB_DEVICE_EN_MENU/ CONFIG_USBD_CDC_ACM_MENU=n in boards/EV8711FLM/prj.conf) pending hardware verification of USB enumeration and REPL-over-USB; flip those three to y to opt in. Both boards build clean either way -- PKE8721DAF and a disabled EV8711FLM compile the feature to an empty object.

Add a USB CDC-ACM virtual serial port bound to ameba-rtos's usbd_cdc_acm
stack, gated to EV8711FLM only (CONFIG_AMEBAGREEN2 + CONFIG_USBD_CDC_ACM).
Implements construct/init/deinit/isconnected/any/read/write, and wires it
into the boot console alongside the existing os.dupterm/WebREPL path.

write() blocks on a mutex-serialized TX-done semaphore to stay safe with
DMA-direct transmit (CONFIG_CDC_ACM_BULK_TX_SKIP_MEMCPY=1).

Disabled by default (CONFIG_USB_OTG_EN_MENU/CONFIG_USB_DEVICE_EN_MENU/
CONFIG_USBD_CDC_ACM_MENU=n in boards/EV8711FLM/prj.conf) pending hardware
verification of USB enumeration and REPL-over-USB; flip those three to y
to opt in. Both boards build clean either way -- PKE8721DAF and a
disabled EV8711FLM compile the feature to an empty object.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant