mirror of
https://github.com/hathach/tinyusb.git
synced 2025-03-25 10:43:44 +00:00
rename romdriver handle
forming API for USBD-CLASS driver (abstract away from rom driver) separate buffer of hid class from buffer of core driver
This commit is contained in:
parent
9e49056721
commit
7d78fc1baf
@ -45,7 +45,7 @@
|
||||
|
||||
#include "usbd.h"
|
||||
#include "mock_dcd.h"
|
||||
//#include "mock_"
|
||||
#include "mock_hid_device.h"
|
||||
|
||||
void setUp(void)
|
||||
{
|
||||
@ -67,8 +67,9 @@ void test_dcd_init_failed(void)
|
||||
void test_usbd_init_ok(void)
|
||||
{
|
||||
dcd_init_ExpectAndReturn(TUSB_ERROR_NONE);
|
||||
hidd_init_ExpectAndReturn(&app_tusb_desc_configuration.keyboard_interface, TUSB_ERROR_NONE);
|
||||
|
||||
|
||||
dcd_controller_connect_Expect(0);
|
||||
|
||||
//------------- Code Under Test -------------//
|
||||
TEST_ASSERT_EQUAL( TUSB_ERROR_NONE, usbd_init() );
|
||||
|
@ -46,19 +46,13 @@
|
||||
//--------------------------------------------------------------------+
|
||||
#include "common/common.h"
|
||||
#include "hid_device.h"
|
||||
#include "tusb_descriptors.h"
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// MACRO CONSTANT TYPEDEF
|
||||
//--------------------------------------------------------------------+
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// INTERNAL OBJECT & FUNCTION DECLARATION
|
||||
//--------------------------------------------------------------------+
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// IMPLEMENTATION
|
||||
//--------------------------------------------------------------------+
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
TUSB_CFG_ATTR_USBRAM uint8_t hidd_keyboard_buffer[1024]; // TODO memory reduce
|
||||
TUSB_CFG_ATTR_USBRAM tusb_keyboard_report_t hid_keyboard_report;
|
||||
static volatile bool bKeyChanged = false;
|
||||
#endif
|
||||
@ -68,6 +62,138 @@ TUSB_CFG_ATTR_USBRAM tusb_mouse_report_t hid_mouse_report;
|
||||
static volatile bool bMouseChanged = false;
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// INTERNAL OBJECT & FUNCTION DECLARATION
|
||||
//--------------------------------------------------------------------+
|
||||
static tusb_error_t hidd_interface_init(tusb_descriptor_interface_t const *pIntfDesc, uint8_t const * const pHIDReportDesc,
|
||||
uint32_t ReportDescLength, uint8_t* mem_base, uint32_t mem_size);
|
||||
|
||||
ErrorCode_t HID_GetReport( USBD_HANDLE_T hHid, USB_SETUP_PACKET* pSetup, uint8_t** pBuffer, uint16_t* plength);
|
||||
ErrorCode_t HID_SetReport( USBD_HANDLE_T hHid, USB_SETUP_PACKET* pSetup, uint8_t** pBuffer, uint16_t length);
|
||||
ErrorCode_t HID_EpIn_Hdlr (USBD_HANDLE_T hUsb, void* data, uint32_t event);
|
||||
ErrorCode_t HID_EpOut_Hdlr (USBD_HANDLE_T hUsb, void* data, uint32_t event);
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// IMPLEMENTATION
|
||||
//--------------------------------------------------------------------+
|
||||
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// CLASS-USBH API (don't require to verify parameters)
|
||||
//--------------------------------------------------------------------+
|
||||
tusb_error_t hidd_init(tusb_descriptor_interface_t const * p_interface_desc)
|
||||
{
|
||||
uint8_t const *p_desc = (uint8_t const *) p_interface_desc;
|
||||
|
||||
//------------- HID descriptor -------------//
|
||||
p_desc += p_desc[DESCRIPTOR_OFFSET_LENGTH];
|
||||
tusb_hid_descriptor_hid_t const *p_desc_hid = (tusb_hid_descriptor_hid_t const *) p_desc;
|
||||
ASSERT_INT(HID_DESC_TYPE_HID, p_desc_hid->bDescriptorType, TUSB_ERROR_HIDD_DESCRIPTOR_INTERFACE);
|
||||
|
||||
ASSERT_STATUS( hidd_interface_init(p_interface_desc,
|
||||
app_tusb_keyboard_desc_report, p_desc_hid->wReportLength,
|
||||
hidd_keyboard_buffer , sizeof(hidd_keyboard_buffer)) );
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
tusb_error_t hidd_interface_init(tusb_descriptor_interface_t const *pIntfDesc, uint8_t const * const pHIDReportDesc,
|
||||
uint32_t ReportDescLength, uint8_t* mem_base, uint32_t mem_size)
|
||||
{
|
||||
USB_HID_REPORT_T reports_data =
|
||||
{
|
||||
.desc = (uint8_t*) pHIDReportDesc,
|
||||
.len = ReportDescLength,
|
||||
.idle_time = 0,
|
||||
};
|
||||
|
||||
USBD_HID_INIT_PARAM_T hid_param =
|
||||
{
|
||||
.mem_base = (uint32_t) mem_base,
|
||||
.mem_size = mem_size,
|
||||
|
||||
.intf_desc = (uint8_t*)pIntfDesc,
|
||||
.report_data = &reports_data,
|
||||
.max_reports = 1,
|
||||
|
||||
/* user defined functions */
|
||||
.HID_GetReport = HID_GetReport,
|
||||
.HID_SetReport = HID_SetReport,
|
||||
.HID_EpIn_Hdlr = HID_EpIn_Hdlr,
|
||||
.HID_EpOut_Hdlr = HID_EpOut_Hdlr
|
||||
};
|
||||
|
||||
ASSERT( (pIntfDesc != NULL) && (pIntfDesc->bInterfaceClass == USB_DEVICE_CLASS_HUMAN_INTERFACE), ERR_FAILED);
|
||||
|
||||
ASSERT( LPC_OK == ROM_API->hid->init(romdriver_hdl, &hid_param), TUSB_ERROR_FAILED );
|
||||
|
||||
/* update memory variables */
|
||||
// *mem_base += (*mem_size - hid_param.mem_size);
|
||||
// *mem_size = hid_param.mem_size;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
tusb_error_t hidd_configured(USBD_HANDLE_T hUsb)
|
||||
{
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
ROM_API->hw->WriteEP(hUsb , HID_KEYBOARD_EP_IN , (uint8_t* ) &hid_keyboard_report , sizeof(tusb_keyboard_report_t) ); // initial packet for IN endpoint , will not work if omitted
|
||||
#endif
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_MOUSE
|
||||
ROM_API->hw->WriteEP(hUsb , HID_MOUSE_EP_IN , (uint8_t* ) &hid_mouse_report , sizeof(tusb_mouse_report_t) ); // initial packet for IN endpoint, will not work if omitted
|
||||
#endif
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
tusb_error_t tusbd_hid_keyboard_send_report(tusb_keyboard_report_t *p_kbd_report)
|
||||
{
|
||||
// uint32_t start_time = systickGetSecondsActive();
|
||||
// while (bKeyChanged) // TODO blocking while previous key has yet sent - can use fifo to improve this
|
||||
// {
|
||||
// ASSERT_MESSAGE(systickGetSecondsActive() - start_time < 5, ERR_FAILED, "HID Keyboard Timeout");
|
||||
// }
|
||||
|
||||
if (bKeyChanged)
|
||||
{
|
||||
return TUSB_ERROR_FAILED;
|
||||
}
|
||||
|
||||
ASSERT_PTR(p_kbd_report, TUSB_ERROR_FAILED);
|
||||
|
||||
hid_keyboard_report = *p_kbd_report;
|
||||
bKeyChanged = true;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_MOUSE
|
||||
tusb_error_t tusb_hid_mouse_send(uint8_t buttons, int8_t x, int8_t y)
|
||||
{
|
||||
// uint32_t start_time = systickGetSecondsActive();
|
||||
// while (bMouseChanged) // TODO Block while previous key hasn't been sent - can use fifo to improve this
|
||||
// {
|
||||
// ASSERT_MESSAGE(systickGetSecondsActive() - start_time < 5, ERR_FAILED, "HID Mouse Timeout");
|
||||
// }
|
||||
|
||||
if (bMouseChanged)
|
||||
{
|
||||
return TUSB_ERROR_FAILED;
|
||||
}
|
||||
|
||||
hid_mouse_report.buttons = buttons;
|
||||
hid_mouse_report.x = x;
|
||||
hid_mouse_report.y = y;
|
||||
|
||||
bMouseChanged = true;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
#endif
|
||||
|
||||
ErrorCode_t HID_GetReport( USBD_HANDLE_T hHid, USB_SETUP_PACKET* pSetup, uint8_t** pBuffer, uint16_t* plength)
|
||||
{
|
||||
USB_HID_CTRL_T* pHidCtrl = (USB_HID_CTRL_T*) hHid;
|
||||
@ -173,103 +299,4 @@ ErrorCode_t HID_EpOut_Hdlr (USBD_HANDLE_T hUsb, void* data, uint32_t event)
|
||||
return LPC_OK;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// CLASS-USBH API (don't require to verify parameters)
|
||||
//--------------------------------------------------------------------+
|
||||
tusb_error_t hidd_init(USBD_HANDLE_T hUsb, tusb_descriptor_interface_t const *const pIntfDesc, uint8_t const * const pHIDReportDesc, uint32_t ReportDescLength, uint32_t* mem_base, uint32_t* mem_size)
|
||||
{
|
||||
USB_HID_REPORT_T reports_data =
|
||||
{
|
||||
.desc = (uint8_t*) pHIDReportDesc,
|
||||
.len = ReportDescLength,
|
||||
.idle_time = 0,
|
||||
};
|
||||
|
||||
USBD_HID_INIT_PARAM_T hid_param =
|
||||
{
|
||||
.mem_base = *mem_base,
|
||||
.mem_size = *mem_size,
|
||||
|
||||
.intf_desc = (uint8_t*)pIntfDesc,
|
||||
.report_data = &reports_data,
|
||||
.max_reports = 1,
|
||||
|
||||
/* user defined functions */
|
||||
.HID_GetReport = HID_GetReport,
|
||||
.HID_SetReport = HID_SetReport,
|
||||
.HID_EpIn_Hdlr = HID_EpIn_Hdlr,
|
||||
.HID_EpOut_Hdlr = HID_EpOut_Hdlr
|
||||
};
|
||||
|
||||
ASSERT( (pIntfDesc != NULL) && (pIntfDesc->bInterfaceClass == USB_DEVICE_CLASS_HUMAN_INTERFACE), ERR_FAILED);
|
||||
|
||||
ASSERT( LPC_OK == ROM_API->hid->init(hUsb, &hid_param), TUSB_ERROR_FAILED );
|
||||
|
||||
/* update memory variables */
|
||||
*mem_base += (*mem_size - hid_param.mem_size);
|
||||
*mem_size = hid_param.mem_size;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
tusb_error_t hidd_configured(USBD_HANDLE_T hUsb)
|
||||
{
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
ROM_API->hw->WriteEP(hUsb , HID_KEYBOARD_EP_IN , (uint8_t* ) &hid_keyboard_report , sizeof(tusb_keyboard_report_t) ); // initial packet for IN endpoint , will not work if omitted
|
||||
#endif
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_MOUSE
|
||||
ROM_API->hw->WriteEP(hUsb , HID_MOUSE_EP_IN , (uint8_t* ) &hid_mouse_report , sizeof(tusb_mouse_report_t) ); // initial packet for IN endpoint, will not work if omitted
|
||||
#endif
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
tusb_error_t tusbd_hid_keyboard_send_report(tusb_keyboard_report_t *p_kbd_report)
|
||||
{
|
||||
// uint32_t start_time = systickGetSecondsActive();
|
||||
// while (bKeyChanged) // TODO blocking while previous key has yet sent - can use fifo to improve this
|
||||
// {
|
||||
// ASSERT_MESSAGE(systickGetSecondsActive() - start_time < 5, ERR_FAILED, "HID Keyboard Timeout");
|
||||
// }
|
||||
|
||||
if (bKeyChanged)
|
||||
{
|
||||
return TUSB_ERROR_FAILED;
|
||||
}
|
||||
|
||||
ASSERT_PTR(p_kbd_report, TUSB_ERROR_FAILED);
|
||||
|
||||
hid_keyboard_report = *p_kbd_report;
|
||||
bKeyChanged = true;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_MOUSE
|
||||
tusb_error_t tusb_hid_mouse_send(uint8_t buttons, int8_t x, int8_t y)
|
||||
{
|
||||
// uint32_t start_time = systickGetSecondsActive();
|
||||
// while (bMouseChanged) // TODO Block while previous key hasn't been sent - can use fifo to improve this
|
||||
// {
|
||||
// ASSERT_MESSAGE(systickGetSecondsActive() - start_time < 5, ERR_FAILED, "HID Mouse Timeout");
|
||||
// }
|
||||
|
||||
if (bMouseChanged)
|
||||
{
|
||||
return TUSB_ERROR_FAILED;
|
||||
}
|
||||
|
||||
hid_mouse_report.buttons = buttons;
|
||||
hid_mouse_report.x = x;
|
||||
hid_mouse_report.y = y;
|
||||
|
||||
bMouseChanged = true;
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -66,7 +66,7 @@ tusb_error_t tusbd_hid_mouse_send_report(uint8_t buttons, int8_t x, int8_t y);
|
||||
#ifdef _TINY_USB_SOURCE_FILE_
|
||||
#include "device/romdriver/mw_usbd_rom_api.h" // TODO remove rom driver dependency
|
||||
|
||||
tusb_error_t hidd_init(USBD_HANDLE_T hUsb, tusb_descriptor_interface_t const *const pIntfDesc, uint8_t const * const pHIDReportDesc, uint32_t ReportDescLength, uint32_t* mem_base, uint32_t* mem_size);
|
||||
tusb_error_t hidd_init(tusb_descriptor_interface_t const * p_interface_desc);
|
||||
tusb_error_t hidd_configured(USBD_HANDLE_T hUsb);
|
||||
|
||||
#endif
|
||||
|
@ -74,6 +74,7 @@
|
||||
ENTRY(TUSB_ERROR_OSAL_SEMAPHORE_FAILED )\
|
||||
ENTRY(TUSB_ERROR_EHCI_NOT_ENOUGH_QTD )\
|
||||
ENTRY(TUSB_ERROR_USBD_DESCRIPTOR_STRING )\
|
||||
ENTRY(TUSB_ERROR_HIDD_DESCRIPTOR_INTERFACE )\
|
||||
ENTRY(TUSB_ERROR_FAILED )\
|
||||
|
||||
|
||||
|
@ -43,7 +43,7 @@
|
||||
|
||||
#define USB_ROM_SIZE (1024*2) // TODO dcd abstract later
|
||||
uint8_t usb_RomDriver_buffer[USB_ROM_SIZE] ATTR_ALIGNED(2048) TUSB_CFG_ATTR_USBRAM;
|
||||
USBD_HANDLE_T g_hUsb;
|
||||
USBD_HANDLE_T romdriver_hdl;
|
||||
static volatile bool isConfigured = false;
|
||||
|
||||
/**************************************************************************/
|
||||
@ -109,25 +109,25 @@ tusb_error_t dcd_init(uint8_t coreid)
|
||||
};
|
||||
|
||||
/* USB hardware core initialization */
|
||||
ASSERT(LPC_OK == ROM_API->hw->Init(&g_hUsb, &DeviceDes, &usb_param), TUSB_ERROR_FAILED);
|
||||
ASSERT(LPC_OK == ROM_API->hw->Init(&romdriver_hdl, &DeviceDes, &usb_param), TUSB_ERROR_FAILED);
|
||||
|
||||
membase += (memsize - usb_param.mem_size);
|
||||
memsize = usb_param.mem_size;
|
||||
|
||||
/* Initialise the class driver(s) */
|
||||
#ifdef TUSB_CFG_DEVICE_CDC
|
||||
ASSERT_STATUS( tusb_cdc_init(g_hUsb, &USB_FsConfigDescriptor.CDC_CCI_Interface,
|
||||
ASSERT_STATUS( tusb_cdc_init(romdriver_hdl, &USB_FsConfigDescriptor.CDC_CCI_Interface,
|
||||
&USB_FsConfigDescriptor.CDC_DCI_Interface, &membase, &memsize) );
|
||||
#endif
|
||||
|
||||
#ifdef TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
ASSERT_STATUS( tusb_hid_init(g_hUsb , &USB_FsConfigDescriptor.HID_KeyboardInterface ,
|
||||
ASSERT_STATUS( tusb_hid_init(romdriver_hdl , &USB_FsConfigDescriptor.HID_KeyboardInterface ,
|
||||
HID_KeyboardReportDescriptor, USB_FsConfigDescriptor.HID_KeyboardHID.DescriptorList[0].wDescriptorLength,
|
||||
&membase , &memsize) );
|
||||
#endif
|
||||
|
||||
#ifdef TUSB_CFG_DEVICE_HID_MOUSE
|
||||
ASSERT_STATUS( tusb_hid_init(g_hUsb , &USB_FsConfigDescriptor.HID_MouseInterface ,
|
||||
ASSERT_STATUS( tusb_hid_init(romdriver_hdl , &USB_FsConfigDescriptor.HID_MouseInterface ,
|
||||
HID_MouseReportDescriptor, USB_FsConfigDescriptor.HID_MouseHID.DescriptorList[0].wDescriptorLength,
|
||||
&membase , &memsize) );
|
||||
#endif
|
||||
@ -135,7 +135,7 @@ tusb_error_t dcd_init(uint8_t coreid)
|
||||
hal_interrupt_enable(); /* Enable the USB interrupt */
|
||||
|
||||
/* Perform USB soft connect */
|
||||
ROM_API->hw->Connect(g_hUsb, 1);
|
||||
ROM_API->hw->Connect(romdriver_hdl, 1);
|
||||
#endif
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
|
@ -47,15 +47,12 @@
|
||||
//--------------------------------------------------------------------+
|
||||
#include "dcd.h"
|
||||
#include "dcd_nxp_romdriver.h"
|
||||
#include "romdriver/mw_usbd_rom_api.h"
|
||||
|
||||
#include "tusb_descriptors.h"
|
||||
|
||||
|
||||
#define USB_ROM_SIZE (1024*2) // TODO dcd abstract later
|
||||
uint8_t usb_RomDriver_buffer[USB_ROM_SIZE] ATTR_ALIGNED(2048) TUSB_CFG_ATTR_USBRAM;
|
||||
|
||||
USBD_HANDLE_T g_hUsb;
|
||||
USBD_HANDLE_T romdriver_hdl;
|
||||
|
||||
typedef struct {
|
||||
volatile uint8_t state;
|
||||
@ -147,29 +144,18 @@ tusb_error_t dcd_init(void)
|
||||
};
|
||||
|
||||
/* USB hardware core initialization */
|
||||
ASSERT_INT(LPC_OK, ROM_API->hw->Init(&g_hUsb, &desc_core, &usb_param), TUSB_ERROR_FAILED);
|
||||
ASSERT_INT(LPC_OK, ROM_API->hw->Init(&romdriver_hdl, &desc_core, &usb_param), TUSB_ERROR_FAILED);
|
||||
|
||||
// TODO need to confirm the mem_size is reduced by the number of byte used
|
||||
membase += (memsize - usb_param.mem_size);
|
||||
memsize = usb_param.mem_size;
|
||||
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
ASSERT_STATUS( hidd_init(g_hUsb , &app_tusb_desc_configuration.keyboard_interface,
|
||||
app_tusb_keyboard_desc_report, app_tusb_desc_configuration.keyboard_hid.wReportLength,
|
||||
&membase , &memsize) );
|
||||
#endif
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_MOUSE
|
||||
ASSERT_STATUS( tusb_hid_init(g_hUsb , &USB_FsConfigDescriptor.HID_MouseInterface ,
|
||||
ASSERT_STATUS( tusb_hid_init(romdriver_hdl , &USB_FsConfigDescriptor.HID_MouseInterface ,
|
||||
HID_MouseReportDescriptor, USB_FsConfigDescriptor.HID_MouseHID.DescriptorList[0].wDescriptorLength,
|
||||
&membase , &memsize) );
|
||||
#endif
|
||||
|
||||
hal_interrupt_enable(0);
|
||||
ROM_API->hw->Connect(g_hUsb, 1);
|
||||
ROM_API->hw->ForceFullSpeed(g_hUsb, 1);
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
@ -187,12 +173,12 @@ tusb_error_t dcd_controller_reset(uint8_t coreid)
|
||||
|
||||
void dcd_controller_connect(uint8_t coreid)
|
||||
{
|
||||
// ROM_API->hw->Connect(g_hUsb, 1);
|
||||
ROM_API->hw->Connect(romdriver_hdl, 1);
|
||||
}
|
||||
|
||||
void dcd_isr(uint8_t coreid)
|
||||
{
|
||||
ROM_API->hw->ISR(g_hUsb);
|
||||
ROM_API->hw->ISR(romdriver_hdl);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -47,6 +47,7 @@
|
||||
#define _TUSB_DCD_NXP_ROMDRIVER_H_
|
||||
|
||||
#include "common/common.h"
|
||||
#include "romdriver/mw_usbd_rom_api.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@ -62,6 +63,8 @@
|
||||
#error forgot something, thach ?
|
||||
#endif
|
||||
|
||||
extern USBD_HANDLE_T romdriver_hdl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -80,6 +80,16 @@ tusb_error_t usbd_init (void)
|
||||
|
||||
ASSERT_STATUS ( dcd_init() );
|
||||
|
||||
#if TUSB_CFG_DEVICE_HID_KEYBOARD
|
||||
ASSERT_STATUS( hidd_init(&app_tusb_desc_configuration.keyboard_interface) );
|
||||
#endif
|
||||
|
||||
#ifndef _TEST_
|
||||
hal_interrupt_enable(0); // TODO USB1
|
||||
#endif
|
||||
|
||||
dcd_controller_connect(0); // TODO USB1
|
||||
|
||||
return TUSB_ERROR_NONE;
|
||||
}
|
||||
|
||||
|
@ -49,8 +49,10 @@
|
||||
//--------------------------------------------------------------------+
|
||||
// INCLUDE
|
||||
//--------------------------------------------------------------------+
|
||||
#include "common/common.h"
|
||||
#include "osal/osal.h" // TODO refractor move to common.h ?
|
||||
#include "dcd.h"
|
||||
#include "dcd.h" // TODO hide from application include
|
||||
//#include "tusb_descriptors.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
Loading…
x
Reference in New Issue
Block a user