* feat(wifi): add compile time configurtation
Add `WLED_AP_SSID` and `WLED_AP_PASS` defines to allow configuring the
SoftAP SSID and Password at compile time. Default to existing values.
Add `WLED_AP_SSID_UNIQUE` flag to append the device portion of the mac
address to `WLED_AP_SSID`.
Exampleof all flags (note the quoting to preserve
"stringification"):
```
build_flags =
-D WLED_AP_SSID='"MyAP"'
-D WLED_AP_PASS='"MyPassword"'
-D WLED_AP_SSID_UNIQUE
```
* Removed two error defines
Co-authored-by: Christian Schwinne <cschwinne@gmail.com>
- added "max used PSRAM" info
- moved all mem infos into one part
- only check PSRAM if BOARD_HAS_PSRAM
- oappend: debug message in case that stack buffer is too small.
This is a nice little chip info tool that I've created some time ago.
When building with `-D WLED_DEBUG`, it reports some interesting information about your ESP32 on serial monitor.
````
====================================
Chip info for ESP32-D0WDQ5
SDK: v4.4.1-472-gc9140caf8c
------------------------------------
XTAL FREQ: 40 MHz
APB FREQ: 80.0 MHz
CPU FREQ: 240 MHz
ESP32 DEVICE: ESP32-D0WD-V3 rev.3, 2 core(s), 240MHz.
Chip feature flags: 0b110010
* 0b0000010 Chip has 2.4GHz WiFi
* 0b0001000 Chip has Bluetooth LE
* 0b0010000 Chip has Bluetooth Classic
FLASH CHIP FREQ (magic): 80.0 MHz
FLASH SIZE (magic byte): 4.00 MB
FLASH MODE (magic byte): 2 ; 0=QIO, 1=QOUT, 2=DIO, 3=DOUT or other
FLASH CHIP ID: 0x16405E
FLASH CHIP FREQ: 80.0 MHz
FLASH REAL SIZE: 4.00 MB
FLASH REAL MODE: DIO
------------------------------------
RAM HEAP SIZE: 261.79 KB
FREE RAM: 232.57 KB
MAX RAM alloc: 107.99 KB
ESP32 PSRAM: found.
* SPI RAM Chip availeable: 64MBits = 8MBytes
total PSRAM: 4094 KB
FREE PSRAM: 4093.89 KB
MAX PSRAM alloc:4031.99 KB
used PSRAM: 0 Bytes
* PSRAM free after malloc / ps_malloc : 2833.85 KB
* Can allocate big memory with ps_malloc()
* Can allocate big memory with malloc()
CPU #0 - last reset reason = 1 POWERON_RESET => Vbat power on reset
CPU #1 - last reset reason = 14 EXT_CPU_RESET => APP CPU reset by PRO CPU
====================================
````
This fixes a "division by zero" in WLED_DEBUG code.
LittleFS init seems to take some time, so we can arrive at "Loops/sec" with 0 loops executed --> crash.
- adding USB-OTG to reserved GPIO
- no read-only GPI
- if PSRAM found, add pins for "octal" PSRAM to unusable list (octal PSRAM seems to common on S3)
- ESP32: 37 and 38 are read-only
handleImprovPacket() unconditionally gobbles serial data which a problem
if we want another feature to consume it. This patch uses the same guard
as the existing call in `handleSerial()`.
Co-authored-by: Thomas Fubar <FUB4R@users.noreply.github.com>