CharlesJGantt / LinkNode-R4-Controlled-By-Amazon-Alexa

This code will create four FauxMo smart-home devices that emulate Belkin We-Mo switches. The unmodified version of this code is originally by kakopappa and can be found at https://github.com/kakopappa/arduino-esp8266-alexa-multiple-wemo-switch/tree/master/wemos.
45 stars 16 forks source link

Consider implementing WiFiManager for runtime configuration #2

Open cosmocracy opened 7 years ago

cosmocracy commented 7 years ago

The WiFiManager project provides the ability to dynamically configure an ESP8266, including wifi SSID/credentials. WiFiManager also supports additional arbitrary config parameters which seems ideal for capturing the Alexa names associated with each of the relays. This would make the image more useful to end-users as it would not require changes to the .INO (and the entire Arduino IDE) just to configure a LinkNodeR4 once it has the initial image.

cosmocracy commented 7 years ago

I would be happy to investigate this if you would like.

joeman2116 commented 7 years ago

An excellent Idea!

I have several esp8266 and nodelink r4 using the Alexa echo Dot. - works well

The multiple wemos emulation code works great but hard coding the ssid, pw and device names makes it difficult to install at other locations etc.

cosmocracy commented 7 years ago

I've been doing some work on this in a forked repo. Worked nicely in some of my testing. Once I get it fully ironed out I'll send you a PR for your consideration, @CharlesJGantt. Thanks for this great project! See https://github.com/cosmocracy/LinkNode-R4-Controlled-By-Amazon-Alexa

joeman2116 commented 7 years ago

Had a quick look at the code. The new configuration controls look very interesting. Can hardly wait to test on a spare linknode R4

Thanks for your work and sharing it to those of who are not so talented.

Joe

Canada

cosmocracy commented 7 years ago

Glad you liked it, @joeman2116. I'll probably do a little refactoring of the code to reduce duplication--less code to test and less to go wrong ;-) before the PR to @CharlesJGantt.

joeman2116 commented 7 years ago

cosmocracy

Compiled your new test code and it uploaded fine. Looking at serial monitor: Jumper set for boot - will attempt autoconnect, else config portal mounting FS... mounted file system reading config file opened config file {"alexa_name1":"","alexa_name2":"","alexa_name3":"","alexa_name4":""} parsed json WM: Adding parameter WM: alexa_name1 WM: Adding parameter WM: alexa_name2 WM: Adding parameter WM: alexa_name3 WM: Adding parameter WM: alexa_name4 WM: WM: AutoConnect WM: Connecting as wifi client... WM: Already connected. Bailing out. WM: IP Address: WM: 192.168.1.127 connected...yeey :) SSID: ASUS66ujoe Local IP: 192.168.1.127 Begin multicast .. Udp multicast server started at 239.255.255.250:1900 WebServer started on port: 96 WebServer started on port: 97 WebServer started on port: 98 WebServer started on port: 99 Adding switches upnp broadcast responder Adding switch : index : 0 Adding switch : index : 1 Adding switch : index : 2 Adding switch : index : 3

All looks perfect up to here -----------------------------Then udp errors------

UDP packet encountered, size: 391Found 'M-SEARCH' in request ::UDP packet encountered, size: 391Found 'M-SEARCH' in request ::UDP packet encountered, size: 391Found 'M-SEARCH' in request :::UDP packet encountered, size: 444Found 'M-SEARCH' in request ::UDP packet encountered, size: 446Found 'M-SEARCH' in request

Basic udp error repeats over and over

Joe

joeman2116 commented 7 years ago

I changed the ports as the original were in use.....

cosmocracy commented 7 years ago

@joeman2116, are those errors or just the logging I added when the device sees UDP multicasts? I was having trouble with autodiscovery at one point so I added the logging. I should probably either remove it or add some logging level setting. All worked ok though, right?

joeman2116 commented 7 years ago

I think they are just info but they wipe out the serial monitor because of repetition.

When i tell alexa to discover devices

Got UDP Belkin Request..

Sending response to 192.168.1.128 Port : 50000 Response sent !

