change usbd_init() return to bool for simplicity

This commit is contained in:
hathach
2018-12-05 17:30:04 +07:00
parent 3dc0653d70
commit d887829b4c
5 changed files with 14 additions and 19 deletions

View File

@@ -101,16 +101,14 @@
/** \ingroup group_application_api
* @{ */
/** \brief Initialize the usb stack
* \return Error Code of the \ref TUSB_ERROR enum
* \note Function will initialize the stack according to configuration in the configure file (tusb_config.h)
*/
tusb_error_t tusb_init(void);
// Initialize device/host stack according to tusb_config.h
// return true if success
bool tusb_init(void);
#if CFG_TUSB_OS == OPT_OS_NONE
/** \brief Run all tinyusb's internal tasks (e.g host task, device task).
* \note This function is only required when using no RTOS (\ref CFG_TUSB_OS == OPT_OS_NONE). All the stack functions
* & callback are invoked within this function, so it should be called periodically within the mainloop
* & callback are invoked within this function. This should be called periodically within the mainloop
*
@code
int main(void)