Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: max32625pico maxim-dev mbed-rtos USBDevice
Fork of PICO_USB_I2C_SPI by
Diff: main.cpp
- Revision:
- 7:5de026dd3a82
- Parent:
- 6:bff339370df6
- Child:
- 8:9b85634550c7
diff -r bff339370df6 -r 5de026dd3a82 main.cpp
--- a/main.cpp Thu Dec 08 21:44:01 2016 +0000
+++ b/main.cpp Tue Dec 13 21:30:06 2016 +0000
@@ -8,7 +8,10 @@
#define USB_MAX_RESP_LENGTH 255
#define USB_MAX_CMD_LENGTH 255
-MAX32630FTHR pegasus(MAX32630FTHR::VIO_3V3);
+MAX32630FTHR pegasus;
+
+// Virtual serial port over USB
+USBSerial microUSB;
// Serial Interface Adapter
SerialInterface serInt;
@@ -28,8 +31,6 @@
void usb_thread()
{
-// Virtual serial port over USB
- USBSerial microUSB;
char obuf[USB_MAX_RESP_LENGTH+1];
char ibuf[USB_MAX_CMD_LENGTH+1];
int i = 0;
@@ -103,7 +104,7 @@
bLED = LED_OFF;
// Board Initialization
- pegasus.init();
+ pegasus.init(MAX32630FTHR::VIO_3V3);
// Serial Interface Setup
serInt.init(&i2c, &spi, &ssel);