Sending response to 192.168.1.128 Port : 50000 Response sent !

Sending response to 192.168.1.128 Port : 50000 Response sent !

Sending response to 192.168.1.128 Port : 50000 Response sent ! ---------------------------------------------------------looks good then i get:

ending :<?xml version="1.0"?>urn:Belkin:device:controllee:1Belkin International Inc.Emulated Socket3.1415uuid:Socket-1_0-38323636-4558-4dda-9188-cda0e6d0fca5-72221517K01017690urn:Belkin:service:basicevent:1urn:Belkin:serviceId:basicevent1/upnp/control/basicevent1/upnp/event/basicevent1/eventservice.xml

########## Responding to setup.xml ... ########

I get 4 of the above

Are there default alexa device names? I looked at alexa after discover devices but did not see any new names Alexa name 1 etc

How to i get to the config to change the device names , ssid etc

I tried connecting to 192.168.1.4 - but no responses when connected to module also tried 192.168.1.127 on my pc (the ip shown on serial monitor - no response.

Must be me......

Joe

cosmocracy commented 7 years ago

@joeman2116, pull the boot/flash jumper and put it in the flash position (even though you're not flashing). Then restart the LinkNode and it should start in "configuration" mode (with a new wifi AP called EchoBase-something. If you associate with and access the wifi config there will be four parameter slots at the bottom of the page where you can specify names. After you save those, put the jumper back to the boot position and restart the LinkNode. (Also, those XML snippets you're seeing are just from the autodiscovery probes that Alexa (or other UPnP clients) are sending).

cosmocracy commented 7 years ago

I think we can tighten down the logging so there will be an "info" level vs. "debug" so your console won't be overwhelmed with output when you're not in need of so much detail.

joeman2116 commented 7 years ago

I have the module in flash mode.

Rebooted - still dont see any wifi ap with ecobase - looked on 2 devices

may need to clean module and reflash

On Mon, Dec 26, 2016 at 12:39 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116, pull the boot/flash jumper and put it in the flash position (even though you're not flashing). Then restart the LinkNode and it should start in "configuration" mode (with a new wifi AP called EchoBase-something. If you associate with and access the wifi config there will be four parameter slots at the bottom of the page where you can specify names. After you save those, put the jumper back to the boot position and restart the LinkNode. (Also, those XML snippets you're seeing are just from the autodiscovery probes that Alexa (or other UPnP clients) are sending).

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269225580, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY7e6udE4JjCkrT6kuGguUAVzsL2nks5rL-3bgaJpZM4LRaJz .

cosmocracy commented 7 years ago

I'll have to scrutinize the WiFiManager code to see how long the AP stays up. I've had to retry scanning/connecting multiple times--this may be a wifi/channel issue. Try a restart?

cosmocracy commented 7 years ago

I'll troubleshoot more this week and make sure my code isn't the problem :)

joeman2116 commented 7 years ago

cosmocracy,

Did a clean bin file on flash, then reflash with your code EchoBase1 appeared as AP I then selected my ssid and assigned 4 device names Did a discover and all are seen and work fine off and on.

The issue now is I want to change info So i put jumper in flash mode reset power Did wifi search for the EchoBase ap but no go. tried other devices but they and router do not see the Echobase AP

As a test again - i cleaned the module, did a reflash and echobase appeared.

It appears once config settings are done... I cannot get the Config EchoBase AP back.

Looking very close......

Thanks.....

Joe

cosmocracy commented 7 years ago

Excellent testing--thank you for documenting this scenario I think it will help me debug.

joeman2116 commented 7 years ago

During the past few days I have noticed the linknode r4 stops being accessible unless I reboot - poweroff/on. I originally thought it was just an odd happening, but within 24 hrs or so it stops responding. Very consistent.

I have another linknoder4 running beside it with the original linknode code and it continues to run flawless day after day.

Once the new code is ironed out I will see if this issue gets cleared. If, not I will load the same original linknode code to ensure it is not the module etc..

Joe

On Mon, Dec 26, 2016 at 5:45 PM, Eric Kramer notifications@github.com wrote:

