summaryrefslogtreecommitdiff
path: root/src/class/cdc
diff options
context:
space:
mode:
authorhathach <[email protected]>2018-07-23 15:25:45 +0700
committerhathach <[email protected]>2018-07-23 15:25:45 +0700
commit4342325ee1359d3361acca6de4f8accf013e8e39 (patch)
treec869f399e0ef1f8588842a8927a22e528dadc503 /src/class/cdc
parent141ac25e3b3aaf72a50ace257d2bda41d1ebe702 (diff)
reworking device hid class driver
Diffstat (limited to 'src/class/cdc')
-rw-r--r--src/class/cdc/cdc_device.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/class/cdc/cdc_device.c b/src/class/cdc/cdc_device.c
index 8848ddca0..bbf1c8ceb 100644
--- a/src/class/cdc/cdc_device.c
+++ b/src/class/cdc/cdc_device.c
@@ -38,7 +38,7 @@
#include "tusb_option.h"
-#if (MODE_DEVICE_SUPPORTED && CFG_TUD_CDC)
+#if (TUSB_OPT_DEVICE_ENABLED && CFG_TUD_CDC)
#define _TINY_USB_SOURCE_FILE_
//--------------------------------------------------------------------+
@@ -157,13 +157,13 @@ uint32_t tud_cdc_n_write(uint8_t itf, void const* buffer, uint32_t bufsize)
bool tud_cdc_n_write_flush (uint8_t itf)
{
cdcd_interface_t* p_cdc = &_cdcd_itf[itf];
- VERIFY( !dcd_edpt_busy(TUD_RHPORT, p_cdc->ep_in) ); // skip if previous transfer not complete
+ VERIFY( !dcd_edpt_busy(TUD_OPT_RHPORT, p_cdc->ep_in) ); // skip if previous transfer not complete
uint16_t count = tu_fifo_read_n(&_cdcd_itf[itf].tx_ff, p_cdc->epout_buf, CFG_TUD_CDC_EPSIZE);
VERIFY( tud_cdc_n_connected(itf) ); // fifo is empty if not connected
- if ( count ) TU_ASSERT( dcd_edpt_xfer(TUD_RHPORT, p_cdc->ep_in, p_cdc->epout_buf, count) );
+ if ( count ) TU_ASSERT( dcd_edpt_xfer(TUD_OPT_RHPORT, p_cdc->ep_in, p_cdc->epout_buf, count) );
return true;
}