why does library not work for me in different environment?
Great package! Thank you. It works great for me in Ubuntu 24.04 but does not work in Fedora 42.
The same test Python code is running in both environments, on the same laptop hardware (booted from USB for Ubuntu, booting off disk for Fedora). In both environments the prep.sh script puts the wireless device in monitor mode on the correct channel, according to iwconfig/iw. An ESP32 device sends broadcast packets and listens for broadcast packets. The Ubuntu laptop target can communicate both directions with the ESP using ESPythoNOW, but the Fedora target can not communicate with the ESP.
In Fedora, when the laptop sends a packet, it does appear in Wireshark on the laptop that is listening to the monitor interface. But the packet is not received by the ESP32, so I think the packet is not actually getting out in a form that the ESP thinks is ESPNow. When the ESP sends a packet, no packets ever appear on the laptop Wireshark session in Fedora.
I thought the issue might be differing scapy version (2.6.0 in Fedora, 2.5.0 in Ubuntu) but things still don't work if I install scapy 2.5.0 in a venv in Fedora and use that.
Fedora is using kernel 6.14.6 and Ubuntu is on kernel 6.8.0. I'm wondering if that is the issue, or maybe some kernel build option. I'm hoping someone has a suggestion for how to figure out why Fedora is not working on the same hardware.
I'm not sure, scapy is at the heart of everything, so I'm tempted to say the source of the issue is there.
Using another computer, or interface, does wireshark pick up the packets leaving the ESPythoNow interface? Or can you only see it while monitoring the interface used for ESPythoNow?
libpcap-devel is installed on fedora?
Thanks for the suggestion. I confirmed, by using another ESPythonNOW Linux machine, that the Fedora machine is actually sending ESPNow packets out! It just cannot seem to receive any.
I thought maybe the incoming ESPNow packets were being firewalled coming in to the Fedora machine, but that does not seem to be the case. So still a mystery why the Fedora machine cannot receive. I have no idea if ESPNow packets would be subject to iptables/nftables rules anyway--would they?
Strong possibility seems to be a difference in the version of the wifi driver (so kernel difference basicallyl) or wifi firmware load between the functional Ubuntu and nonfunctional Fedora. Another thing I have noticed is that on Fedora I often am not able to return the interface back into functional managed mode after experimentation, without rebooting.