ESP8266 Remote Control for Alexa

Hi,

I am searching the whole day for a solution to create a Remote Control with an ESP8266 to switch on devices like lights trough Amazon Alexa. I don't want to remote everything with the voice assistant. I found out that the Echo Button is supporting the feature to start routines over alexa after a click, so I thought that there could also be an emulation software for the ESP8266 to emulate an Echo Button to trigger a routine in Alexa.
There are also some Wall Light Switches on the market, that can trigger an alexa action and I found this one GitHub - witnessmenow/esp8266-alexa-wemo-emulator: multiple belkin wemos switch emulator using ESP8266. But I think that it's only for switching on an ESP8266 Pin output through the voice assistant.
You can find so many tutorials to trigger an ESP with the voice assistant but not the other way arround :confused:

I don't see what you are after? Alexa is just that, a voice assistant operation.

Your description is confusing......"so I thought that there could also be an emulation software for the ESP8266 to emulate an Echo Button to trigger a routine in Alexa. "

Well, it's not "in" Alexa but via Alexa voice assistant. The light switch can be switched on/off manually locally too.

If you want to trigger the 'light' with Alexa via pushbutton then that is in the Alexa app on your phone. Your devices show up there and you can switch on and off via the button.

Alexa is a voice assistant of a home automation. so the esp8266 should speak to her :slight_smile:

or let the esp8266 be the other assistant and call the same functions Alexa does.

for example if the light is controlled by Wemo, you could call the Wemo API. but that is pretty low level

so your best option is to use IFTTTT

From his post "I don't want to remote everything with the voice assistant. "

I still can't quite work out why he wants to use pushbuttons via Alexa sevice which is meant as voice recognition.

There are other services for that without Alexa

DISCLAIMER: I know nothing about Amazon Assistant beyond what I can find on the internet in 2 minutes

The echo button appears to be a bluetooth device that can pair with your existing "Alexa" product. Rather than a device to be controlled by Alexa it appears to be an alternative input method to the usual voice command. Quick primer here

The ESP8266 will not emulate an Echo Button since it doesnt have bluetooth onboard. A board like the ESP32 with bluetooth could in theory do it but no-one seems to have published such a thing.

It would be interesting what use the OP has in mind for such a function if it did exist..

Good Morning,
I would like to achieve the same.

Related to that I've found 2 different things:

Well I've emulated inside alexa following this :

https://bitbucket.org/xoseperez/fauxmoesp/src/master/README.md

with success, means that Alexa discover the devices and I'm able to manage it from Alexa App. But should be nice to have a simply button create with ESP8266 and the idea to follow for me is what is mentioned in above link for PhS. Basically the system wake up, connected to network, retrieve the state, apply the new state go to sleep again.

For to that we should be able to emulate the alexa command packet. I did a wireshark session that I attach here but I'm not able to find something clear. THE LAMP is 192.168.15.108 maybe if we can extract the basic command we can create a packet to send directly.

Please update me,

best regards
Andrea

The answers so far miss what Alexa actually is. It's not just a voice assistant. She is a home speaker system, entertainment system, gaming system. And you can set up very useful routines that interact with various smart devices in a specific order and time. With multiple Echos throughout the house we have found it very useful to have Alexa as an intercom and announcement system as well.

That being said, it would be extremely useful to be able to program ESP8266's to trigger routines or start intercom functionality or switch the music to all speakers or tell me the plants are dry or tell me the oven was left on... the possibilities are endless.

I don't understand why this application hasn't been realized and tutorialized online yet.

1 Like

"I don't understand why this application hasn't been realized and tutorialized online yet."

Perhaps you can list all the Alexa control methods so they can be evaluated for how an ESP8266 can be interfaced with the Alexa.

Would you like, for example, tell alexa what the room temperature is and what does it tell you? or you just want to turn a bulb on and off?

I'm also looking for a solution to this. Or at least a direction on where to start to build my own. OP is saying he wants the esp8266 to send a command to Alexa. Say for instance I have a light sensor on my esp, so when I turn on the lights in my room the esp will send a command "Alexa, Play Music".

