mirror of
https://github.com/0xFEEDC0DE64/arduino-esp32.git
synced 2025-07-13 10:46:31 +02:00
Update IDF to aaf1239 (#1539)
* fix sdmmc config * Fix warnings in EEPROM from @Curclamas * remove leftover TAG in EEPROM * Initial add of @stickbreaker i2c * Add log_n * fix warnings when log is off * i2c code clean up and reorganization * add flags to interrupt allocator * fix sdmmc config * Fix warnings in EEPROM from @Curclamas * remove leftover TAG in EEPROM * fix errors with latest IDF * fix debug optimization (#1365) incorrect optimization for debugging tick markers. * Fix some missing BT header * Change BTSerial log calls * Update BLE lib * Arduino-ESP32 release management scripted (#1515) * Calculate an absolute path for a custom partitions table (#1452) * * Arduino-ESP32 release management scripted (ready-to-merge) * * secure env for espressif/arduino-esp32 * * build tests enabled * gitter webhook enabled * * gitter room link fixed * better comment * * filepaths fixed * BT Serial adjustments * * don't run sketch builds & tests for tagged builds * Return false from WiFi.hostByName() if hostname is not resolved * Free BT Memory when BT is not used * WIFI_MODE_NULL is not supported anymore * Select some key examples to build with PlatformIO to save some time * Update BLE lib * Fixed BLE lib * Major WiFi overhaul - auto reconnect on connection loss now works - moved to event groups - some code clean up and procedure optimizations - new methods to get a more elaborate system ststus * Add cmake tests to travis * Add initial AsyncUDP * Add NetBIOS lib and fix CMake includes * Add Initial WebServer * Fix WebServer and examples * travis not quiting on build fail * Try different travis build * Update IDF to aaf1239 * Fix WPS Example * fix script permission and add some fail tests to sketch builder * Add missing space in WiFiClient::write(Stream &stream)
This commit is contained in:
@ -34,6 +34,37 @@ typedef void (*WiFiEventSysCb)(system_event_t *event);
|
||||
|
||||
typedef size_t wifi_event_id_t;
|
||||
|
||||
typedef enum {
|
||||
WIFI_POWER_19_5dBm = 78,// 19.5dBm
|
||||
WIFI_POWER_19dBm = 76,// 19dBm
|
||||
WIFI_POWER_18_5dBm = 74,// 18.5dBm
|
||||
WIFI_POWER_17dBm = 68,// 17dBm
|
||||
WIFI_POWER_15dBm = 60,// 15dBm
|
||||
WIFI_POWER_13dBm = 52,// 13dBm
|
||||
WIFI_POWER_11dBm = 44,// 11dBm
|
||||
WIFI_POWER_8_5dBm = 34,// 8.5dBm
|
||||
WIFI_POWER_7dBm = 28,// 7dBm
|
||||
WIFI_POWER_5dBm = 20,// 5dBm
|
||||
WIFI_POWER_2dBm = 8,// 2dBm
|
||||
WIFI_POWER_MINUS_1dBm = -4// -1dBm
|
||||
} wifi_power_t;
|
||||
|
||||
static const int AP_STARTED_BIT = BIT0;
|
||||
static const int AP_HAS_IP6_BIT = BIT1;
|
||||
static const int AP_HAS_CLIENT_BIT = BIT2;
|
||||
static const int STA_STARTED_BIT = BIT3;
|
||||
static const int STA_CONNECTED_BIT = BIT4;
|
||||
static const int STA_HAS_IP_BIT = BIT5;
|
||||
static const int STA_HAS_IP6_BIT = BIT6;
|
||||
static const int ETH_STARTED_BIT = BIT7;
|
||||
static const int ETH_CONNECTED_BIT = BIT8;
|
||||
static const int ETH_HAS_IP_BIT = BIT9;
|
||||
static const int ETH_HAS_IP6_BIT = BIT10;
|
||||
static const int WIFI_SCANNING_BIT = BIT11;
|
||||
static const int WIFI_SCAN_DONE_BIT= BIT12;
|
||||
static const int WIFI_DNS_IDLE_BIT = BIT13;
|
||||
static const int WIFI_DNS_DONE_BIT = BIT14;
|
||||
|
||||
class WiFiGenericClass
|
||||
{
|
||||
public:
|
||||
@ -46,6 +77,9 @@ class WiFiGenericClass
|
||||
void removeEvent(WiFiEventSysCb cbEvent, system_event_id_t event = SYSTEM_EVENT_MAX);
|
||||
void removeEvent(wifi_event_id_t id);
|
||||
|
||||
static int getStatusBits();
|
||||
static int waitStatusBits(int bits, uint32_t timeout_ms);
|
||||
|
||||
int32_t channel(void);
|
||||
|
||||
void persistent(bool persistent);
|
||||
@ -56,14 +90,23 @@ class WiFiGenericClass
|
||||
bool enableSTA(bool enable);
|
||||
bool enableAP(bool enable);
|
||||
|
||||
bool setSleep(bool enable);
|
||||
bool getSleep();
|
||||
|
||||
bool setTxPower(wifi_power_t power);
|
||||
wifi_power_t getTxPower();
|
||||
|
||||
static esp_err_t _eventCallback(void *arg, system_event_t *event);
|
||||
|
||||
protected:
|
||||
static bool _persistent;
|
||||
static wifi_mode_t _forceSleepLastMode;
|
||||
|
||||
static int setStatusBits(int bits);
|
||||
static int clearStatusBits(int bits);
|
||||
|
||||
public:
|
||||
int hostByName(const char *aHostname, IPAddress &aResult);
|
||||
static int hostByName(const char *aHostname, IPAddress &aResult);
|
||||
|
||||
protected:
|
||||
friend class WiFiSTAClass;
|
||||
|
Reference in New Issue
Block a user