We all love to see amazing hacks in their finished state and be dazzled by what our peers can do. But that’s just the summit of the hacker’s Everest. We all know that the real work is in getting there. Hackaday.io user [stopsendingmejunk] is working on an ESP8266-based IFTTT Button based on a simple breakout board so that anyone could rebuild it without having to do any soldering, and he’s looking for collaboration.
[stopsendingmejunk]’s project takes off from this similar project on different hardware. The board he’s chosen to use is the EZSBC ESP8266-07 breakout, which should have everything he needs, including an on-board button. It should be an easy enough job, but he’s having trouble getting the thing to stay asleep until the button is pressed.
We’ve seen more than a few hacks of the Amazon Dash button, but aside from hacking for hacking’s sake, we’re also happy to see a ground-up open redesign. Besides, this looks like it’ll be a great introductory project, requiring little fiddling around. With a little help. The code is up here on GitHub. Anyone game?
Wire your button to pull the RST line to ground (or use the inbuilt reset button on your dev board). If your program is running this will cause a reset but if it’s in deep sleep it will wake up. In your code just use node.dsleep(0, 4) to stay asleep indefinitely. Reference is here – https://github.com/nodemcu/nodemcu-firmware/wiki/nodemcu_api_en#nodedsleep
That site was a gold mine of info on the esp8266.
Thank-You Matt. I just starting to get into the the body of programming this thing and I think it is great.
I have ordered 10 of then to start off with. And am waiting for them to show up any day now.
Great Reference.
Oh and good luck Elliot on the project i like it.
It’s not my project — I just wrote it up. But I think it’s neat too.
Adding an explanation to the article what IFTTT means would avoid the need of having to google it.
Adding it in your comment would also avoid the need to google it.
Replying with the information would *also* avoid the need to Google it. ;)
As would have including that information in your reply to the reply above. Come on guys, get it together.
goddamnit guys, IFTTT = If This Then That = A web service thing that lets you make something happen when something else happens or something like that
Sorry for not including the information. After a quick look at the page https://ifttt.com/ I decided it isn’t worth to spend more time on it.
I think this one could be used as an example. Instead of using deep sleep, it just urns itself off completely. Pressing the button powers it again. Of course this means you’ll have to wait a bit longer for it to respond because it first needs to boot, but that shouldn’t be a problem voor dash-button like applications.
http://blog.eikeland.se/2015/07/20/coffee-button/
urns = turns
voor = for
NodeMCU V0.9 already has a USer button on the board and an led if you want a response. trivial to power it from two AA batteries
I believe it is the same button on both boards – GPIO00, which is also the “flash” button. No particular reason to go with one board over the other except for price as far as I can see.
Does any EU based webshop sell the EZSBC ESP8266-07 ?
You could look at getting the NodeMCU board, which is essentially the same thing. These can be had on ebay for $7 us and ship from China, so I assume you could get one in Europe. I have ordered one to test with and am guessing that the code will work with little or no modification.
I have wondered why the ’07 version of the SoM seems less popular. I has both an onboard antenna and a socket for an external one, and the same foot print as the ’12 making it compatible with their breakouts.
I do not understand why the line: node.dsleep ( 0 , 4 )
is not written in any of the three files. (ifttt.lua, init.lua, setwifi.lua) of the PowerSaving version.
Where should I place it?
I recently updated my intro IoT/esp8266 project tutorial to use IFTTT instead of Twilio to send SMS in response to a single button input. http://hammerproject.com/post/130804023369/iot-intro-sms-me-when-i-leave-my-garage-door-open
The input can be anything, and since it connects to IFTTT now, you can use any “that” you like. So go mad and I’d appreciate any feedback.