Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Page not being rendered on browser #1801

Open
y-runwal opened this issue Feb 17, 2025 · 0 comments
Open

Page not being rendered on browser #1801

y-runwal opened this issue Feb 17, 2025 · 0 comments

Comments

@y-runwal
Copy link

I am doing a project where device is connected to WiFi and MQTT server and some bluetooth related activity is going on. I have implemented on demand portal. When i trigger it, root page is being displayed on browser, but when pressed setup, it just doesn't load (stuck on blank page in browser). My setup has parameters for MQTT credentials. What can go wrong? Should I disconnect wifi and mqtt server below starting portal?
Below is my function to start config portal. some part is removed from original function.

`
void mannual_wifi_init() {
xTimerStop(mqttReconnectTimer, 0);

mqttClient.disconnect(true);
WiFi.mode(WIFI_STA); // explicitly set mode, esp defaults to STA+AP
open_for_AP = false;
wm.setConfigPortalTimeout(100);

if (!wm.startConfigPortal("ER-BLE-Scanner11")) {
Serial.println("failed to connect and hit timeout");
delay(3000);
//reset and try again, or maybe put it to deep sleep
ESP.restart();
delay(5000);
}

//if you get here you have connected to the WiFi
Serial.println("connected...yeey :)");
xTimerStart(mqttReconnectTimer, 0);
AP_config_mode = wm.getConfigPortalActive();
}

`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant