martinius96 / ESP32-eduroam

Examples with connection to eduroam powered university networks around the world and then to IoT services or self-hosted websites..
http://arduino.clanweb.eu/wpa2-enterprise.php
MIT License
98 stars 28 forks source link

esp_wpa2_config_t was not declared in this scope #8

Closed JaimeHuarte closed 2 years ago

JaimeHuarte commented 2 years ago

Hello! When I try to compile this code It appears that the type esp_wpa2_config_t wasn't declared, but I implemented the needed libraries and don't know why. Is it possible they retired that config variable type from the library?

martinius96 commented 2 years ago

Hello there, it looks like many things changed in esp_wpa2.h header file. I am using older Arduino Core, my esp_wpa2.h is from 11th January 2019, it is from Arduino Core 1.0.1 up to 1.0.4 or similar. So I think, example sketches are not useable with newer version of Arduino Core for ESP32.

My actual esp_wpa2.h (I havent found which .cpp library it is using): https://pastebin.com/sedMTmVP There is both esp_wpa2.h codes diff: https://www.diffchecker.com/roChUY8R it looks totally reworked (on left, old version on right).

martinius96 commented 2 years ago

@JaimeHuarte I have created some updates in codes available in repository. There is 2021 and 2022 implementations. In Arduino Core 2.0.3-RC1 there was added new WiFi.begin() function that can accept parameters for WPA/WPA2 Enterprise connection. Can you please test that?

Note: 2.0.3-RC1 is development version, it is not available if you are using .json link in Arduino IDE for stable-only releases.