53#include "interrupts.h"
56#define NVIC_EnableIRQ(_x) interrupt_enable(_x + 16)
57#define NVIC_DisableIRQ(_x) interrupt_disable(_x + 16)
58#define power_set() ( USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_PWRDWN )
59#ifdef USB_OTG_GCCFG_VBUSASEN
60#define vbus_enable() ( USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBUSASEN )
62#define vbus_enable() ( USB_OTG_FS->GCCFG |= USB_OTG_GCCFG_VBDEN )
86static inline void usb_hw_init(
void) {
88 RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN;
112 RCC->AHB2ENR |= RCC_AHB2ENR_OTGFSEN;
114 RCC->APB2ENR |= RCC_APB2ENR_SYSCFGEN;
#define GPIOA
Definition MK60D10.h:6910
#define GPIO_AFRH_AFRH2_3
Definition stm32f207xx.h:8701
#define GPIO_OTYPER_OT10_Msk
Definition stm32f407xx.h:8239
#define GPIO_MODER_MODER11_1
Definition stm32f207xx.h:8109
#define GPIO_AFRH_AFRH3_3
Definition stm32f207xx.h:8706
#define GPIO_AFRH_AFRH2_1
Definition stm32f207xx.h:8699
#define GPIO_PUPDR_PUPDR10_0
Definition stm32f207xx.h:8349
#define GPIO_MODER_MODER12_1
Definition stm32f207xx.h:8114
#define GPIO_MODER_MODER10_1
Definition stm32f207xx.h:8104
#define GPIO_OSPEEDR_OSPEEDR11_1
Definition stm32f745xx.h:8520
#define GPIO_AFRH_AFRH4_1
Definition stm32f207xx.h:8709
#define GPIO_OSPEEDR_OSPEEDR12_1
Definition stm32f745xx.h:8525
#define GPIO_AFRH_AFRH3_1
Definition stm32f207xx.h:8704
#define GPIO_AFRH_AFRH4_3
Definition stm32f207xx.h:8711