commit
539d22a5e3
|
@ -37,7 +37,11 @@ The symbol can now be changed without attached display - during normal operation
|
||||||
for DHT22 I used the library from https://github.com/beegee-tokyo/DHTesp, as the standard library gives to many wrong readings<br>
|
for DHT22 I used the library from https://github.com/beegee-tokyo/DHTesp, as the standard library gives to many wrong readings<br>
|
||||||
Now the DS18B20 is supported as well - uncomment line 31: // #define DS18B20 // use this if you use DS18B20, default ist DHT22<br>
|
Now the DS18B20 is supported as well - uncomment line 31: // #define DS18B20 // use this if you use DS18B20, default ist DHT22<br>
|
||||||
<br>
|
<br>
|
||||||
new features:<br>
|
<b>show RX packets</b><br>
|
||||||
|
by uncommenting <b>// #define SHOW_RX_PACKET</b> the tracker shows received LoRa APRS packets in raw format for the time in milliseconds defined in SHOW_RX_TIME - both in ...config.h<br>
|
||||||
|
<br>
|
||||||
|
<b>new features:<b><br>
|
||||||
|
- show RX packets
|
||||||
- DS18B20 support (setable in config.h)
|
- DS18B20 support (setable in config.h)
|
||||||
- GPS switched off in WX_FIXED mode (only available with boards with HW-Version >=V1.0)
|
- GPS switched off in WX_FIXED mode (only available with boards with HW-Version >=V1.0)
|
||||||
- immediate TX with short key press
|
- immediate TX with short key press
|
||||||
|
|
|
@ -8,12 +8,23 @@
|
||||||
; Please visit documentation for the other options and examples
|
; Please visit documentation for the other options and examples
|
||||||
; https://docs.platformio.org/page/projectconf.html
|
; https://docs.platformio.org/page/projectconf.html
|
||||||
|
|
||||||
[env:heltec_wifi_lora_32]
|
;[env:heltec_wifi_lora_32]
|
||||||
|
[env:ttgo-t-beam]
|
||||||
platform = espressif32
|
platform = espressif32
|
||||||
board = heltec_wifi_lora_32
|
;board = heltec_wifi_lora_32
|
||||||
|
board = ttgo-t-beam
|
||||||
framework = arduino
|
framework = arduino
|
||||||
|
|
||||||
; Custom Serial Monitor speed (baud rate)
|
; Custom Serial Monitor speed (baud rate)
|
||||||
monitor_speed = 115200
|
monitor_speed = 115200
|
||||||
|
|
||||||
; lib_deps = Adafruit GFX Library@1.6.1, Adafruit Unified Sensor@1.0.3, Adafruit SSD1306@2.0.2, AXP202X_Library@1.0.1, DallasTemperature@3.8.0, DHT sensor library for ESPx@1.17, OneWire@2.3.5, TinyGPSPlus@1.0.2
|
lib_deps =
|
||||||
|
RadioHead
|
||||||
|
TinyGPSPlus
|
||||||
|
DHT sensor library for ESPx
|
||||||
|
Adafruit SSD1306
|
||||||
|
Adafruit GFX Library
|
||||||
|
Adafruit Unified Sensor
|
||||||
|
AXP202X_Library
|
||||||
|
OneWire
|
||||||
|
DallasTemperature
|
||||||
|
|
|
@ -181,6 +181,7 @@ boolean wx;
|
||||||
|
|
||||||
//byte arrays
|
//byte arrays
|
||||||
byte lora_TXBUFF[128]; //buffer for packet to send
|
byte lora_TXBUFF[128]; //buffer for packet to send
|
||||||
|
byte lora_RXBUFF[128]; //buffer for packet to send
|
||||||
//byte Variables
|
//byte Variables
|
||||||
byte lora_TXStart; //start of packet data in TXbuff
|
byte lora_TXStart; //start of packet data in TXbuff
|
||||||
byte lora_TXEnd; //end of packet data in TXbuff
|
byte lora_TXEnd; //end of packet data in TXbuff
|
||||||
|
@ -436,7 +437,7 @@ void setup()
|
||||||
void loop() {
|
void loop() {
|
||||||
if (digitalRead(BUTTON)==LOW) {
|
if (digitalRead(BUTTON)==LOW) {
|
||||||
++button_ctr;
|
++button_ctr;
|
||||||
if (button_ctr>=5){
|
if (button_ctr>=5) {
|
||||||
switch(tracker_mode) {
|
switch(tracker_mode) {
|
||||||
case TRACKER:
|
case TRACKER:
|
||||||
tracker_mode = WX_TRACKER;
|
tracker_mode = WX_TRACKER;
|
||||||
|
@ -480,7 +481,7 @@ void loop() {
|
||||||
button_ctr = 0;
|
button_ctr = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hum_temp) {
|
if (hum_temp) {
|
||||||
hum_temp=false;
|
hum_temp=false;
|
||||||
#ifdef DS18B20
|
#ifdef DS18B20
|
||||||
sensors.requestTemperatures(); // Send the command to get temperature readings
|
sensors.requestTemperatures(); // Send the command to get temperature readings
|
||||||
|
@ -504,8 +505,18 @@ void loop() {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rf95.waitAvailableTimeout(100)) {
|
if (rf95.waitAvailableTimeout(100)) {
|
||||||
if (rf95.recvAPRS(buf, &len)) {
|
#ifdef SHOW_RX_PACKET // only show RX packets when activitated in config
|
||||||
|
if (rf95.recvAPRS(lora_RXBUFF, &len)) {
|
||||||
|
Serial.print("((RX)): ");
|
||||||
|
InputString = "";
|
||||||
|
for ( int i=0 ; i < len ; i++) {
|
||||||
|
InputString += (char) lora_RXBUFF[i];
|
||||||
|
}
|
||||||
|
Serial.println(InputString);
|
||||||
|
blinker(3);
|
||||||
|
writedisplaytext(" ((RX))","",InputString,"","","",SHOW_RX_TIME);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tracker_mode != WX_FIXED) {
|
if (tracker_mode != WX_FIXED) {
|
||||||
|
|
|
@ -48,3 +48,7 @@
|
||||||
// TRANSMIT INTERVAL
|
// TRANSMIT INTERVAL
|
||||||
unsigned long max_time_to_nextTX = 300000L; // set here MAXIMUM time in ms(!) for smart beaconing - minimum time is always 1 min = 60 secs = 60000L !!!
|
unsigned long max_time_to_nextTX = 300000L; // set here MAXIMUM time in ms(!) for smart beaconing - minimum time is always 1 min = 60 secs = 60000L !!!
|
||||||
// when entering 60000L intervall is fixed to 1 min
|
// when entering 60000L intervall is fixed to 1 min
|
||||||
|
|
||||||
|
// show RX values
|
||||||
|
// #define SHOW_RX_PACKET // uncomment to show received LoRa APS packets for the time given below
|
||||||
|
#define SHOW_RX_TIME 5000 // show RX packet for milliseconds (5000 = 5secs)
|
||||||
|
|
Ładowanie…
Reference in New Issue