From a0002cc709bd39049d3effbe9a59b62dc198f79d Mon Sep 17 00:00:00 2001 From: hathach Date: Wed, 30 Oct 2019 23:26:34 +0700 Subject: [PATCH] rename usbd_init() to tud_init() --- src/device/usbd.c | 2 +- src/device/usbd.h | 3 +++ src/device/usbd_pvt.h | 2 -- src/tusb.c | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/device/usbd.c b/src/device/usbd.c index 3e6bf68c9..62f6e9922 100644 --- a/src/device/usbd.c +++ b/src/device/usbd.c @@ -276,7 +276,7 @@ bool tud_remote_wakeup(void) //--------------------------------------------------------------------+ // USBD Task //--------------------------------------------------------------------+ -bool usbd_init (void) +bool tud_init (void) { TU_LOG2("USBD init\r\n"); diff --git a/src/device/usbd.h b/src/device/usbd.h index f0887f0db..e340215fe 100644 --- a/src/device/usbd.h +++ b/src/device/usbd.h @@ -41,6 +41,9 @@ // Application API //--------------------------------------------------------------------+ +// Init device stack +bool tud_init (void); + // Task function should be called in main/rtos loop void tud_task (void); diff --git a/src/device/usbd_pvt.h b/src/device/usbd_pvt.h index 892680142..b9947044b 100644 --- a/src/device/usbd_pvt.h +++ b/src/device/usbd_pvt.h @@ -33,8 +33,6 @@ extern "C" { #endif -bool usbd_init (void); - //--------------------------------------------------------------------+ // USBD Endpoint API //--------------------------------------------------------------------+ diff --git a/src/tusb.c b/src/tusb.c index 271b35f1e..7a1e73ec7 100644 --- a/src/tusb.c +++ b/src/tusb.c @@ -47,7 +47,7 @@ bool tusb_init(void) #endif #if TUSB_OPT_DEVICE_ENABLED - TU_ASSERT ( usbd_init() ); // init device stack + TU_ASSERT ( tud_init() ); // init device stack #endif _initialized = true;