SOLVED! how do i change my wifi ssid/password in espeasy url interface

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
ufumes
Normal user
Posts: 11
Joined: 14 Aug 2018, 23:00

SOLVED! how do i change my wifi ssid/password in espeasy url interface

#1 Post by ufumes » 14 Aug 2018, 23:14

Hi guys, pls i need help with updating my ssid/password settings in espeasy. I was able to change it manually through <espeasyip>/config, but i am wondering if it is possible to specify the values of my my ssid/password directly and dynamically through URL in a way similar to "http://192.168.50.111/control?cmd=GPIO,12,1" so that i can encode it programatically into my application, without my users having to start learning the details of configuring the esp8622 by themselves. Pls i appreciate your advice and help. thanks
Last edited by ufumes on 16 Aug 2018, 11:21, edited 1 time in total.

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: how do i change my wifi ssid/password in espeasy url interface

#2 Post by grovkillen » 15 Aug 2018, 06:19

You need to do that over serial. BUT you might be able to do it with an event call together with %eventvalue%.... haven't tested it myself but I figured I give you a pointer on what to test.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

TD-er
Core team member
Posts: 8643
Joined: 01 Sep 2017, 22:13
Location: the Netherlands
Contact:

Re: how do i change my wifi ssid/password in espeasy url interface

#3 Post by TD-er » 15 Aug 2018, 12:03

It is a bit tricky to update those settings via http.
Rules could work. like Grovkillen suggested, but I don't see yet how, so I am also curious to how he thinks to do that :)

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: how do i change my wifi ssid/password in espeasy url interface

#4 Post by grovkillen » 15 Aug 2018, 13:12

Given a integer password and integer ssid name it would work using %eventvalue% ;)
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

ufumes
Normal user
Posts: 11
Joined: 14 Aug 2018, 23:00

Re: how do i change my wifi ssid/password in espeasy url interface

#5 Post by ufumes » 15 Aug 2018, 23:56

thanks for the heads-up, i was able to get the list of system variables from https://www.letscontrolit.com/wiki/inde ... _Variables , there i saw ssid, but the is there a way to access the password variable?
Thanks in advance

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: how do i change my wifi ssid/password in espeasy url interface

#6 Post by grovkillen » 16 Aug 2018, 08:52

As the current code base. No only integer/float values are possible to use "all over the place". We hope to be able to bring string values into this later down the line but that's something for 2019 ;)
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

ufumes
Normal user
Posts: 11
Joined: 14 Aug 2018, 23:00

Re: how do i change my wifi ssid/password in espeasy url interface

#7 Post by ufumes » 16 Aug 2018, 10:43

Hi, I was finally able to figure it out and got it working! so here is how i achieved it (this is just for future easpeasy users who wishes to be able to change their wifi ssid and wifi key through a http command)

First create rules (from the espeasy interface go to Tools/advanced, then enable rules. A new tab called rule appears, open and type the following inside it , then click on SUBMIT

Code: Select all

on wifissid do
  WifiSSID %eventvalue%
endon

on wifikey do
  WifiKey %eventvalue%
endon

on saveit do
  save
endon

on RebootS do
  Reboot
endon
access the following url in this succession

Code: Select all

http://192.168.50.184/control?cmd=event,wifissid=mywifiName
http://192.168.50.184/control?cmd=event,wifikey=mywifiKey
http://192.168.50.184/control?cmd=event,saveit
http://192.168.50.184/control?cmd=event,RebootS
NB: Replace the IP address to your IP address.
thats it. Note that the wifi name and password can contain only alphabet and numbers.

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: SOLVED! how do i change my wifi ssid/password in espeasy url interface

#8 Post by grovkillen » 16 Aug 2018, 12:50

Ah great, I didn't know that event value accepted alphanumerical (not only numerical). Thanks for that heads up!
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: how do i change my wifi ssid/password in espeasy url interface

#9 Post by grovkillen » 16 Aug 2018, 12:51

ufumes wrote: 16 Aug 2018, 10:43 Hi, I was finally able to figure it out and got it working! so here is how i achieved it (this is just for future easpeasy users who wishes to be able to change their wifi ssid and wifi key through a http command)

First create rules (from the espeasy interface go to Tools/advanced, then enable rules. A new tab called rule appears, open and type the following inside it , then click on SUBMIT

Code: Select all

on wifissid do
  WifiSSID %eventvalue%
endon

on wifikey do
  WifiKey %eventvalue%
endon

on saveit do
  save
endon

on RebootS do
  Reboot
endon
access the following url in this succession

Code: Select all

http://192.168.50.184/control?cmd=event,wifissid=mywifiName
http://192.168.50.184/control?cmd=event,wifikey=mywifiKey
http://192.168.50.184/control?cmd=event,saveit
http://192.168.50.184/control?cmd=event,RebootS
NB: Replace the IP address to your IP address.
thats it. Note that the wifi name and password can contain only alphabet and numbers.
You could simplify this by:

Code: Select all

on wifissid do
  WifiSSID %eventvalue%
endon

on wifikey do
  WifiKey %eventvalue%
endon

on saveit do
  Save
  Reboot
endon
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

ufumes
Normal user
Posts: 11
Joined: 14 Aug 2018, 23:00

Re: SOLVED! how do i change my wifi ssid/password in espeasy url interface

#10 Post by ufumes » 16 Aug 2018, 16:34

Ok, thanks

Post Reply

Who is online

Users browsing this forum: No registered users and 30 guests