change dcd_init() to take rhport struct
This commit is contained in:
@@ -470,8 +470,8 @@ static void process_bus_resume(uint8_t rhport)
|
||||
/*------------------------------------------------------------------*/
|
||||
/* Device API
|
||||
*------------------------------------------------------------------*/
|
||||
void dcd_init(uint8_t rhport)
|
||||
{
|
||||
void dcd_init(const tusb_rhport_init_t* rh_init) {
|
||||
const uint8_t rhport = rh_init->rhport;
|
||||
intr_disable(rhport);
|
||||
intr_clear(rhport);
|
||||
|
||||
|
||||
@@ -120,8 +120,8 @@ static ep0_stage_t ep0_get_stage(void)
|
||||
/*------------------------------------------------------------------*/
|
||||
/* Controller API
|
||||
*------------------------------------------------------------------*/
|
||||
void dcd_init(uint8_t rhport)
|
||||
{
|
||||
void dcd_init(const tusb_rhport_init_t* rh_init) {
|
||||
const uint8_t rhport = rh_init->rhport;
|
||||
// Disable endpoint interrupts for now
|
||||
USB_REGS->INTRRXEbits.w = 0;
|
||||
USB_REGS->INTRTXEbits.w = 0;
|
||||
|
||||
Reference in New Issue
Block a user