beaconupdate1

This commit is contained in:
richonguzman 2023-02-11 18:18:34 -03:00
parent f9b2bfb934
commit 3b2f231db0
2 changed files with 4 additions and 4 deletions

View file

@ -112,8 +112,7 @@ void setup() {
void loop() {
String receivedPacket = "";
uint32_t lastTx = millis() - lastTxTime;
bool beacon_update = true;
static bool beacon_update = true;
int packetSize = LoRa.parsePacket();
if (packetSize) {
@ -124,9 +123,10 @@ void loop() {
valida_y_procesa_packet(receivedPacket); //Serial.println("Mensaje Recibido : " + String(receivedPacket));
}
uint32_t lastTx = millis() - lastTxTime;
if (lastTx >= BeaconInterval) {
beacon_update = true;
}
}
if (beacon_update) {
Serial.println("enviando Beacon Estacion/iGate");

View file

@ -4,7 +4,7 @@
#define WIFI_SSID "Richon"
#define WIFI_PASSWORD "k4fPnmg5qnyf"
#define BeaconInterval 15*60*1000 // 15 minutes
#define BeaconInterval 900000 // 15 minutes = 900000 seg
String iGate_Callsign = "CD2RXU-10";
String passcode_igate = "23201";