Commit 6c34d114 authored by Markéta Jedličková's avatar Markéta Jedličková
Browse files

Possibility for changing frequency added into examples

parent 52ff9d49
No preview for this file type
......@@ -23,6 +23,7 @@
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 2 // My node ID (0 to 255)
#define FREQUENCY RF69_433MHZ
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define chip_select_pin 43
#define interupt_pin 9
......@@ -66,6 +67,7 @@ void setup()
}
else
{
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
}
}
......
......@@ -28,6 +28,7 @@
#define MYNODEID 1 // My node ID (0 to 255)
#define TONODEID 2 // Destination node ID (0 to 254, 255 = broadcast)
#define FREQUENCY RF69_433MHZ
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define CHIP_SELECT_PIN 43 //radio chip select
#define INTERUP_PIN 9 //radio interrupt
......@@ -99,6 +100,7 @@ void setup()
if(isRadioOk)
{
Serial.println("High power was set (needed for RFM69HW).");
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
}
......
......@@ -40,6 +40,7 @@ uint8_t screenNum = 1;
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 2 // My node ID (0 to 255)
#define FREQUENCY RF69_433MHZ
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define chip_select_pin 43
#define interupt_pin 9
......@@ -88,6 +89,7 @@ void setup()
}
else
{
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
}
//// RFM69
......
......@@ -37,6 +37,7 @@
#define MYNODEID 1 // My node ID (0 to 255)
#define TONODEID 2 // Destination node ID (0 to 254, 255 = broadcast)
#define FREQUENCY RF69_433MHZ // Frequency set up
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define CHIP_SELECT_PIN 43 //radio chip select
#define INTERUP_PIN 9 //radio interrupt
......@@ -153,6 +154,7 @@ void setup()
}
else
{
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
}
......
......@@ -20,12 +20,13 @@
#define Serial SerialUSB // change default serial to SAMD USB serial
// RFM69
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 2 // My node ID (0 to 255)
#define FREQUENCY RF69_433MHZ
#define CHIP_SELECT_PIN 43 //radio chip select
#define INTERUP_PIN 9 //radio interrupt
#define MS_DELAY 300 // Number of milliseconds between data sending and LED signalization
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 2 // My node ID (0 to 255)
#define FREQUENCY RF69_433MHZ
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define CHIP_SELECT_PIN 43 //radio chip select
#define INTERUP_PIN 9 //radio interrupt
#define MS_DELAY 300 // Number of milliseconds between data sending and LED signalization
// Local
#define PC_BAUDRATE 56700
......@@ -57,6 +58,7 @@ void setup()
// RFM69 initialize
radio.initialize(FREQUENCY, MYNODEID, NETWORKID);
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
Serial.println(); // print new line on serial to make the output look better :-;
......
......@@ -20,13 +20,14 @@
#define Serial SerialUSB // Change default serial to SAMD USB serial
// RFM69
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 1 // My node ID (0 to 255)
#define TONODEID 2 // Destination node ID (0 to 254, 255 = broadcast)
#define FREQUENCY RF69_433MHZ
#define CHIP_SELECT_PIN 43 // Radio chip select
#define INTERUP_PIN 9 // Radio interrupt
#define MS_DELAY 300 // Number of milliseconds between data sending and LED signalization
#define NETWORKID 0 // Must be the same for all nodes (0 to 255)
#define MYNODEID 1 // My node ID (0 to 255)
#define TONODEID 2 // Destination node ID (0 to 254, 255 = broadcast)
#define FREQUENCY RF69_433MHZ
#define FREQUENCYSPECIFIC 433000000 // Should be value in Hz, now 433 Mhz will be set
#define CHIP_SELECT_PIN 43 // Radio chip select
#define INTERUP_PIN 9 // Radio interrupt
#define MS_DELAY 300 // Number of milliseconds between data sending and LED signalization
// Local
#define PC_BAUDRATE 56700
......@@ -58,6 +59,7 @@ void setup()
if(radio.initialize(FREQUENCY, MYNODEID, NETWORKID))
{
radio.setFrequency(FREQUENCYSPECIFIC);
radio.setHighPower(true); // Always use this for RFM69HW
}
else
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment