From cd00d5fdb05d07aba78c890ffa5ce708275a0c47 Mon Sep 17 00:00:00 2001 From: Cristian Maglie <c.maglie@arduino.cc> Date: Fri, 13 Mar 2015 13:22:58 +0100 Subject: [PATCH] Revert " updated validation test for usb_device" This reverts commit 5024bce531bfeb6f70844f76ea09d7e7de31a067. --- .../validation_usb_device/test_usb_device.cpp | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/cores/validation/validation_usb_device/test_usb_device.cpp b/cores/validation/validation_usb_device/test_usb_device.cpp index e69c7193..ddc3060e 100644 --- a/cores/validation/validation_usb_device/test_usb_device.cpp +++ b/cores/validation/validation_usb_device/test_usb_device.cpp @@ -27,10 +27,6 @@ void setup(void) { - SERIAL_PORT_MONITOR.begin( 115200 ); - while (!SERIAL_PORT_MONITOR); // Wait for serial port to connect - used on Leonardo, Teensy and other boards with built-in USB CDC serial connection - SERIAL_PORT_MONITOR.println("Start USB device test"); - #ifdef HID_ENABLED Mouse.begin(); @@ -41,11 +37,11 @@ void setup(void) #endif #ifdef CDC_ENABLED - SERIAL_PORT_USBVIRTUAL.begin(115200); + SerialUSB.begin(115200); #endif } -char testchar[10]; + void loop(void) { #ifdef HID_ENABLED @@ -68,14 +64,11 @@ void loop(void) #endif #ifdef CDC_ENABLED - if (SERIAL_PORT_USBVIRTUAL.available() > 0) + if (SerialUSB.available() > 0) { char inChar; - - //while( -1 == (inChar = SERIAL_PORT_USBVIRTUAL.read())); - inChar = SERIAL_PORT_USBVIRTUAL.read(); - - SERIAL_PORT_USBVIRTUAL.print(inChar); + while( -1 == (inChar = SerialUSB.read())); + SerialUSB.print(inChar); } delay(10); -- GitLab