-
- Downloads
stmhal: Add USB_VCP class/object, for direct USB VCP control.
Before, pyb.stdin/pyb.stdout allowed some kind of access to the USB VCP device, but it was basic access. This patch adds a proper USB_VCP class and object with much more control over the USB VCP device. Create an object with pyb.USB_VCP(), then use this object as if it were a UART object. It has send, recv, read, write, and other methods. send and recv allow a timeout to be specified. Addresses issue 774.
Showing
- stmhal/modpyb.c 1 addition, 0 deletionsstmhal/modpyb.c
- stmhal/pybstdio.c 4 additions, 2 deletionsstmhal/pybstdio.c
- stmhal/qstrdefsport.h 6 additions, 0 deletionsstmhal/qstrdefsport.h
- stmhal/usb.c 148 additions, 10 deletionsstmhal/usb.c
- stmhal/usb.h 3 additions, 2 deletionsstmhal/usb.h
- stmhal/usbd_cdc_interface.c 58 additions, 11 deletionsstmhal/usbd_cdc_interface.c
- stmhal/usbd_cdc_interface.h 7 additions, 4 deletionsstmhal/usbd_cdc_interface.h
Loading
Please register or sign in to comment