There are loads of tutorials on how to go from Alexa -> ESP but not ESP -> Alexa.

"There are loads of tutorials on how to go from Alexa -> ESP but not ESP -> Alexa."

Does Alexa have a web server function, ie, can be controlled from a web page or similar?

Take a look at gadgets and echo buttons.

I'm working on this, too. I learned that you can't connect an ESP8266 to AWS (Amazon Web Service) because it doesn't have the right security. You can connect a MKR Wifi - but then it gets very complicated. You can hack ESP8266 into Alexa by emulating WEMOS, but again, one-way.

It's pretty straightforward to connect a Nano 33 IoT to the Amazon Cloud, and Alexa can pick up your device from the Amazon Cloud - but again, Alexa can see it, read from it (e.g. temperature) and change it, but the NANO can't launch a Routine on Alexa. (My NANO can tell the temperature of the chicken I'm roasting on the grill outside, and I want Alexa, in the house, to tell me when it's done)

This is the post I put on a different forum (Gigs and Collaborations):

I have successfully created a Thing in the Arduino cloud using a Nano 33 IoT board and the Smart Home Property Type: Motion Sensor. Both the Dashboard on IoT Cloud and the Devices on my Alexa App can see the status of the motion detector connected to the Nano.

HOWEVER - I am unable to create a New Routine on the Alexa App that does anything with the Motion Sensor information.

When I select "New Routine", then "When this happens" the menu is Voice, Schedule, Smart Home, Location, Alarms, Echo Button, or Guard. I select Smart Home, and expect to see my Arduino Motion Sensor, but the only option there is "Dallas Living Room, Echo Plus", which is the temperature in my living room.

Has anyone been able to trigger an Alexa Routine from a Motion Sensor connected to the Arduino Cloud?

I am looking for the same thing, to be able to trigger an Alexa routine from something connected to the Arduino Cloud. Has anyone had any luck? Thanks!

My solution is to get an earbud speaker and put it on a little microphone on your Alexa. Then record the audio of u triggering the routine. Then you can play that from your esp8266 through the little speaker and your Alexa will play the routine.

1 Like

I have been doing a great research about how to interact from an arduino to Alexa, specally triggering routines. As we know there is much information about the communication Alexa-Arduino but not the other way around. I will try to simplify what I found.

The solution given by @rednadOzeuven is feasible. I started with this solution some months ago with an Adafruit MP3 shield for arduino. It worked out well but is not the most precise solution, as the environment noise can interfere.

There are some IoT web services that can help you with this. You can create virtual switches that are recognized by the Alexa app in order to trigger a routine. These virtual switches can be operated by an Arduino with WIFI capabilites. Pretty easy setup.

The feasible ones I found are Sinric and Smartnest, as well as Ardiuino IoT. Have a look on them.
The problem is that they just have found the profit they can get with this and have changed their platform from free to paid subscrption. You still can have somewhere up to 5 devices aprox. for free but in case you want to interact with some more you will have to pay. Sinric is still on its transition, so the old free server is still operative for you to try. Be carefull as they intend to migrate to the paid one soon and you could lose it all.

There is another one of this kind called Supla which seems to work in the same way. This one is fully free but seems to be a little bit more complicated as the code and instructions are not so clear. Haven´t tried this last one though.

I´m waiting to find a totally free kind of Sinric server as this is the simplest method to work with. For the time being I´m working with another method, working through OpenHab.

OpenHab is a Home Automation free and open source platform which, among hips of things, lets you directly interact with your alexa device through the WIFI. It also lets you interact with your arduino so this means that i am able to press a button in arduino and an alexa routine is triggered. The OpenHab method is kind of complicated but it works.

Anyone who is interested in this method can text me, i will be please to help as others have helped me.

I realize this is a fairly old thread, but there is a way to trigger Alexa Routines with an ESP8266. See this Github project for more info: GitHub - Thomptronics/ESP8266-Virtual-Buttons: How to use Virtual Buttons to trigger Alexa Routines with an ESP8266