File tree Expand file tree Collapse file tree 11 files changed +37
-21
lines changed Expand file tree Collapse file tree 11 files changed +37
-21
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ install:
14
14
- arduino --install-library "DHT sensor library:1.3.0,Adafruit Unified Sensor:1.0.2"
15
15
before_script :
16
16
# Replace placeholders with actual frequency plan (on Mac OS folow -i by '')
17
- - find $PWD/examples -type f -name "*.ino" -exec sed -i 's/\(freqPlan = \)/\1TTN_FP_EU868; /g' {} +
17
+ - find $PWD/examples -type f -name "*.ino" -exec sed -i 's/REPLACE_ME/TTN_FP_EU868 /g' {} +
18
18
script :
19
19
- arduino --verify --board arduino:avr:leonardo $PWD/examples/ABP/ABP.ino
20
20
- arduino --verify --board arduino:avr:leonardo $PWD/examples/DeviceInfo/DeviceInfo.ino
Original file line number Diff line number Diff line change 4
4
const char *devAddr = " 00000000" ;
5
5
const char *nwkSKey = " 00000000000000000000000000000000" ;
6
6
const char *appSKey = " 00000000000000000000000000000000" ;
7
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
8
7
9
8
#define loraSerial Serial1
10
9
#define debugSerial Serial
11
10
11
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
12
+ #define freqPlan REPLACE_ME
13
+
12
14
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
13
15
14
16
void setup () {
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
3
- // Set the frequency plan
4
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
5
-
6
3
#define loraSerial Serial1
7
4
#define debugSerial Serial
8
5
6
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
7
+ #define freqPlan REPLACE_ME
8
+
9
9
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
10
10
11
11
void setup ()
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
#include < TheThingsMessage.h>
3
3
4
- // Set your AppEUI, AppKey and the frequency plan
4
+ // Set your AppEUI and AppKey
5
5
const char *appEui = " 0000000000000000" ;
6
6
const char *appKey = " 00000000000000000000000000000000" ;
7
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
8
7
9
8
#define loraSerial Serial1
10
9
#define debugSerial Serial
11
10
11
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
12
+ #define freqPlan REPLACE_ME
13
+
12
14
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
13
15
14
16
sensordata_t sensorData = api_SensorData_init_default;
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
#include < TheThingsMessage.h>
3
3
4
- // Set your AppEUI, AppKey and the frequency plan
4
+ // Set your AppEUI and AppKey
5
5
const char *appEui = " 0000000000000000" ;
6
6
const char *appKey = " 00000000000000000000000000000000" ;
7
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
8
7
9
8
#define loraSerial Serial1
10
9
#define debugSerial Serial
11
10
11
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
12
+ #define freqPlan REPLACE_ME
13
+
12
14
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
13
15
14
16
sensordata_t data = api_SensorData_init_default;
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
3
- // Set your AppEUI, AppKey and the frequency plan
3
+ // Set your AppEUI and AppKey
4
4
const char *appEui = " 0000000000000000" ;
5
5
const char *appKey = " 00000000000000000000000000000000" ;
6
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
7
6
8
7
#define loraSerial Serial1
9
8
#define debugSerial Serial
10
9
10
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
11
+ #define freqPlan REPLACE_ME
12
+
11
13
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
12
14
13
15
void setup () {
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
3
- // Set your AppEUI, AppKey and the frequency plan
3
+ // Set your AppEUI and AppKey
4
4
const char *appEui = " 0000000000000000" ;
5
5
const char *appKey = " 00000000000000000000000000000000" ;
6
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
7
6
8
7
#define loraSerial Serial1
9
8
#define debugSerial Serial
10
9
10
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
11
+ #define freqPlan REPLACE_ME
12
+
11
13
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
12
14
13
15
void setup () {
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
3
- // Set your AppEUI, AppKey and the frequency plan
3
+ // Set your AppEUI and AppKey
4
4
const char *appEui = " 0000000000000000" ;
5
5
const char *appKey = " 00000000000000000000000000000000" ;
6
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
7
6
8
7
#define loraSerial Serial1
9
8
#define debugSerial Serial
10
9
10
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
11
+ #define freqPlan REPLACE_ME
12
+
11
13
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
12
14
13
15
void setup () {
Original file line number Diff line number Diff line change 3
3
// First install "DHT sensor library" via the Library Manager
4
4
#include < DHT.h>
5
5
6
- // Set your AppEUI, AppKey and the frequency plan
6
+ // Set your AppEUI and AppKey
7
7
const char *appEui = " 0000000000000000" ;
8
8
const char *appKey = " 00000000000000000000000000000000" ;
9
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
10
9
11
10
#define loraSerial Serial1
12
11
#define debugSerial Serial
13
12
13
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
14
+ #define freqPlan REPLACE_ME
15
+
14
16
#define DHTPIN 2
15
17
16
18
// Choose your DHT sensor moddel
Original file line number Diff line number Diff line change 1
1
#include < TheThingsNetwork.h>
2
2
3
- // Set your AppEUI, AppKey and the frequency plan
3
+ // Set your AppEUI and AppKey
4
4
const char *appEui = " 0000000000000000" ;
5
5
const char *appKey = " 00000000000000000000000000000000" ;
6
- const ttn_fp_t freqPlan = // Use either TTN_FP_EU868; or TTN_FP_US915; here
7
6
8
7
// define AnalogPin for sensor
9
8
#define LightPin A0
10
9
11
10
#define loraSerial Serial1
12
11
#define debugSerial Serial
13
12
13
+ // Replace REPLACE_ME with TTN_FP_EU868 or TTN_FP_US915
14
+ #define freqPlan REPLACE_ME
15
+
14
16
TheThingsNetwork ttn (loraSerial, debugSerial, freqPlan);
15
17
16
18
void setup () {
You can’t perform that action at this time.
0 commit comments