Initial Refleks Lite hardware and firmware release
This commit is contained in:
23
arcadestick_software/USB_DEVICE/App/usb_device_dfu.c
Normal file
23
arcadestick_software/USB_DEVICE/App/usb_device_dfu.c
Normal file
@@ -0,0 +1,23 @@
|
||||
#include "usb_device.h"
|
||||
|
||||
#include "usbd_core.h"
|
||||
#include "usbd_desc.h"
|
||||
#include "usbd_dfu_bootloader.h"
|
||||
|
||||
USBD_HandleTypeDef hUsbDeviceFS;
|
||||
|
||||
void MX_USB_DEVICE_Init(void)
|
||||
{
|
||||
if (USBD_Init(&hUsbDeviceFS, &FS_Desc, DEVICE_FS) != USBD_OK)
|
||||
{
|
||||
Error_Handler();
|
||||
}
|
||||
if (USBD_RegisterClass(&hUsbDeviceFS, &USBD_DFU_BOOTLOADER) != USBD_OK)
|
||||
{
|
||||
Error_Handler();
|
||||
}
|
||||
if (USBD_Start(&hUsbDeviceFS) != USBD_OK)
|
||||
{
|
||||
Error_Handler();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user