summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorhathach <[email protected]>2018-03-11 19:45:13 +0700
committerhathach <[email protected]>2018-03-11 19:45:13 +0700
commite29409d4c833a5004d68f6e4721d2469968dd9a5 (patch)
treeaefbb0f2d4c16ae1488596baa90cffbdbf905afa /examples
parentf5260610d3ed56ae61401617f611ec4b94b4c5ee (diff)
clean up
Diffstat (limited to 'examples')
-rw-r--r--examples/device/nrf52840/src/main.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/device/nrf52840/src/main.c b/examples/device/nrf52840/src/main.c
index f48ade9df..65a21ff77 100644
--- a/examples/device/nrf52840/src/main.c
+++ b/examples/device/nrf52840/src/main.c
@@ -79,14 +79,14 @@ int main(void)
void virtual_com_task(void)
{
// connected and there are data available
- if ( tud_mounted(0) && tud_cdc_available(0) )
+ if ( tud_mounted() && tud_cdc_available() )
{
uint8_t buf[64];
// read and echo back
- uint32_t count = tud_cdc_read(0, buf, sizeof(buf));
+ uint32_t count = tud_cdc_read(buf, sizeof(buf));
- tud_cdc_write(0, buf, count);
+ tud_cdc_write(buf, count);
}
}