https://github.com/esp8266/Arduino/issues/2128
Anyone can help?
Explore... Chat... Share...
void loop(void){
webserver.handleClient();
if (setPort==1) // check flag
{
digitalWrite(led, 0); // just a short flash of light.
delay(90);
webserver.begin(portNumber); // this is where it all happens
Serial.print("new port number ");
Serial.println(portNumber);
digitalWrite(led, 1);
setPort = 0; // clear flag
}
}rudy wrote:It works for me. I used a form to input the port number on a webpage. Took that argument and passed it to the code below. The port changed to what I entered on the webpage. The old port was no longer available, the webpage shows up on the new port number.
I am using a git version from a few weeks ago.
I'm curious why you would need this.Code: Select allvoid loop(void){
webserver.handleClient();
if (setPort==1) // check flag
{
digitalWrite(led, 0); // just a short flash of light.
delay(90);
webserver.begin(portNumber); // this is where it all happens
Serial.print("new port number ");
Serial.println(portNumber);
digitalWrite(led, 1);
setPort = 0; // clear flag
}
}
lucasromeiro wrote:hello, but I die for the wifiserver !! for it does not work .... what is a git version?
I need this because the user of my system should be able to change the communication port according to the portforwarding configuration that is made. understood?It takes about 20-25 seconds for home assistant c[…]
I tried to upgrade tof my sonoff basic R2 with the[…]
a problem Perhaps you want to define "Probl[…]
Rebooting your router will not give you a faster I[…]
There are no other notifications from esptool.py i[…]
Using the Arduino IDE, you'll learn how to set up […]
In this project, you will post to Twitter using an[…]
In this project, we will build a water level contr[…]
I guess I'm late, but I had the same problem and f[…]
Last night I received my first D1 Minis for a lear[…]
Although I am aware that this is an old post, I fe[…]