Skip to content

Commit 58fa264

Browse files
authored
Merge pull request #3 from Open-Things-Network/Obudowa
Added resetting after every boot.
2 parents 90f63be + fdd928d commit 58fa264

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

projects/weather-station/weather-station.ino

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#define VBAT (analogRead(A0) * 0.013) // napięcie z baterii mierzone na wejściu A0 (dzielnik R4, R5 i VREF = 3.3V)
1515

1616
#define DS18_TEMPERATURE_CHANNEL 11
17-
17+
#define RN_RESET_PIN 4
1818
#define debugSerial Serial
1919
SoftwareSerial loraSerial(6, 7); // port do komunikacji z RN2483 (RX, TX)
2020

@@ -146,6 +146,8 @@ void setup()
146146
// uruchomienie komunikacji z RN2483
147147
loraSerial.begin(9600);
148148
ttn.wake();
149+
ttn.resetHard(RN_RESET_PIN);
150+
ttn.reset(false);
149151
ttn.onMessage(message);
150152

151153
// odczyt i wyświetlanie informacji z RN2483

0 commit comments

Comments
 (0)