autoplant: fix settings.h inclusion ordering

This commit is contained in:
Starbeamrainbowlabs 2022-02-03 18:51:09 +00:00
parent 3eb49a813e
commit 098dd82394
Signed by: sbrl
GPG key ID: 1BE5172E637709C2
2 changed files with 7 additions and 3 deletions

2
.gitignore vendored
View file

@ -1,4 +1,6 @@
*.bak
settings.h settings.h
*.gcode *.gcode
*.stl *.stl
*.obj *.obj

View file

@ -5,6 +5,8 @@
#include <WiFi.h> #include <WiFi.h>
#include "settings.h"
#ifdef WIFI_ENTERPRISE_ENABLED #ifdef WIFI_ENTERPRISE_ENABLED
// Ref https://github.com/martinius96/ESP32-WPA2-enterprise/blob/master/ESP32_WPA2enterprise.ino // Ref https://github.com/martinius96/ESP32-WPA2-enterprise/blob/master/ESP32_WPA2enterprise.ino
#include "esp_wpa2.h" #include "esp_wpa2.h"
@ -25,7 +27,6 @@
#include <Adafruit_Sensor.h> #include <Adafruit_Sensor.h>
#include <Adafruit_BME280.h> #include <Adafruit_BME280.h>
#include "settings.h"
// WAS D5 D6 D7 // WAS D5 D6 D7
@ -85,8 +86,9 @@ void connect_wifi() {
esp_wifi_sta_wpa2_ent_set_identity((uint8_t *)user, strlen(user)); esp_wifi_sta_wpa2_ent_set_identity((uint8_t *)user, strlen(user));
esp_wifi_sta_wpa2_ent_set_username((uint8_t *)user, strlen(user)); esp_wifi_sta_wpa2_ent_set_username((uint8_t *)user, strlen(user));
esp_wifi_sta_wpa2_ent_set_password((uint8_t *)pass, strlen(pass)); esp_wifi_sta_wpa2_ent_set_password((uint8_t *)pass, strlen(pass));
esp_wpa2_config_t config = WPA2_CONFIG_INIT_DEFAULT(); esp_wifi_sta_wpa2_ent_enable();
esp_wifi_sta_wpa2_ent_enable(&config); // esp_wpa2_config_t config = WPA2_CONFIG_INIT_DEFAULT();
// esp_wifi_sta_wpa2_ent_enable(&config);
WiFi.begin(WIFI_SSID); WiFi.begin(WIFI_SSID);
#endif #endif