summaryrefslogtreecommitdiff
path: root/src/class/cdc
diff options
context:
space:
mode:
authorWini-Buh <[email protected]>2021-06-11 22:36:17 +0200
committerWini-Buh <[email protected]>2021-06-11 22:36:17 +0200
commit60d8ecbfe617b0f398f90c3fede9a9488f4da407 (patch)
tree30484f43a2e94b8bd6ce6301377a32036950f625 /src/class/cdc
parent1c23462b43f47685cf0051568f4bfea5de37d563 (diff)
parentb34724215bea28ef93fd80ed9c2e4ddc87874093 (diff)
clean up
Diffstat (limited to 'src/class/cdc')
-rw-r--r--src/class/cdc/cdc_host.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/class/cdc/cdc_host.c b/src/class/cdc/cdc_host.c
index facf86d56..33f1a8ad3 100644
--- a/src/class/cdc/cdc_host.c
+++ b/src/class/cdc/cdc_host.c
@@ -29,6 +29,8 @@
#if (TUSB_OPT_HOST_ENABLED && CFG_TUH_CDC)
#include "host/usbh.h"
+#include "host/usbh_classdriver.h"
+
#include "cdc_host.h"
//--------------------------------------------------------------------+
@@ -71,13 +73,13 @@ bool tuh_cdc_is_busy(uint8_t dev_addr, cdc_pipeid_t pipeid)
switch (pipeid)
{
case CDC_PIPE_NOTIFICATION:
- return hcd_edpt_busy(dev_addr, p_cdc->ep_notif );
+ return usbh_edpt_busy(dev_addr, p_cdc->ep_notif );
case CDC_PIPE_DATA_IN:
- return hcd_edpt_busy(dev_addr, p_cdc->ep_in );
+ return usbh_edpt_busy(dev_addr, p_cdc->ep_in );
case CDC_PIPE_DATA_OUT:
- return hcd_edpt_busy(dev_addr, p_cdc->ep_out );
+ return usbh_edpt_busy(dev_addr, p_cdc->ep_out );
default:
return false;
@@ -101,7 +103,7 @@ bool tuh_cdc_send(uint8_t dev_addr, void const * p_data, uint32_t length, bool i
TU_VERIFY( p_data != NULL && length, TUSB_ERROR_INVALID_PARA);
uint8_t const ep_out = cdch_data[dev_addr-1].ep_out;
- if ( hcd_edpt_busy(dev_addr, ep_out) ) return false;
+ if ( usbh_edpt_busy(dev_addr, ep_out) ) return false;
return usbh_edpt_xfer(dev_addr, ep_out, (void *) p_data, length);
}
@@ -113,7 +115,7 @@ bool tuh_cdc_receive(uint8_t dev_addr, void * p_buffer, uint32_t length, bool is
TU_VERIFY( p_buffer != NULL && length, TUSB_ERROR_INVALID_PARA);
uint8_t const ep_in = cdch_data[dev_addr-1].ep_in;
- if ( hcd_edpt_busy(dev_addr, ep_in) ) return false;
+ if ( usbh_edpt_busy(dev_addr, ep_in) ) return false;
return usbh_edpt_xfer(dev_addr, ep_in, p_buffer, length);
}