summaryrefslogtreecommitdiff
path: root/src/class/bth
diff options
context:
space:
mode:
authorHa Thach <[email protected]>2022-06-07 01:13:08 +0700
committerGitHub <[email protected]>2022-06-07 01:13:08 +0700
commita03a03d74eafa33c0cbaa0747db6b09a0e7083bd (patch)
tree3d442c2696e3821058c3262c735f876909900488 /src/class/bth
parentafd9b1883de4d0927433c2286dfc56ed2a5e2203 (diff)
parent7c8278303bc14770ea9fcd9f6e4a9dbba32572e3 (diff)
Merge pull request #1495 from hathach/enhance-tusb-config
Better support multiple controllers configuration
Diffstat (limited to 'src/class/bth')
-rwxr-xr-xsrc/class/bth/bth_device.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/class/bth/bth_device.c b/src/class/bth/bth_device.c
index f40bfbd0d..f96bb3552 100755
--- a/src/class/bth/bth_device.c
+++ b/src/class/bth/bth_device.c
@@ -59,10 +59,12 @@ CFG_TUSB_MEM_SECTION btd_interface_t _btd_itf;
static bool bt_tx_data(uint8_t ep, void *data, uint16_t len)
{
+ uint8_t const rhport = 0;
+
// skip if previous transfer not complete
- TU_VERIFY(!usbd_edpt_busy(TUD_OPT_RHPORT, ep));
+ TU_VERIFY(!usbd_edpt_busy(rhport, ep));
- TU_ASSERT(usbd_edpt_xfer(TUD_OPT_RHPORT, ep, data, len));
+ TU_ASSERT(usbd_edpt_xfer(rhport, ep, data, len));
return true;
}