khoih-prog / WiFiManager_Portenta_H7_Lite

Library to configure MultiWiFi/Credentials at runtime for Portenta_H7 boards, using built-in WiFi (Murata) modules/shields. You can also specify DHCP HostName, static AP and STA IP. Use much less memory compared to full-fledge WiFiManager. Config Portal will be auto-adjusted to match the number of dynamic custom parameters. Optional default Credentials to be autoloaded into Config Portal to use or change instead of manually input. Credentials are saved in LittleFS. New powerful-yet-simple-to-use feature to enable adding dynamic custom parameters from sketch and input using the same Config Portal. DoubleDetectDetector as well as Virtual Switches feature permits entering Config Portal as requested. Now using WiFiMulti_Generic library
MIT License
5 stars 2 forks source link

Configuration not being saved #1

Closed dddhhhrrr closed 2 years ago

dddhhhrrr commented 2 years ago

Describe the bug

I'm running the Portenta_H7_WiFi example and no matter what I do, when I open the browser and set the SSID and password and press Save it just stays there....

Steps to Reproduce

run Portenta_H7_WiFi example, connect to the SSID on your phone, go to the webpage 192.168.3.1, write your SSID and password and hit SAVE

Expected behavior

The configuration should be saved

Actual behavior

nothing happens

Information

khoih-prog commented 2 years ago

Hi @dddhhhrrr

It's running normally here, so the issue is possibly your board issue (hardware, firmware, core version, etc.). Ask for help on Arduino Forum if necessary.

1. No Config Data => Config Portal at 192.168.3.1

Start Portenta_H7_WiFi on PORTENTA_H7_M7 with Portenta_H7 WiFi
WiFiMulti_Generic v1.1.1
WiFiManager_Portenta_H7_Lite v1.6.0
[WG] Hostname=Portenta-Controller
Flash Size: (KB) = 2048.00
FlashIAP Start Address: = 0x80A0000
LittleFS size (KB) = 1280.00
LittleFS Mount OK
LittleFS Flag read = 0xd0d04321
Flag read = 0xd0d04321
No doubleResetDetected
Saving DOUBLERESETDETECTOR_FLAG to DRD file : 0xd0d01234
Saving DRD file OK
SetFlag write = 0xd0d01234
[WG] bg: isForcedConfigPortal = false
[WG] bg:Stay forever in CP:No ConfigDat
[WG] clearForcedCP
[WG] SaveCPFile 
[WG] OK
[WG] SSID=WIFI_GENERIC_51F485,PW=MyWIFI_GENERIC_51F485
[WG] IP=192.168.3.1,CH=1
F
Your stored Credentials :
Blynk Server1 = account.duckdns.org
Token1 = token1
Blynk Server2 = account.ddns.net
Token2 = token2
Port = 8080
MQTT Server = mqtt.duckdns.org
Stop doubleResetDetecting
Saving to DRD file : 0xd0d04321
Saving DRD file OK
LittleFS Flag read = 0xd0d04321
ClearFlag write = 0xd0d04321
FFFF[WG] 
h:UpdLittleFS
[WG] h:Rst

2. Config Data saved => working normally, even after power off-on

Start Portenta_H7_WiFi on PORTENTA_H7_M7 with Portenta_H7 WiFi
WiFiMulti_Generic v1.1.1
WiFiManager_Portenta_H7_Lite v1.6.0
[WG] Hostname=Portenta-Controller
Flash Size: (KB) = 2048.00
FlashIAP Start Address: = 0x80A0000
LittleFS size (KB) = 1280.00
LittleFS Mount OK
LittleFS Flag read = 0xd0d04321
Flag read = 0xd0d04321
No doubleResetDetected
Saving DOUBLERESETDETECTOR_FLAG to DRD file : 0xd0d01234
Saving DRD file OK
SetFlag write = 0xd0d01234
[WG] CCSum=0x1518,RCSum=0x1518
[WG] CrCCsum=0x1de6,CrRCsum=0x1de6
[WG] Valid Stored Dynamic Data
[WG] ======= Start Stored Config Data =======
[WG] Hdr=PORTENTA-H7-WIFI,SSID=HueNet1,PW=12345678
[WG] SSID1=HueNet,PW1=12345678
[WG] BName=Portenta_H7_M7
[WG] i=0,id=sv1,data=new-account.duckdns.org
[WG] i=1,id=tk1,data=token1
[WG] i=2,id=sv2,data=new-account.ddns.net
[WG] i=3,id=tk2,data=token2
[WG] i=4,id=prt,data=8080
[WG] i=5,id=mqt,data=new-mqtt.duckdns.org
[WG] WiFi connected after time: 1
[WG] SSID:HueNet,RSSI=-37
[WG] IP address:192.168.2.119
[WG] b:WOK
Stop doubleResetDetecting
Saving to DRD file : 0xd0d04321
Saving DRD file OK
LittleFS Flag read = 0xd0d04321
ClearFlag write = 0xd0d04321
H
Your stored Credentials :
Blynk Server1 = new-account.duckdns.org
Token1 = token1
Blynk Server2 = new-account.ddns.net
Token2 = token2
Port = 8080
MQTT Server = new-mqtt.duckdns.org