Excellent testing--thank you for documenting this scenario I think it will help me debug.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269243767, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY-kPxv3ADKPbjkRx4odOUbOdV5Yoks5rMDWQgaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 Interesting. Did you happen to have the WifiManager-enabled Linknode hooked up to a serial monitor to see if there was anything being logged? I really wish there were a couple spare pins exposed on the Linknode so we could hook up either a small LCD display or at least a "heartbeat LED". Hmmm.

joeman2116 commented 7 years ago

Good idea, i will plug into computer and leave serial on to see if something shows.

Joe

On Thu, Dec 29, 2016, 4:46 PM Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Interesting. Did you happen to have the WifiManager-enabled Linknode hooked up to a serial monitor to see if there was anything being logged? I really wish there were a couple spare pins exposed on the Linknode so we could hook up either a small LCD display or at least a "heartbeat LED". Hmmm.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269690982, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpYxrRbm3R8j1wqUb2-GMORBMRK44zks5rNBw-gaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 Getting back to this now. Any word how your serial-monitored experiment is going? Thanks!

joeman2116 commented 7 years ago

Well, I tried the serial monitor but did not see anything unusual. I also exchanged the powersupply from a working linknode r4 but no change. It just seems after x time it fails to respond to alexa . The serial does not output nor does one see anything coming from alexa Discover devices doe not retore the device either. But as soon as i remove power and discover devices it returns and works .

The other linknode r 4 is a few feet a way from this one, but it continues to work 24/7.

Joe

On Sat, Dec 31, 2016, 11:38 AM Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Getting back to this now. Any word how your serial-monitored experiment is going? Thanks!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269870156, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY4ZM1iZavIfPxJlX1h1iRj53CKmJks5rNnbtgaJpZM4LRaJz .

cosmocracy commented 7 years ago

Ok, I'm about to commit a version with more logging statements. That might help pinpoint things. Thanks for your continued help from Up North, @joeman2116 :-)

cosmocracy commented 7 years ago

@joeman2116 Wondering if the problem is the underling WiFi library for the ESP8266. Looks like there is an issue being investigated with the most recent version: https://github.com/esp8266/Arduino/issues/2186

In particular see this comment: https://github.com/esp8266/Arduino/issues/2186#issuecomment-252823447

joeman2116 commented 7 years ago

My pleasure to help anyway I can..

Joe

On Sat, Dec 31, 2016 at 1:53 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Wondering if the problem is the underling WiFi library for the ESP8266. Looks like there is an issue being investigated with the most recent version: esp8266/Arduino#2186 https://github.com/esp8266/Arduino/issues/2186

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269875557, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY_JYKVvwGho4BeJb81XnD2GjSJv6ks5rNpaIgaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 New commit 3bdaf059b233dc32a29ce262a858e57504ebe656 in my repo that adds more logging and some additional reconnection tweaks. Give it a go when you have a moment? (I have a LinkNode running it now and will see what the serial logging shows)

cosmocracy commented 7 years ago

@CharlesJGantt Would you consider adding me to the project? I'd be interested in spinning up an "add-wifi-manager" branch and moving my commits to this/your repo. Thanks!

CharlesJGantt commented 7 years ago

I will definitely add you. I am traveling at the moment and will add you when I get back to my PC.

On Dec 31, 2016 1:05 PM, "Eric Kramer" notifications@github.com wrote:

@CharlesJGantt https://github.com/CharlesJGantt Would you consider adding me to the project? I'd be interested in spinning up an "add-wifi-manager" branch and moving my commits to this/your repo. Thanks!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269878117, or mute the thread https://github.com/notifications/unsubscribe-auth/AD7NQKlXSJ7lvaXmfDXilakepAvnEwV0ks5rNqdtgaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 Another commit, 7b5f223a4f03bb4f8b993b447625c71718fa5e5d, that adds further logging to help see what's going on. :-)

joeman2116 commented 7 years ago

I will burn the new code tommorrow. Thanks

Joe

