mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-08-07 01:13:28 +02:00
testing syslog
This commit is contained in:
@@ -182,13 +182,14 @@ void loop() {
|
||||
Utils::checkDisplayInterval();
|
||||
Utils::checkBeaconInterval();
|
||||
|
||||
String packet;
|
||||
|
||||
|
||||
APRS_IS_Utils::checkStatus(); // Need that to update display, maybe split this and send APRSIS status to display func?
|
||||
|
||||
String packet = "";
|
||||
if (Config.loramodule.rxActive) {
|
||||
packet = LoRa_Utils::receivePacket(); // We need to fetch LoRa packet above APRSIS and Digi
|
||||
}
|
||||
|
||||
APRS_IS_Utils::checkStatus(); // Need that to update display, maybe split this and send APRSIS status to display func?
|
||||
}
|
||||
|
||||
if (packet != "") {
|
||||
if (Config.aprs_is.active) { // If APRSIS enabled
|
||||
|
||||
+5
-5
@@ -97,9 +97,9 @@ namespace LoRa_Utils {
|
||||
changeFreqTx();
|
||||
}
|
||||
|
||||
#ifdef HAS_INTERNAL_LED
|
||||
#ifdef HAS_INTERNAL_LED
|
||||
digitalWrite(internalLedPin, HIGH);
|
||||
#endif
|
||||
#endif
|
||||
int state = radio.transmit("\x3c\xff\x01" + newPacket);
|
||||
transmissionFlag = true;
|
||||
if (state == RADIOLIB_ERR_NONE) {
|
||||
@@ -116,9 +116,9 @@ namespace LoRa_Utils {
|
||||
Utils::print(F("failed, code "));
|
||||
Utils::println(String(state));
|
||||
}
|
||||
#ifdef HAS_INTERNAL_LED
|
||||
#ifdef HAS_INTERNAL_LED
|
||||
digitalWrite(internalLedPin, LOW);
|
||||
#endif
|
||||
#endif
|
||||
if (Config.loramodule.txFreq != Config.loramodule.rxFreq) {
|
||||
changeFreqRx();
|
||||
}
|
||||
@@ -169,7 +169,7 @@ namespace LoRa_Utils {
|
||||
freqError = radio.getFrequencyError();
|
||||
Utils::println("<--- LoRa Packet Rx : " + loraPacket);
|
||||
Utils::println("(RSSI:" + String(rssi) + " / SNR:" + String(snr) + " / FreqErr:" + String(freqError) + ")");
|
||||
if (Config.syslog.active && WiFi.status() == WL_CONNECTED && loraPacket != "") {
|
||||
if (Config.syslog.active && WiFi.status() == WL_CONNECTED) {
|
||||
SYSLOG_Utils::log("Rx", loraPacket, rssi, snr, freqError);
|
||||
}
|
||||
return loraPacket;
|
||||
|
||||
Reference in New Issue
Block a user