usbd_cdc_if.c (provides application read/write functions).usbd_desc.c (provides USB device descriptors).usbd_device.c (provides initializing function called from main()).usbd_conf.c (provides low layer / HAL functions).usbd_cdc.c (provides everything to interact with USB host, descriptors, data IO …). ![]() usbd_ioreq.c, usbd_ctlreq.c (provides everything for endpoint controls and USB request).usbd_core.c (provides all USB device core functions).More about endpoints later.Īgain, USB files contains “settings for CDC” in this files: To generate basic USB CDC device with CubeMX, follow this previous post, but change Middleware USB profile to CDC. ![]() ![]() So, here it is, STM32 USB CDC – communication with PC over USB, generated with STM32CubeMX on STM32L100 discovery board. Although this devices were mostly prototypes and/or single products, such approach added unwanted costs and since almost all uC that I used already have USB peripheral embedded, there is no excuse not to use it. By now almost all of my projects included some sort of communication with PC, mostly with external USB-UART bridge chip like MCP2200 or CP210x.
0 Comments
Leave a Reply. |