On Sat, Dec 31, 2016, 3:34 PM Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Another commit, 7b5f223 https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/commit/7b5f223a4f03bb4f8b993b447625c71718fa5e5d, that adds further logging to help see what's going on. :-)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269879066, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpYwWX09ZL7lT2oPdoZNTWdeXqdr0mks5rNq49gaJpZM4LRaJz .

joeman2116 commented 7 years ago

Ok,

Flashed the linknoder4 with esptool with 4 blank.bins to be sure it clean. I installed the new code. Searched for wifi - found Echobase1 connected - 192.168.4.1 menu appeared configured wifi devices 4 saved Serial monitor - good - Disconnected power and put jumper to run mode (right hand side) powered up waited about 15 secs then told alexa to discover devices

It connected and alexa found 4 devices - which turn on and off fine.

Now in monitor mode to see how it holds.

if all goes well for 24 hours or so then I will put linknode in flash mode and change device names ssid etc - to see if re-config works consistently.

Happy New Year

Joe

On Sat, Dec 31, 2016 at 10:28 PM, joe basque joeman2116@gmail.com wrote:

I will burn the new code tommorrow. Thanks

Joe

On Sat, Dec 31, 2016, 3:34 PM Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Another commit, 7b5f223 https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/commit/7b5f223a4f03bb4f8b993b447625c71718fa5e5d, that adds further logging to help see what's going on. :-)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269879066, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpYwWX09ZL7lT2oPdoZNTWdeXqdr0mks5rNq49gaJpZM4LRaJz .

joeman2116 commented 7 years ago

Test results with new code:

Initially, everything working, and very fast responses from Alexa.

After several hours this is what the serial reports and never gets out of loop"

Disconnected while in loop(); Attempting reconnect... tatus = tatus = tatus = tatus = tatus = tatus = tatus = tatus = tatus = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = iFi status = Failure to establish connection after 10sec. Will reattempt connection in 2 sec Disconnected while in loop(); Attempting reconnect...

Goes on forever and never gets a connect. If I power off and rediscover devices - all returns to normal and it connects fine

Joe

On Sat, Dec 31, 2016 at 3:34 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Another commit, 7b5f223 https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/commit/7b5f223a4f03bb4f8b993b447625c71718fa5e5d, that adds further logging to help see what's going on. :-)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269879066, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpYwWX09ZL7lT2oPdoZNTWdeXqdr0mks5rNq49gaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 good work! I think we are closing in on this. I'll investigate adding more robustness to the reconnect handling.

joeman2116 commented 7 years ago

Eric,

Sounds good. Just did more testing and find if there is a disconnect for whatever reason, it will try to reconnect but never does. As soon as i power off then on it connects instantly and saved config is applied and alexa talks with the devices... And communication is very very fast. ...

joe

On Sun, Jan 1, 2017 at 11:23 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 good work! I think we are closing in on this. I'll investigate adding more robustness to the reconnect handling.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-269931791, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpYyQF5mKszIZh1390i6DiPo6vwvVdks5rOG2lgaJpZM4LRaJz .

cosmocracy commented 7 years ago

Hmmmm, good research. One short-term option would be to trigger a quick reboot/restart after X attempts connecting. But the better fix is to get the reconnect working.

On a related note, I have other ESP8266 projects--not using the LinkNode--that do periodically and spontaneously disconnect from wifi for 10-30sec at a time... but the code there reconnects fine. I'll see about porting some of that code to this project.

joeman2116 commented 7 years ago

Eric,

Yes, I have seen where a disconnect occurs or router reboots but reconnects occur as soon as network is stable. Certainly an auto reboot would be a nice feature if system wont reconnect by other code. Even a nice backup last resort if regular code cant reconnect after x amount of time...

When it works the response is amazingly fast. The second i tell Alexa to turn on or off its done... If i use a group command to tell alexa to turn on all relays its sound like a machine gun lol so fast....

Cool stuff

Joe

On Mon, Jan 2, 2017 at 4:11 PM, Eric Kramer notifications@github.com wrote:

Hmmmm, good research. One short-term option would be to trigger a quick reboot/restart after X attempts connecting. But the better fix is to get the reconnect working.

