aboutsummaryrefslogtreecommitdiffstats
path: root/testhal/STM32/STM32F7xx/USB_CDC
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2015-12-26 13:16:24 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2015-12-26 13:16:24 +0000
commitae70b0edcea8b466894e140839371fb122a4aa92 (patch)
tree4c0031bf1e4afddba7d9479ebd055d7a6d16ae64 /testhal/STM32/STM32F7xx/USB_CDC
parent672c4381f55bb8d7fd7ff902dae116c5b9b72373 (diff)
downloadChibiOS-ae70b0edcea8b466894e140839371fb122a4aa92.tar.gz
ChibiOS-ae70b0edcea8b466894e140839371fb122a4aa92.tar.bz2
ChibiOS-ae70b0edcea8b466894e140839371fb122a4aa92.zip
Fixed bug #686.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8647 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'testhal/STM32/STM32F7xx/USB_CDC')
-rw-r--r--testhal/STM32/STM32F7xx/USB_CDC/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/testhal/STM32/STM32F7xx/USB_CDC/main.c b/testhal/STM32/STM32F7xx/USB_CDC/main.c
index 4a15108d7..16b298bc1 100644
--- a/testhal/STM32/STM32F7xx/USB_CDC/main.c
+++ b/testhal/STM32/STM32F7xx/USB_CDC/main.c
@@ -113,11 +113,11 @@ static void cmd_write(BaseSequentialStream *chp, int argc, char *argv[]) {
while (chnGetTimeout((BaseChannel *)chp, TIME_IMMEDIATE) == Q_TIMEOUT) {
#if 1
/* Writing in channel mode.*/
- chnWrite(&SDU1, buf, sizeof buf - 1);
+ chnWrite(&SDU2, buf, sizeof buf - 1);
#else
/* Writing in buffer mode.*/
(void) obqGetEmptyBufferTimeout(&SDU1.obqueue, TIME_INFINITE);
- memcpy(SDU1.obqueue.ptr, buf, SERIAL_USB_BUFFERS_SIZE);
+ memcpy(SDU2.obqueue.ptr, buf, SERIAL_USB_BUFFERS_SIZE);
obqPostFullBuffer(&SDU1.obqueue, SERIAL_USB_BUFFERS_SIZE);
#endif
}