connornishijima / AlertMe

Arduino library for sending email and SMS from nothing but the ESP8266!
GNU General Public License v3.0
67 stars 17 forks source link

URL redirection is corrupted #4

Closed sontqq closed 4 years ago

sontqq commented 6 years ago

Everytime I connect to the AP it redirects me to http://smtp.gmail.com192.168.4.1/. Even if I try to enter the IP manually.

Debug lines:

*ALERTME: Mounting SPIFFS...
*ALERTME: Mounted file system.
*ALERTME: Reading alertme_config.json...
*ALERTME: Opened config file!
*ALERTME: Parsed config:
{"smtp_server":"smtp.gmail.com","smtp_port":465,"smtp_email":"****","smtp_password":"****"}*ALERTME: 

*ALERTME: Connecting to your WiFi network...

Failed to connect to WiFi, config AP active at: 'AlertMe Configuration'

Any idea how to resolve it?

petri1973 commented 5 years ago

Hi.

I have the same problem, please fix it.

192.168.4.1 page shows next:

Chip ID 2352881 Flash Chip ID 1335429 IDE Flash Size 1048576 bytes Real Flash Size 1048576 bytes Soft AP IP smtp.gmail.com192.168.4.1 Soft AP MAC BE:DD:C2:23:E6:F1 Station MAC smtp.gmail.comBC:DD:C2:23:E6:F1

petri1973 commented 5 years ago

Ok, found the reason, its not compatible with the esp8266 2.5.0, 2.4.2 and it works!

Thanks!!

mikekgr commented 5 years ago

Hello @petri1973 did you try the latest GitHub version ( master ) of ESP8266 Arduino core? I encourage you to try it as they have done many corrections. In this case, please report here if it working or not!

petri1973 commented 5 years ago

Hi mikekgr,

Yes, the problem is with the latest version, when installed 2.4.2 the corruption of json stopped. Allthough, if the field in web interface is left empty once, and then try to update it, corrupted again..

mikekgr commented 5 years ago

Hello again @petri1973 , please make sure that you have installed the latest GitHub version, master that is cocked now and not the released 2.5.0 that have some problems... If you indeed have the master installed and still have the problem, then it is important to file an issue to them... Best Regards, Mike Kranidis

petri1973 commented 5 years ago

Hi mikekgr,

Yes, I used the direct link to pull the branch with the GitHub desktop app. Also tried the zip. And added the cjson link to arduino 1.8.8. (stable release), and from boards manager installed the latest version.

So tried all possible ways that I know of. Quite new with this stuff, but had no similar issues before with other projects.

After installed the 2.4.2 the problem went away, now the code is working.

More:

The web page after corruption is like: smtp.gmail.com192.168.4.1

drinnird commented 5 years ago

Is there a fix for this? I have tried all the versions since 2.4.2 and cannot get this to work except with 2.4.2. only issue is corruption after web interface is left empty.

drderiv commented 5 years ago

I've proposed a fix for this that prevents the issue from happening regardless of the version of esp8266. It may have worked in previous versions due to the way the older kernel allocates memory, but regardless there was indeed a bug in the code which I've created a PR for.

connornishijima commented 4 years ago

drderiv's fix was merged just now. Sorry for the wait!