mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-03-28 16:52:33 +01:00
Compare commits
11 Commits
V3.2.1
...
backBefore
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c80b565730 | ||
|
|
84cbcc30e8 | ||
|
|
11d413cb17 | ||
|
|
19d767e3cb | ||
|
|
803bde1008 | ||
|
|
8ab1f5ec24 | ||
|
|
cfc9474469 | ||
|
|
949807bc14 | ||
|
|
35760b74f7 | ||
|
|
b5690a2f37 | ||
|
|
b448e2fc6b |
@@ -23,20 +23,20 @@ build_flags =
|
||||
-D RADIOLIB_EXCLUDE_SSTV=1
|
||||
-I variants/${PIOENV}
|
||||
lib_deps =
|
||||
adafruit/Adafruit Unified Sensor @ 1.1.14
|
||||
adafruit/Adafruit AHTX0 @ 2.0.5
|
||||
adafruit/Adafruit BME280 Library @ 2.2.4
|
||||
adafruit/Adafruit BMP280 Library @ 2.6.8
|
||||
adafruit/Adafruit BME680 Library @ 2.0.4
|
||||
adafruit/Adafruit Unified Sensor @ 1.1.15
|
||||
adafruit/Adafruit AHTX0 @ 2.0.6
|
||||
adafruit/Adafruit BME280 Library @ 2.3.0
|
||||
adafruit/Adafruit BMP280 Library @ 3.0.0
|
||||
adafruit/Adafruit BME680 Library @ 2.0.6
|
||||
adafruit/Adafruit INA219 @ 1.2.3
|
||||
adafruit/Adafruit Si7021 Library @ 1.5.3
|
||||
arduino-libraries/NTPClient @ 3.2.1
|
||||
ayushsharma82/ElegantOTA @ 3.1.7
|
||||
bblanchon/ArduinoJson @ 6.21.3
|
||||
jgromes/RadioLib @ 7.1.0
|
||||
jgromes/RadioLib @ 7.6.0
|
||||
knolleary/PubSubClient @ 2.8
|
||||
ESP32Async/AsyncTCP @ 3.4.9
|
||||
ESP32Async/ESPAsyncWebServer @ 3.9.3
|
||||
ESP32Async/AsyncTCP @ 3.4.10
|
||||
ESP32Async/ESPAsyncWebServer @ 3.10.0
|
||||
mikalhart/TinyGPSPlus @ 1.0.3
|
||||
richonguzman/APRSPacketLib @ 1.0.4
|
||||
display_libs =
|
||||
@@ -44,4 +44,4 @@ display_libs =
|
||||
adafruit/Adafruit SSD1306 @ 2.5.10
|
||||
usb_flags=
|
||||
-DARDUINO_USB_MODE=1
|
||||
-DARDUINO_USB_CDC_ON_BOOT=1
|
||||
-DARDUINO_USB_CDC_ON_BOOT=1
|
||||
@@ -195,13 +195,13 @@ public:
|
||||
REMOTE_MANAGEMENT remoteManagement;
|
||||
MQTT mqtt;
|
||||
|
||||
void setup();
|
||||
void setDefaultValues();
|
||||
bool writeFile();
|
||||
Configuration();
|
||||
|
||||
private:
|
||||
bool readFile();
|
||||
String _filePath;
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace POWER_Utils {
|
||||
void vext_ctrl_OFF();
|
||||
#endif
|
||||
|
||||
#ifdef ADC_CTRL
|
||||
#ifdef ADC_CTRL_PIN
|
||||
void adc_ctrl_ON();
|
||||
void adc_ctrl_OFF();
|
||||
#endif
|
||||
|
||||
@@ -16,7 +16,7 @@ extra_configs =
|
||||
variants/*/platformio.ini
|
||||
|
||||
[env]
|
||||
platform = espressif32 @ 6.7.0
|
||||
platform = espressif32 @ 6.12.0
|
||||
board_build.partitions = min_spiffs.csv
|
||||
framework = arduino
|
||||
monitor_speed = 115200
|
||||
|
||||
@@ -67,8 +67,8 @@ ___________________________________________________________________*/
|
||||
#endif
|
||||
|
||||
|
||||
String versionDate = "2026-03-04";
|
||||
String versionNumber = "3.2.1";
|
||||
String versionDate = "2026-03-08";
|
||||
String versionNumber = "3.2.101";
|
||||
Configuration Config;
|
||||
WiFiClient aprsIsClient;
|
||||
WiFiClient mqttClient;
|
||||
@@ -101,6 +101,7 @@ String firstLine, secondLine, thirdLine, fourthLine, fifthLine, sixthLine, seven
|
||||
|
||||
void setup() {
|
||||
Serial.begin(115200);
|
||||
Config.setup();
|
||||
POWER_Utils::setup();
|
||||
Utils::setupDisplay();
|
||||
LoRa_Utils::setup();
|
||||
@@ -216,4 +217,4 @@ void loop() {
|
||||
Utils::checkRebootTime();
|
||||
Utils::checkSleepByLowBatteryVoltage(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -154,7 +154,7 @@ namespace BATTERY_Utils {
|
||||
}
|
||||
#else
|
||||
|
||||
#ifdef ADC_CTRL
|
||||
#ifdef ADC_CTRL_PIN
|
||||
POWER_Utils::adc_ctrl_ON();
|
||||
#endif
|
||||
|
||||
@@ -180,7 +180,7 @@ namespace BATTERY_Utils {
|
||||
delay(3);
|
||||
}
|
||||
|
||||
#ifdef ADC_CTRL
|
||||
#ifdef ADC_CTRL_PIN
|
||||
POWER_Utils::adc_ctrl_OFF();
|
||||
|
||||
#ifdef HELTEC_WP_V1
|
||||
|
||||
@@ -25,11 +25,29 @@
|
||||
|
||||
bool shouldSleepStop = true;
|
||||
|
||||
void Configuration::setup() {
|
||||
if (!SPIFFS.begin(false)) {
|
||||
Serial.println("SPIFFS Mount Failed");
|
||||
return;
|
||||
} else {
|
||||
Serial.println("SPIFFS Mounted");
|
||||
}
|
||||
|
||||
bool exists = SPIFFS.exists("/igate_conf.json");
|
||||
if (!exists) {
|
||||
setDefaultValues();
|
||||
writeFile();
|
||||
delay(1000);
|
||||
ESP.restart();
|
||||
}
|
||||
|
||||
readFile();
|
||||
}
|
||||
|
||||
bool Configuration::writeFile() {
|
||||
Serial.println("Saving configuration...");
|
||||
|
||||
StaticJsonDocument<3584> data;
|
||||
DynamicJsonDocument data(3584);
|
||||
File configFile = SPIFFS.open("/igate_conf.json", "w");
|
||||
|
||||
if (!configFile) {
|
||||
@@ -558,22 +576,3 @@ void Configuration::setDefaultValues() {
|
||||
|
||||
Serial.println("New Data Created... All is Written!");
|
||||
}
|
||||
|
||||
Configuration::Configuration() {
|
||||
if (!SPIFFS.begin(false)) {
|
||||
Serial.println("SPIFFS Mount Failed");
|
||||
return;
|
||||
} else {
|
||||
Serial.println("SPIFFS Mounted");
|
||||
}
|
||||
|
||||
bool exists = SPIFFS.exists("/igate_conf.json");
|
||||
if (!exists) {
|
||||
setDefaultValues();
|
||||
writeFile();
|
||||
delay(1000);
|
||||
ESP.restart();
|
||||
}
|
||||
|
||||
readFile();
|
||||
}
|
||||
@@ -272,8 +272,8 @@ namespace POWER_Utils {
|
||||
if (Config.beacon.gpsActive && Config.digi.ecoMode != 1) activateGPS();
|
||||
#endif
|
||||
|
||||
#ifdef ADC_CTRL
|
||||
pinMode(ADC_CTRL, OUTPUT);
|
||||
#ifdef ADC_CTRL_PIN
|
||||
pinMode(ADC_CTRL_PIN, OUTPUT);
|
||||
adc_ctrl_OFF();
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user