25#include "../usb/usb_private.h"
26#include "common/st_usbfs_core.h"
59 const uint16_t *lbuf = buf;
60 volatile uint32_t *PM = vPM;
61 for (len = (len + 1) >> 1; len; len--) {
76 const volatile uint16_t *PM = vPM;
77 uint8_t odd = len & 1;
79 for (len >>= 1; len; PM += 2, lbuf++, len--) {
84 *(uint8_t *) lbuf = *(uint8_t *) PM;
void rcc_periph_clock_enable(enum rcc_periph_clken clken)
Enable Peripheral Clock in running mode.
struct _usbd_device usbd_device
const struct _usbd_driver st_usbfs_v1_usb_driver
void st_usbfs_poll(usbd_device *dev)
void st_usbfs_ep_nak_set(usbd_device *dev, uint8_t addr, uint8_t nak)
uint16_t st_usbfs_ep_write_packet(usbd_device *dev, uint8_t addr, const void *buf, uint16_t len)
struct _usbd_device st_usbfs_dev
void st_usbfs_ep_setup(usbd_device *dev, uint8_t addr, uint8_t type, uint16_t max_size, void(*callback)(usbd_device *usbd_dev, uint8_t ep))
uint8_t st_usbfs_ep_stall_get(usbd_device *dev, uint8_t addr)
void st_usbfs_endpoints_reset(usbd_device *dev)
uint16_t st_usbfs_ep_read_packet(usbd_device *dev, uint8_t addr, void *buf, uint16_t len)
void st_usbfs_ep_stall_set(usbd_device *dev, uint8_t addr, uint8_t stall)
void st_usbfs_set_address(usbd_device *dev, uint8_t addr)
static usbd_device * st_usbfs_v1_usbd_init(void)
Initialize the USB device controller hardware of the STM32.
void st_usbfs_copy_to_pm(volatile void *vPM, const void *buf, uint16_t len)
void st_usbfs_copy_from_pm(void *buf, const volatile void *vPM, uint16_t len)
Copy a data buffer from packet memory.