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: libmDot-mbed5 ISL29011
Diff: examples/src/ota_example.cpp
- Revision:
- 45:0d541f98d058
- Parent:
- 44:89b8ed62c32c
diff -r 89b8ed62c32c -r 0d541f98d058 examples/src/ota_example.cpp
--- a/examples/src/ota_example.cpp Wed Nov 11 00:27:58 2020 +0000
+++ b/examples/src/ota_example.cpp Wed Nov 11 00:38:59 2020 +0000
@@ -51,7 +51,7 @@
mDot* dot = NULL;
lora::ChannelPlan* plan = NULL;
-BufferedSerial pc(USBTX, USBRX);
+Serial pc(USBTX, USBRX);
// Initialize I2C
const int addr7bit = 0x40; // 7 bit I2C address
@@ -86,7 +86,7 @@
RadioEvent events;
- pc.set_baud(115200);
+ pc.baud(115200);
i2c.frequency(400000);
mts::MTSLog::setLogLevel(mts::MTSLog::TRACE_LEVEL);
@@ -264,7 +264,7 @@
send_data(tx_data);
// Send to sleep for desired time.
- ThisThread::sleep_for(uplinkInterval * 60s); // seconds
+ ThisThread::sleep_for(uplinkInterval * 60000); // seconds
}
return 0;