Skip to content

ESP-NOW encrypt with ESP32 peer (Arduino 3.x): silent no-recv on SoftAP ESP8266 #9322

Description

@tmdrake

Summary

Encrypted ESP-NOW between ESP32 (Arduino-ESP32 3.x) and ESP8266 SoftAP fails silently (no recv on 8266) even with matching PMK/LMK, same channel, and STA joined SoftAP. Unencrypted peers work on the same setup.

Full write-up + repro sketch shapes:

espressif/arduino-esp32#12796

ESP8266 side (fail)

esp_now_set_kok((u8*)PMK, 16);
esp_now_add_peer(tail_mac, ESP_NOW_ROLE_COMBO, 2, (u8*)LMK, 16);
// recv_cb never called for encrypted frames from ESP32

Workaround

esp_now_add_peer(tail_mac, ESP_NOW_ROLE_COMBO, 2, NULL, 0);  // no encrypt

Also document please

ESP8266 SoftAP MAC ≠ STA MAC (WiFi.softAPmacAddress() / client WiFi.BSSID() vs WiFi.macAddress()). Wrong peer MAC also looks like “ESP-NOW ready but dead.”

Asking: is encrypted ESP-NOW ESP32↔ESP8266 supported? If not, docs would save a lot of bench time.

Field notes: https://github.com/tmdrake/DRAKE_2_0_TAIL/blob/main/docs/ESPNOW_ENCRYPT_CROSS_CHIP_ISSUE.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions