updated libraries, fixed ESP-NOW send data function to work with the new library

This commit is contained in:
2025-09-09 01:09:15 +02:00
parent 79c734bd34
commit 649cbe63b1
3 changed files with 5 additions and 2 deletions

View File

@@ -1,6 +1,7 @@
// ROFLS+ Referee Remote
#include <WiFi.h>
#include <esp_wifi.h> // Required for wifi_tx_info_t
#include <esp_now.h> // automatically installed for ESP32 boards, I think?
#include <Preferences.h> // automatically installed for ESP32 boards
#include <avdweb_Switch.h> // https://github.com/avdwebLibraries/avdweb_Switch
@@ -79,7 +80,7 @@ esp_now_peer_info_t peerInfo;
Preferences preferences;
// callback when data is sent
void OnDataSent(const uint8_t *mac_addr, esp_now_send_status_t status) {
void OnDataSent(const wifi_tx_info_t *tx_info, esp_now_send_status_t status) {
Serial.print("\r\nLast Packet Send Status:\t");
Serial.println(status == ESP_NOW_SEND_SUCCESS ? "Delivery Success" : "Delivery Fail");
}