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-Custom MTS-Serial
Fork of mDot_AT_firmware_CUSTOM by
To change channel plans replace AS923 with AU915, EU868, KR920 or US915 on line 15
#define CHANNEL_PLAN CP_AS923
Diff: main.cpp
- Revision:
- 17:17963e6bd07d
- Parent:
- 15:36db31c18231
- Child:
- 18:4e02a7a01625
--- a/main.cpp Wed Aug 31 11:59:44 2016 -0500 +++ b/main.cpp Sat Sep 17 18:03:33 2016 +0000 @@ -4,6 +4,7 @@ #include "ATSerial.h" #include "ATSerialFlowControl.h" #include "CustomChannelPlan_EU868.h" +#include "CustomChannelPlan_US915.h" #define SERIAL_BUFFER_SIZE 512 @@ -17,7 +18,7 @@ mDot* dot = mDot::getInstance(); - lora::CustomChannelPlan_EU868* plan = new lora::CustomChannelPlan_EU868(*dot->getRadio(), *dot->getSettings()); + lora::CustomChannelPlan_US915* plan = new lora::CustomChannelPlan_US915(*dot->getRadio(), *dot->getSettings()); dot->setChannelPlan(plan); // Seed the RNG @@ -26,17 +27,17 @@ mts::ATSerial* serial; if (dot->getFlowControl()) -#if defined(TARGET_MTS_MDOT_F411RE) +#if defined(TARGET_MTS_MDOT_F411RE) serial = new mts::ATSerialFlowControl(XBEE_DOUT, XBEE_DIN, XBEE_RTS, XBEE_CTS, SERIAL_BUFFER_SIZE, SERIAL_BUFFER_SIZE); -#else +#else serial = new mts::ATSerialFlowControl(UART1_TX, UART1_RX, UART1_RTS, UART1_CTS, SERIAL_BUFFER_SIZE, SERIAL_BUFFER_SIZE); -#endif +#endif else -#if defined(TARGET_MTS_MDOT_F411RE) +#if defined(TARGET_MTS_MDOT_F411RE) serial = new mts::ATSerial(XBEE_DOUT, XBEE_DIN, SERIAL_BUFFER_SIZE, SERIAL_BUFFER_SIZE); -#else +#else serial = new mts::ATSerial(UART1_TX, UART1_RX, SERIAL_BUFFER_SIZE, SERIAL_BUFFER_SIZE); -#endif +#endif debug.baud(dot->getDebugBaud()); serial->baud(dot->getBaud()); @@ -52,4 +53,4 @@ } #endif // UNIT_TEST - +