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.
Ping-Pong demo application using FHSS (Frequency Hoping Spread Spectrum) between two SX1276MB1xAs demo board.
Application demonstrating simple Tx/Rx between two boards. By default, each board starts as a "master" and will transmit a "Ping" message, and then wait for an answer. The first board receiving a "Ping" message will become a slave and answer the "master" with a "Pong". The Ping-Pong is then started...
Diff: main.cpp
- Revision:
- 1:41b10c760ff2
- Parent:
- 0:db48addeabda
- Child:
- 2:b03bdfedfafa
diff -r db48addeabda -r 41b10c760ff2 main.cpp
--- a/main.cpp Fri Sep 19 15:25:35 2014 +0000
+++ b/main.cpp Tue Sep 23 14:25:25 2014 +0000
@@ -1,6 +1,6 @@
#include "mbed.h"
+#include "sx1276-hal.h"
#include "main.h"
-#include "sx1276-hal.h"
#include "mbed_debug.h"
/* Set this flag to '1' to display debug messages on the console */
@@ -47,7 +47,7 @@
#error "Please define a modem in the compiler options."
#endif
-#define RX_TIMEOUT_VALUE 3000000 // in us
+#define RX_TIMEOUT_VALUE 4000000 // in us
#define BUFFER_SIZE 32 // Define the payload size here
#if( defined ( TARGET_KL25Z ) )
@@ -361,5 +361,5 @@
void OnFhssChangeChannel( uint8_t channelIndex )
{
Radio.SetChannel( HoppingFrequencies[channelIndex] );
- debug_if( DEBUG_MESSAGE, "-"/*"%d"*/, channelIndex);
+ debug_if( DEBUG_MESSAGE, "F%d-", channelIndex);
}