Skip to content

Commit

Permalink
use tuh_task_ext()
Browse files Browse the repository at this point in the history
  • Loading branch information
hathach committed Oct 27, 2023
1 parent 9a83b0b commit 2c80ef1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/arduino/Adafruit_USBH_Host.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,9 @@ bool Adafruit_USBH_Host::begin(uint8_t rhport) {
return tuh_init(rhport);
}

void Adafruit_USBH_Host::task(void) { tuh_task(); }
void Adafruit_USBH_Host::task(uint32_t timeout_ms, bool in_isr) {
tuh_task_ext(timeout_ms, in_isr);
}

// Invoked when device with hid interface is mounted
// Report descriptor is also available for use.
Expand Down
2 changes: 1 addition & 1 deletion src/arduino/Adafruit_USBH_Host.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ class Adafruit_USBH_Host {
#endif

bool begin(uint8_t rhport);
void task(void);
void task(uint32_t timeout_ms = UINT32_MAX, bool in_isr = false);

//------------- internal usage -------------//
static Adafruit_USBH_Host *_instance;
Expand Down

0 comments on commit 2c80ef1

Please sign in to comment.