On a related note, I have other ESP8266 projects--not using the LinkNode--that do periodically and spontaneously disconnect from wifi for 10-30sec at a time... but the code there reconnects fine. I'll see about porting some of that code to this project.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-270015479, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY5LIsEGuTlFJ_hnCFd7XmxRKsQzfks5rOVoHgaJpZM4LRaJz .

cosmocracy commented 7 years ago

@joeman2116 Good news. Commit e8757835c750c76065a32e44a89e4fe058390bf0 implements some improvements to connection robustness. Specifically, when a disconnect occurs the reconnect attempt is done in a slightly different manner. In my testing--I rebooted my router--it reconnected after only a couple of attempts:

Disconnected while in loop(); Attempting reconnect to SEVERUS...
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
Failure to establish connection after 10sec. Will reattempt connection in 2 sec
Disconnected while in loop(); Attempting reconnect to SEVERUS...
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
Failure to establish connection after 10sec. Will reattempt connection in 2 sec
Disconnected while in loop(); Attempting reconnect to SEVERUS...
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Disconnected
WiFi status = Connected
joeman2116 commented 7 years ago

Thanks for new code

Cleaned the linknode r4 Installed new code Found the Echobase1 Entered ssid and pw Saved Rebooted Discover devices Serial monitor - looks good , alexa responses good 4 devices found - and turn off / on with a very quick response.

monitoring...

Joe

On Mon, Jan 2, 2017 at 10:50 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Good news. Commit e875783 https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/commit/e8757835c750c76065a32e44a89e4fe058390bf0 implements some improvements to connection robustness. Specifically, when a disconnect occurs the reconnect attempt is done in a slightly different manner. In my testing--I rebooted my router--it reconnected after only a couple of attempts:

Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected Failure to establish connection after 10sec. Will reattempt connection in 2 sec Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected Failure to establish connection after 10sec. Will reattempt connection in 2 sec Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Connected

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-270044659, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY3ZaNYqR4YWZnuMlH3YjZtxS_Fgbks5rObd2gaJpZM4LRaJz .

joeman2116 commented 7 years ago

wifi disconnected then

linknode would not reconnect serial monitor displays reconnect attempts over and over.

had to power off to restore to normal operation

Joe.

On Tue, Jan 3, 2017 at 11:36 AM, joe basque joeman2116@gmail.com wrote:

Thanks for new code

Cleaned the linknode r4 Installed new code Found the Echobase1 Entered ssid and pw Saved Rebooted Discover devices Serial monitor - looks good , alexa responses good 4 devices found - and turn off / on with a very quick response.

monitoring...

Joe

On Mon, Jan 2, 2017 at 10:50 PM, Eric Kramer notifications@github.com wrote:

@joeman2116 https://github.com/joeman2116 Good news. Commit e875783 https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/commit/e8757835c750c76065a32e44a89e4fe058390bf0 implements some improvements to connection robustness. Specifically, when a disconnect occurs the reconnect attempt is done in a slightly different manner. In my testing--I rebooted my router--it reconnected after only a couple of attempts:

Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected Failure to establish connection after 10sec. Will reattempt connection in 2 sec Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected Failure to establish connection after 10sec. Will reattempt connection in 2 sec Disconnected while in loop(); Attempting reconnect to SEVERUS... WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Disconnected WiFi status = Connected

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CharlesJGantt/LinkNode-R4-Controlled-By-Amazon-Alexa/issues/2#issuecomment-270044659, or mute the thread https://github.com/notifications/unsubscribe-auth/AWDpY3ZaNYqR4YWZnuMlH3YjZtxS_Fgbks5rObd2gaJpZM4LRaJz .

littledrumer commented 6 years ago

After I upload the code to my Linknode R4 and switch it to normal run mode it continuously flashes the power LED on the Linknode and on the ESP8266 . I am getting this in the serial window.

ets Jan 8 2013,rst cause:1, boot mode:(3:7)

I have searched for an explanation and have only found that the function wdt_disable() is no longer working but I can't seem to find that function in the code anywhere. Any ideas as to what is wrong?