Great demo, all you're demos are great... I have a 4way switch I didn't even want to think about adding automation to until I saw this video. The addition of a current sensor was something I had never thought about.
Very nice demo and explanation, I have found that many do not understand how 4 way (DPDT) switches operate requiring a 3 way (SPDT) at the source and load ends of the chain. I am new to the Pi Arduino and ESP world so this was quite useful. A suggestion for your proof of concept and demos would be to use 12 Vac lamps on the bench to eliminate the shock hazard. I specified 12Vac as the current transformer would not work on DC.
Sweet setup, I like the idea of still being able to use regular switches if the ESP board has problems. I have setup 8 lights in my house so far with regular wall switches, google home & home assistant all working nice together on 2 ESP boards talking to home assistant via mqtt and light switches us GPIO's on ESP board to change state and relay via mqtt to keep all in sync but if an ESP board goes, I have no light control. Might have to look into integrating your setup into my own :). My setup was first inspired by your videaos so thank you again :).
Great job on the video. I am just starting out with DIY home automation. I am excited about the possibilities and availability of components. I love how you are using the relay as a 3-way switch in the circuit along with a current sensor and how this allows the manual switches to continue working in the event of a failure of the home automation hardware. I will be using the AdaFruit Huzzah breakout ESP8266 board. Unfortunately, is only has two analog inputs for the current sensors. A digital input to detect the load going "hot" would allow for more inputs and would not be subject to changes in the Amps drawn on the load if bulbs burn out (which may be a non-issue). I just got my Raspberry Pi working with OpenHAB2 and Mosquitto. Now on to the hardware! Liked and Subscribed :-)
I do love your tutorial with one exception, using these mains switches with exposed screw is not a good practice at all - I cringed at 18:54 were the ESP is just about to touch the mains wire on the switch!!!!!!!!!
First Winner -- Reverie Quest, congratulations your are the first winner of the NodeMcu. Please send me your mailing address in private message so I can mail you your brand new NodeMcu. Thank you again for leaving comments.
I was able to get this working and was wondering if anyone could direct me to a document or website that could help explain the coding. Especially regarding the the startHttpServer() function. I would like to learn more about how this is working with Alexa. Thanks!
Breno Sabino you can control multiple switches with single ESP but this switch configuration is for one device only. You can look at my tutorial on controlling multiple relays with single ESP. ua-cam.com/video/OC6QSXzkQU8/v-deo.html
Hello Netmedias! Your videos are awesome and very descriptive, congratulations :) I was wondering if something similar can be done with sonoff 4ch pro r2. I think that the 4 needed GPIOS for the current meter inputs can be soldered directly to the ESP8285 SOC pins , isn't it?
Netmedias Excellent! I’m wondering the same about sonoff dual with a current sensor add flashed with tasmota? Very interested in your work here. Pointers appreciated.
Greetings , I wanted to say a big THANK YOU for the NodeMCU. I was one of your winners. I appreciate it so much. Now, off to the shop and build, build, build. Rick
I have a sonoff 4 ch pro and 4 two-way switches...I want to connect them such that when I will use the regular two-way switch it will get sync within the app as well. Is this possible? Please help...
Hi . i need some assistance from u . is it ok to help me out . i have a 4 channel relay , and a 8 channel relay , nodemcu and also echo dot .. so was planning to do some automation for my bed room . i have connected to dc supply till now to switch on the relays . it works fine all with the dc voltage in normal way giving commands to echo dot to switch on all 4 channel relay and 8 channel relay board , but moving on to ac connection the problem how to connect it with the nodemcu . in this video you have connected to a single channel relay right . also some kind of sensor which u were talking about in the diagram to Ao pin in nodemcu along with the 3 way switch ... how should i connect the 4 channel relay or the 8 channel relays to ac voltage with the nodemcu as per it has only one Ao pin . other thing is that here that sensor is not available in India . in your other video you have replaced it with a diode and a resistor right .. but even still how i can connect the both 4 channel relay or the 8 channel relay to nodemcu to notify the ecodot that if i switched on the 3 way switch it is already on as per nodemcu has only one Ao pin . i do not know much about elctronics or about the nodemcu .. and the programing .. but connected and programmed it watching many videos only . so if you help in this one it will be a great thing to me . hope you will . can you do a video how to connect the 4 channel relay
Awesome tutorial. How would you do the wiring on a typical 3-way lighting setup that uses 2 x 3-way mechanical switches (i.e. one switch is it at one end of the room and the other one at the other end)?
@@netmedias7657 Thanks, so let me summarize: I need to replace one of the 3-way switches with a 4-way one and wire it along with the ESP module, did I understand well?
Hi, in 3way installation you placed current sensor at the beginning(between plug and switch). In the 4 way installation you placed the sensor between relay and the bulb. Could be current sensor in 4way installation at beginnig? (on the 4way scheme on the left before first 3way switch). Thank you in advance
Basic idea here... but doesn't work with all 3-way/multi-way switch configurations. If you don't have this situation, then you'll need multiple Sonoff's and some sort of automation, ala Home Assistant, to do the work in software. www.dropbox.com/s/h94truyd6d9c8w3/2018-01-08%2014.14.01.jpg?dl=0
I think you have an error in your code. You don't have sendRelayState funtion defined at the end. You have Turnonrelay and turnoffrelay but no sendrelaystate. So when I compile. System don't find it. I have found it and now compile good.
Is it possible to measure the voltage at the relay common pin instead of measuring the current flowing through the relay common pin to ascertain if the switch is on? I would like to remotely switch a power point while retaining the manual switch. With your setup the chip would see the power point as being switched off when actually on but no load applied.
Thanks for your reply. If wired to a power point with no load, ie. no current flowing through relay common pole for the CT to detect, the ESP8266 board could wrongly see the power point as being switched off when the power point may be still live. I would want to the power point to switch off regardless of attached loads are switched on or off.
Sir I am using NodeMCU with 8ch 5v relay board.I am using same manual switches also as you shown in your video but if I wish to use current sensor with all 8 relay how should I connect those? Because there are only one A0 pin in nodemcu.
hello, I need to ask you that if the ALEXA and Google Assistant code are built-in into your arduino code or we still using HEROKU. I see that in the Arduino code there are serial lines. What are these lines for
This project does not require any skills for Alexa. You only need the sketch to get your device working. You can use IFTTT to make it work with Google Home.
Hi I think your tutorials are great and you explain things well but the wire you use makes the project very messy. The use of coloured wires would be better.
very nice and useful info with detailed tutorial..thanks and keep it up. will definitely get help from this setup when i will start my home shifting to automatic and i will use this setup to turn on/off my solenoid motor from ground floor and first floor.
Just noticed this, perfect for a project I'm thinking about. I've ordered all the parts needed except for the current sensors which are not available in the UK :(. Is there an alternative such as the solid state current sensors that are widely available or is it possible for your design to work without a current sensor. Many thanks, Keith
Hi, thanks for the code and tutorial, it is great. I am trying to use this on a Wemos D1 mini, i am struggling to get the ADC input pin. the pinout just says A0, but i cannot figure out how this translates to a pin number. Any advice would be really helpful. Thank
Hi, thank u for sharing this kind of videos, many thanks from South América! Is it possible to do this circuit without the current meter? We can't get it in my country and if there are one it could cost about 15usd! So i dont know if is possible to replace this part with other device or control since software! I cant get the way, and probably you can guide me.. thanks
tiwar87 It is easy to make one if you have time. Yes you can use it without the current meter. Alexa won't know if device is on or off but you can still control it with your voice.
Netmedias yes I know that can control the Alexa with or without the current sensor but the way you implement it to recognize it is the best way for me. I Will try to find the way to do a current sensor. Thanks for the advice, keeping forward
thanks for the helpful video, is the second tutorial I do in my home, I have one question, if I have two lights, how can I name more than one name in the code?
im trying to purchase the current sensor from ebay but i cant figure out which model you are using..can you post model# or share link for current sensor
You are awesome! I already watched all of your Alexa Tutorials. You are the reason, why I am successfull in my smarthome project. I hope you are going to produce more Videos like this one. My wish is, that you make a Tutorial, how to build own Alexa skill, which works like Standard Alexa smarthome Skills, so I dont need to say"alexa ask skill to turn the light blue" just "alexa turn the light blue" Thanks Nice work
Dima Z your feedback is greatly appreciated. To do that you need to create your own Alexa device using Pi and Alexa AVS (Alexa Voice Service) . github.com/alexa/avs-device-sdk
@@netmedias7657 hi i got some problem on (esp-12f doiting) on console only show little figures no show any comand on serial port i check all too many times and change on 2 esp boards too
Nice work.. If I just wanted an upstairs and downstairs switch plus the nodemcu (not 3 physical switches), can I just replace the last switch in a 3 switch configuration with the relay? and if so, does anything need to change in your arduino code?
Mark Porridge Yes sir. You are right. In two switch configuration make sure last switch that connects to the device is 4 way switch. If not the replace it and connect the relay.
This is a great proyect thanks for shear, I already made it but it does not responds all time, it turns off when it suppose not to do it or viseversa but it shows in the serial that it is taking the measurements of the current sensor but does not responds according to those reads. I already set the current value according to the sense in the program.Do you have any idea what could be happening, Thanks in advance.
bruno gonzalez It means that you current meter current reading is fluctuating. Try to take reading few times and set the trigger at the lowest current measurement. Let me know if you are still having issues. Good Luck.
Thanks for your respond, I have 155 when lamp is on and 17.3 and 34.5 when is off so I set it to 35 but still having the same problem as soon as I figure out how to solve this will let you know, my filling is that it is not sensing the current before doing the comand. My best regards. Im working with NodeMCU 1.0
hI still not resonding at it should, im still looking for a solution, in your video you turn on and off but you did not turn on demo swich when it is on or turn it off when it is off, Is it doing it well for you? because there is where I have the problem. I dont know if someone else has my same problem. My best Regards.
bruno gonzalez I am not sure if I understand what you are trying to do. Are you saying that it does not turn on and off from Alexa? If it is on, then you should be able to turn it off from Alexa or vice versa.
I don't want to win one of those nodemcus because I live in Germany and the shipping is probably more expensive than just ordering one myself. I think your videos are great anyway. I'm thinking of doing such an automation on my own as well
Hi, very nice project and very easy explanation!! I’m going to do something similar to my apartment, my intention is to connect to the same board 4 series of buttons (I would like to manage 4 different lights with one board), I think I need to change the board and I was more oriented on a MKR1000 that has more analog ports and wifi connection but my question is, can Alexa manage 4 lights points with one board? I’m still learning skills but your help can help me to understand if the project is fine (and to proceed to order the material) Thanks for your kind reply
This was a good video but one thing that will make it much better is when you are wiring the relay instead of saying wiring to the left and right terminals, tell if it is the normally closed or normally open terminals because not all have the terminals in the same place.
Eric Hughes Yes sir. I am doing that. I mentioned my relay default at 5:03. Anyway in this configuration it does not make any difference as long as common pole is connected to the device.
Do you think it would be a good idea to replace the induction current sensor with an optocoupler, resistor and capacitive dropper circuit? It's a bit more invasive but i had the parts laying around so i would rather not buy another sensor.
SilentDreamcast It should work but it complicates things and I wanted to keep it simple. It is good to separate low and high voltage with optocoupler. Let us know how it goes. Good luck.
Great video's well explained and already starting to use your projects! Would like to see how you provide power when these are placed permanently in an electrical box, and if wireless had any issues working in the wall .. thanks !!
Ross Romeo thank you for your feedback. Please share your thoughts what you like and dislike about the videos for I can make improvements. Good luck with your projects.
Hi there, Love watching these tutorials, my living room wiring is slightly different, is it possible to control the circuit below with NodeMcu? Any advice would be appreciated. upload.wikimedia.org/wikipedia/commons/thumb/d/d1/California-3-way.svg/800px-California-3-way.svg.png
Great tutorial!!! I'd like to do the same but with 8 channel relay board and using it as mqtt swicht on home assistant so i can control with google home, HA and real wall switch. Is it possible?
nice ,i only wish there was a way to do it without running additional wires i have an outside light but it only is wired for a regular switch not a 3 way ,plus i would need to run wires for the current sensor too if i want the board mounted in the light
Andrea Mitchell you don't need to run additional wires if you are trying to make Alexa 3 way switch. Just replace your toggle switch with 3 way switch and connect NodeMcu as shown in 1st demo. Good Luck!
Jarren141 Please do suggest a better name for the video. Electrical switches are bought from Lows and NodeMcu,relay and current monitor from eBay. If you want them quicker then order them from Amazon.
Thomas360xbox Bass You can only flash one sketch at a time. You can use one sketch to control multiple devices. Check out my tutorial on how to control two devices with single sketch. Good luck. ua-cam.com/video/OC6QSXzkQU8/v-deo.html
Benjamin H I am glad that this video will be help full in your project. Please do share with us how you will use and improve this project in your implementation. Good Luck with your projects.
First of all, thank you. Your videos are very helpful and very in depth. I like the step by step instructions you provide along with code for project. However, some of the videos are just a bit too long. Like this one, i find myself skipping forward sometimes.
Dave Thank you for your valuable feedback. I agree with you and planning to make them around 10 to 15 minutes. Let me know what would be the ideal length?
Hi man,i enjoyed watching your videos,i have a little understanding on computers and electronics and i want to have my house automized,just one question,is this system for 22OV?or just 110V?thanks for sharing
Thanks man,for the relay,let say i want to control 5 or more units at home,i would just buy a bigger relays and use the same set up?appreciated your comment sir...
You are very thorough on your videos. I like the way you mix in power point slides and video. There in no doubt you spend a lot of time on these. Have you looked at using a Wemos in place of the NodeMCU? It had a smaller foot print as it has fewer GPIO, but based on the ESP. A side note, the current sensor can be installed on the wire from the relay to the light, which would put it in the same box as the relay and Node. You ultimately are trying to determine when current is flowing to the bulb. Keep up the great work!
It is a Wemos, not Wemo. Wemo is a brand of IOT components from Belkin. Wemos is an ESP8266 board with 5 volt regulator, FTDI and several other things all one 1 board. Basically the NodeMCU's little brother.
Thomas360xbox Bass You should be able to use any current sensor that can detect the current at 3 to 5 volts level. I have couple of dufferent ones and they work fine.
What is the use of current sensor? is it just to tell whether the load is on or off? or is it for measuring how much current its drawing ? If i dont want to install the current sensor if its there for demo purposes only, how to wire schematic then?
On/off is not required. Just testing to make sure it works with manual switch only. I am using active high relay. You can check my following video to learn how to convert active low relay to active high. ua-cam.com/video/pBxeHlvF4eQ/v-deo.html
@@netmedias7657 Thank you for the reply. I have an issue maybe you can help with. When I verify code in Arduino IDE, it has this error. "Error compiling for board NodeMCU 1.0 (ESP-12E Module). /Downloads/IOT-NodeMcu-Alexa_Automation_4Way_Switch-master/current_sensor/current_sensor.ino:194: undefined reference to `sendRelayState()'" I know this video is a few years old, is it possible that an update to IDE or other libraries has broken your code? Thanks
I am not sure why you need to do this. This is very dangerous to do it your self. Seek a professional help.Usually most houses in US use 100 to 200 amps mains connection. You need to make sure you get a correct relay based on your connection rating. You will need a heavy duty relay that can handle this kind of load.
If I stop the light from Alexa, the relay may be in the NO position, and the current is cut off, we can have lights on in the middle of the night, or the program remembers the last state on power failure?
Imagine the following scenario; we turn the light on from the switch 1 and turn off the light from the voice command. if the power is down (disconnecting the plug from the socket), the program will know the last state and will keep the light off, when pluging on again?
Rainmaker LLC can check out the following current meters. I have 3 different ones. You can also buy it on Amazon and ebay. Good luck. www.banggood.com/0-5A-Iteaduino-AC-Current-Transformer-Current-Sensor-Module-With-3p-4p-Interface-p-1068624.html?rmmds=search&cur_warehouse=CN www.banggood.com/5A-Range-Single-phase-AC-Current-Transformer-Current-Sensor-Module-p-1228113.html?rmmds=detail-left-hotproducts__1&cur_warehouse=CN
Updated Video ua-cam.com/video/5SgB6wzgxY0/v-deo.html
Great demo, all you're demos are great... I have a 4way switch I didn't even want to think about adding automation to until I saw this video. The addition of a current sensor was something I had never thought about.
Thank you. Good luck with your project.
Very nice demo and explanation, I have found that many do not understand how 4 way (DPDT) switches operate requiring a 3 way (SPDT) at the source and load ends of the chain. I am new to the Pi Arduino and ESP world so this was quite useful. A suggestion for your proof of concept and demos would be to use 12 Vac lamps on the bench to eliminate the shock hazard. I specified 12Vac as the current transformer would not work on DC.
This is one of the great tutorial I have seen . Thank you so much for your great video and your efforts .
e service consultancy Thank you.
Sweet setup, I like the idea of still being able to use regular switches if the ESP board has problems. I have setup 8 lights in my house so far with regular wall switches, google home & home assistant all working nice together on 2 ESP boards talking to home assistant via mqtt and light switches us GPIO's on ESP board to change state and relay via mqtt to keep all in sync but if an ESP board goes, I have no light control. Might have to look into integrating your setup into my own :). My setup was first inspired by your videaos so thank you again :).
Great job on the video. I am just starting out with DIY home automation. I am excited about the possibilities and availability of components. I love how you are using the relay as a 3-way switch in the circuit along with a current sensor and how this allows the manual switches to continue working in the event of a failure of the home automation hardware.
I will be using the AdaFruit Huzzah breakout ESP8266 board. Unfortunately, is only has two analog inputs for the current sensors. A digital input to detect the load going "hot" would allow for more inputs and would not be subject to changes in the Amps drawn on the load if bulbs burn out (which may be a non-issue).
I just got my Raspberry Pi working with OpenHAB2 and Mosquitto. Now on to the hardware!
Liked and Subscribed :-)
Dave Z Thank you for your feedback. Please keep us up to date on your progress. Good luck on your projects.
Great video, very easy to understand. Thank you for take your time to teach us.
fidel castillo than you for your feedback.
Man you are doing a great job keep up the good work
I do love your tutorial with one exception, using these mains switches with exposed screw is not a good practice at all - I cringed at 18:54 were the ESP is just about to touch the mains wire on the switch!!!!!!!!!
Another great tutorial man. Only what are your plan for powering the node mcu or esp board?
Sebastiaa thank you.
I'm sure it is another great Tutorial Video :). Do I win for having the first comment lol? Watching Now.
Paul Formosa You have better chance on wining one with early post.
I don't think it matters which way they arrow points in this case since its AC. Great video!
Jerry McKee thank you for the correction.
First Winner -- Reverie Quest, congratulations your are the first winner of the NodeMcu. Please send me your mailing address in private message so I can mail you your brand new NodeMcu. Thank you again for leaving comments.
I was able to get this working and was wondering if anyone could direct me to a document or website that could help explain the coding. Especially regarding the the startHttpServer() function. I would like to learn more about how this is working with Alexa. Thanks!
Awesome! Would it be possible to control three lamps in a four way setup using a single esp8266 by adding more relays?
Breno Sabino you can control multiple switches with single ESP but this switch configuration is for one device only. You can look at my tutorial on controlling multiple relays with single ESP.
ua-cam.com/video/OC6QSXzkQU8/v-deo.html
Hello Netmedias! Your videos are awesome and very descriptive, congratulations :) I was wondering if something similar can be done with sonoff 4ch pro r2. I think that the 4 needed GPIOS for the current meter inputs can be soldered directly to the ESP8285 SOC pins , isn't it?
I am working on it thanks
Netmedias
Excellent! I’m wondering the same about sonoff dual with a current sensor add flashed with tasmota? Very interested in your work here. Pointers appreciated.
Greetings , I wanted to say a big THANK YOU for the NodeMCU. I was one of your winners. I appreciate it so much.
Now, off to the shop and build, build, build. Rick
Rick Prime Thank you for your feedback and good luck with your projects.
I have a sonoff 4 ch pro and 4 two-way switches...I want to connect them such that when I will use the regular two-way switch it will get sync within the app as well. Is this possible? Please help...
Hi . i need some assistance from u . is it ok to help me out . i have a 4 channel relay , and a 8 channel relay , nodemcu and also echo dot .. so was planning to do some automation for my bed room . i have connected to dc supply till now to switch on the relays . it works fine all with the dc voltage in normal way giving commands to echo dot to switch on all 4 channel relay and 8 channel relay board , but moving on to ac connection the problem how to connect it with the nodemcu . in this video you have connected to a single channel relay right . also some kind of sensor which u were talking about in the diagram to Ao pin in nodemcu along with the 3 way switch ... how should i connect the 4 channel relay or the 8 channel relays to ac voltage with the nodemcu as per it has only one Ao pin . other thing is that here that sensor is not available in India . in your other video you have replaced it with a diode and a resistor right .. but even still how i can connect the both 4 channel relay or the 8 channel relay to nodemcu to notify the ecodot that if i switched on the 3 way switch it is already on as per nodemcu has only one Ao pin . i do not know much about elctronics or about the nodemcu .. and the programing .. but connected and programmed it watching many videos only . so if you help in this one it will be a great thing to me . hope you will . can you do a video how to connect the 4 channel relay
Awesome tutorial. How would you do the wiring on a typical 3-way lighting setup that uses 2 x 3-way mechanical switches (i.e. one switch is it at one end of the room and the other one at the other end)?
It is simple. Just remove the middle switch and rest is same.
@@netmedias7657 Thanks, so let me summarize: I need to replace one of the 3-way switches with a 4-way one and wire it along with the ESP module, did I understand well?
What if i use multiple led light, do i need a current sensor to each and every one of them? Or just one sensor for all the lights? Thanks.
This might be something that will work with eMylo remote control receiver, correct?
can i use 4 sensors to control 4 relays
Can a PIR module be connected in parallel for automatic ignition and add control with switches?
You will need to modify the code and add timer so it stays on for required time.
Hi, in 3way installation you placed current sensor at the beginning(between plug and switch). In the 4 way installation you placed the sensor between relay and the bulb. Could be current sensor in 4way installation at beginnig? (on the 4way scheme on the left before first 3way switch). Thank you in advance
Can you show how to integrate multiple sonoff 4ch pros to existing home wiring along with Amazon echo and raspberry pie 3?
pulseps I added the project to my list Thanks.
Basic idea here... but doesn't work with all 3-way/multi-way switch configurations. If you don't have this situation, then you'll need multiple Sonoff's and some sort of automation, ala Home Assistant, to do the work in software. www.dropbox.com/s/h94truyd6d9c8w3/2018-01-08%2014.14.01.jpg?dl=0
When I compiling I have this error "current_sensor.ino:191: undefined reference to `sendRelayState()'". Please help me.
I think you have an error in your code. You don't have sendRelayState funtion defined at the end. You have Turnonrelay and turnoffrelay but no sendrelaystate. So when I compile. System don't find it. I have found it and now compile good.
Awesome man, just got started on this myself.
brendanvanbreda Please share your progress with us and lets us know how we can improve on it. Thanks for your feedback.
Is it possible to measure the voltage at the relay common pin instead of measuring the current flowing through the relay common pin to ascertain if the switch is on?
I would like to remotely switch a power point while retaining the manual switch. With your setup the chip would see the power point as being switched off when actually on but no load applied.
John Silvester this is what is I am doing in 4 way switch in this video. Thanks for you comments.
Thanks for your reply.
If wired to a power point with no load, ie. no current flowing through relay common pole for the CT to detect, the ESP8266 board could wrongly see the power point as being switched off when the power point may be still live.
I would want to the power point to switch off regardless of attached loads are switched on or off.
Sir I am using NodeMCU with 8ch 5v relay board.I am using same manual switches also as you shown in your video but if I wish to use current sensor with all 8 relay how should I connect those? Because there are only one A0 pin in nodemcu.
hello, I need to ask you that if the ALEXA and Google Assistant code are built-in into your arduino code or we still using HEROKU. I see that in the Arduino code there are serial lines. What are these lines for
This project does not require any skills for Alexa. You only need the sketch to get your device working. You can use IFTTT to make it work with Google Home.
can this be done on a sonoff device? like the manual switch will still work even if something bad happens with the sonoff device.
Ruel Baclay NO, because it has 2 pole relay and you need 3 pole relay for this project.
Hi, Great work :)
Will it work with Wemos D1 Mini as well ? I gues some recoding will be needed.
Daniel Kozłowski Yes, no recoding only update the GPIOs. Good luck.
Thx :) I thought so :) I will try to make it working after all parts will arrive.
Hi I think your tutorials are great and you explain things well but the wire you use makes the project very messy. The use of coloured wires would be better.
Harry Powney Thank you for your valuable feedback. I will keep this in mind for future projects.
very nice and useful info with detailed tutorial..thanks and keep it up.
will definitely get help from this setup when i will start my home shifting to automatic and i will use this setup to turn on/off my solenoid motor from ground floor and first floor.
Best of luck
I was going to automate some of our lights. Now that II saw this I bought some 4 way switches to interface with the esp32 and 8266
Good luck. Share your progress with us.Thank you
i like this.its a new project.thanks.
Do it without internet, or it's just a stupid thing to do.
best bideo EVER
Pavel Diaz Thank you.
no what I'm trying to ask is can i guest use the relay and nodemcu with the arduion download
Thomas360xbox Bass Yes. You will need to modify the sketch a bit. Let me if you need help.
AC = Alternating Current so witch way the arrow of the sensor points does not matter.
Nicklas Persson thanks for clarification. It is for DC only the.
Just noticed this, perfect for a project I'm thinking about. I've ordered all the parts needed except for the current sensors which are not available in the UK :(. Is there an alternative such as the solid state current sensors that are widely available or is it possible for your design to work without a current sensor. Many thanks, Keith
Hi, thanks for the code and tutorial, it is great.
I am trying to use this on a Wemos D1 mini, i am struggling to get the ADC input pin.
the pinout just says A0, but i cannot figure out how this translates to a pin number.
Any advice would be really helpful.
Thank
Try 2 for A0.
Great, will do thanks!
Hi, thank u for sharing this kind of videos, many thanks from South América! Is it possible to do this circuit without the current meter? We can't get it in my country and if there are one it could cost about 15usd! So i dont know if is possible to replace this part with other device or control since software! I cant get the way, and probably you can guide me.. thanks
tiwar87 It is easy to make one if you have time. Yes you can use it without the current meter. Alexa won't know if device is on or off but you can still control it with your voice.
Netmedias yes I know that can control the Alexa with or without the current sensor but the way you implement it to recognize it is the best way for me. I Will try to find the way to do a current sensor. Thanks for the advice, keeping forward
what power source are you using to power the nodemcu when you connecting it to the outlet junction box
bobby royster I use "HLK-PM03" or "HLK-PM01" for 5 volts just google it.
thanks for the helpful video, is the second tutorial I do in my home, I have one question, if I have two lights, how can I name more than one name in the code?
im trying to purchase the current sensor from ebay but i cant figure out which model you are using..can you post model# or share link for current sensor
Can we use ir remote and Alexa both to on or off a light??????
Yes, but I will suggest using RF remote instead of ir since you don't need line of site for it to work.
Please tell something about applicatins solid state relays.
Quite, Fast switching and small.
Ok is there any way you can make a video with Alexa , nodemcu , and 2 relays
Thomas360xbox Bass take look at following tutorial.
ua-cam.com/video/OC6QSXzkQU8/v-deo.html
You are awesome! I already watched all of your Alexa Tutorials. You are the reason, why I am successfull in my smarthome project. I hope you are going to produce more Videos like this one.
My wish is, that you make a Tutorial, how to build own Alexa skill, which works like Standard Alexa smarthome Skills, so I dont need to say"alexa ask skill to turn the light blue" just "alexa turn the light blue"
Thanks
Nice work
Dima Z your feedback is greatly appreciated.
To do that you need to create your own Alexa device using Pi and Alexa AVS (Alexa Voice Service) .
github.com/alexa/avs-device-sdk
Do you have a way of control PWM like a FAN or Dimable LED module by alexa?
大谷興冶 Dimmable project is coming soon. Stay tuned.
Thanks. I'm looking forward to it.
BEST WAY BROO of all videos i see of same prototipe ... great video
Glad you liked it
@@netmedias7657 hi i got some problem on (esp-12f doiting) on console only show little figures no show any comand on serial port i check all too many times and change on 2 esp boards too
Does node mcu work by connecting to hotspot
Yes
Nice work.. If I just wanted an upstairs and downstairs switch plus the nodemcu (not 3 physical switches), can I just replace the last switch in a 3 switch configuration with the relay? and if so, does anything need to change in your arduino code?
Mark Porridge Yes sir. You are right. In two switch configuration make sure last switch that connects to the device is 4 way switch. If not the replace it and connect the relay.
This is a great proyect thanks for shear, I already made it but it does not responds all time, it turns off when it suppose not to do it or viseversa but it shows in the serial that it is taking the measurements of the current sensor but does not responds according to those reads. I already set the current value according to the sense in the program.Do you have any idea what could be happening, Thanks in advance.
bruno gonzalez It means that you current meter current reading is fluctuating. Try to take reading few times and set the trigger at the lowest current measurement. Let me know if you are still having issues. Good Luck.
Thanks for your respond, I have 155 when lamp is on and 17.3 and 34.5 when is off so I set it to 35 but still having the same problem as soon as I figure out how to solve this will let you know, my filling is that it is not sensing the current before doing the comand. My best regards. Im working with NodeMCU 1.0
bruno gonzalez set it to 150
hI still not resonding at it should, im still looking for a solution, in your video you turn on and off but you did not turn on demo swich when it is on or turn it off when it is off, Is it doing it well for you? because there is where I have the problem. I dont know if someone else has my same problem. My best Regards.
bruno gonzalez I am not sure if I understand what you are trying to do. Are you saying that it does not turn on and off from Alexa? If it is on, then you should be able to turn it off from Alexa or vice versa.
I don't want to win one of those nodemcus because I live in Germany and the shipping is probably more expensive than just ordering one myself.
I think your videos are great anyway. I'm thinking of doing such an automation on my own as well
Bastian Springer Don't worry Sir. If you are a lucky winner I will ship it to you.
Hi, very nice project and very easy explanation!! I’m going to do something similar to my apartment, my intention is to connect to the same board 4 series of buttons (I would like to manage 4 different lights with one board), I think I need to change the board and I was more oriented on a MKR1000 that has more analog ports and wifi connection but my question is, can Alexa manage 4 lights points with one board? I’m still learning skills but your help can help me to understand if the project is fine (and to proceed to order the material)
Thanks for your kind reply
Stefano I am working on 8 channel relay current sensing tutorial. It will be a while before I post it. Thanks
This was a good video but one thing that will make it much better is when you are wiring the relay instead of saying wiring to the left and right terminals, tell if it is the normally closed or normally open terminals because not all have the terminals in the same place.
Eric Hughes Yes sir. I am doing that. I mentioned my relay default at 5:03. Anyway in this configuration it does not make any difference as long as common pole is connected to the device.
Do you think it would be a good idea to replace the induction current sensor with an optocoupler, resistor and capacitive dropper circuit? It's a bit more invasive but i had the parts laying around so i would rather not buy another sensor.
SilentDreamcast It should work but it complicates things and I wanted to keep it simple. It is good to separate low and high voltage with optocoupler. Let us know how it goes. Good luck.
I can honestly say I enjoy these videos. I learn a lot but you don’t have to over explain every single aspect. Other than that...Great Job & thank you
Des Hollis Let me know what you think of the last two tutorials. Your guidance is much appreciated. Thanks
Great video's well explained and already starting to use your projects! Would like to see how you provide power when these are placed permanently in an electrical box, and if wireless had any issues working in the wall .. thanks !!
Ross Romeo thank you for your feedback. Please share your thoughts what you like and dislike about the videos for I can make improvements. Good luck with your projects.
Hi there, Love watching these tutorials, my living room wiring is slightly different, is it possible to control the circuit below with NodeMcu? Any advice would be appreciated.
upload.wikimedia.org/wikipedia/commons/thumb/d/d1/California-3-way.svg/800px-California-3-way.svg.png
Gary Duncan Yes, you need to replace the switch "B" with 4 way switch and hookup the relay and sensor like I showed it in tutorial. Good luck.
Great tutorial!!! I'd like to do the same but with 8 channel relay board and using it as mqtt swicht on home assistant so i can control with google home, HA and real wall switch. Is it possible?
Yes, but you will need to modify the code a bit.I may do a tutorial in future. Good luck.
Hi Hi, very nice project, but I would like to know can this use mobile phone APP to control it. Thank you
I will have mobile support in future support.
in my country most apartments that are compatible with residential automation use relay pulse.
How would the system with a simple relay pulse ?
You can change the code do on and off with delay to match the plus duration.
Great video buddy ! Thnxs and congratz !
nice ,i only wish there was a way to do it without running additional wires
i have an outside light but it only is wired for a regular switch not a 3 way ,plus i would need to run wires for the current sensor too if i want the board mounted in the light
Andrea Mitchell you don't need to run additional wires if you are trying to make Alexa 3 way switch. Just replace your toggle switch with 3 way switch and connect NodeMcu as shown in 1st demo. Good Luck!
Top man! Great tut! Thanks for your time and effort.
Liked the video but the description of the video could be more robust. What parts did you use and where did you go to get them.
Jarren141 Please do suggest a better name for the video. Electrical switches are bought from Lows and NodeMcu,relay and current monitor from eBay. If you want them quicker then order them from Amazon.
To get a 2 relay nodemcu can I just program the nodemcu with two of the same program and just change the GPIO’s
Thomas360xbox Bass You can only flash one sketch at a time. You can use one sketch to control multiple devices.
Check out my tutorial on how to control two devices with single sketch. Good luck.
ua-cam.com/video/OC6QSXzkQU8/v-deo.html
Excellent video, filmed to a professional standard and very clear and precise instructions. Well done and keep up the good work 😊
Shane Graham Thank you for your valuable feedback.
hey, great project! I needed help in how do we use the sensor for multiple lights and switches
waiting for your reply
If you mean current sensor then need a sensor for each device you connect (or light).so that alexa can sense each device individually.
ok am i going to have to change the program
Wow this was great. Exactly what I was looking for!
Benjamin H I am glad that this video will be help full in your project. Please do share with us how you will use and improve this project in your implementation. Good Luck with your projects.
Y is Alexa so slow in processing command to turn on or off lamp?
Jesus Torres It is not slow for me. Did you add any delay in code?
First of all, thank you. Your videos are very helpful and very in depth. I like the step by step instructions you provide along with code for project. However, some of the videos are just a bit too long. Like this one, i find myself skipping forward sometimes.
Dave Thank you for your valuable feedback. I agree with you and planning to make them around 10 to 15 minutes. Let me know what would be the ideal length?
I would say anything around 15-20 mins seem good.
Hi man,i enjoyed watching your videos,i have a little understanding on computers and electronics and i want to have my house automized,just one question,is this system for 22OV?or just 110V?thanks for sharing
Key Wizard It works for both. Relay works with 110 and 220 just use the 220 to 3v dc power supply to power the NodeMcu
Thanks man,for the relay,let say i want to control 5 or more units at home,i would just buy a bigger relays and use the same set up?appreciated your comment sir...
Key Wizard You need one relay for each device to control them individually. Watch my tutorial with 2 relays. ua-cam.com/video/OC6QSXzkQU8/v-deo.html
This Avionics Tech loves your videos!
akspeedmic Thank you.
Great videos you make the projects easy to understand keep up the great work
kevin lloyd thank you
You are very thorough on your videos. I like the way you mix in power point slides and video. There in no doubt you spend a lot of time on these. Have you looked at using a Wemos in place of the NodeMCU? It had a smaller foot print as it has fewer GPIO, but based on the ESP. A side note, the current sensor can be installed on the wire from the relay to the light, which would put it in the same box as the relay and Node. You ultimately are trying to determine when current is flowing to the bulb. Keep up the great work!
Chris Hettinger defiantly I will look at WeMo.
I am connecting the current meter both ways. Look at the 2nd demo in this video.
It is a Wemos, not Wemo. Wemo is a brand of IOT components from Belkin. Wemos is an ESP8266 board with 5 volt regulator, FTDI and several other things all one 1 board. Basically the NodeMCU's little brother.
Chris Hettinger Sorry for the typo.
Can i use wifi to turn off my main power supply at home if so could you make a video of how to?
Are you asking to turn of the power for entire house?
Do u have to use the current sensor ta12-100 if u use the download
Thomas360xbox Bass You should be able to use any current sensor that can detect the current at 3 to 5 volts level. I have couple of dufferent ones and they work fine.
Impressed with the explanation and demonstration. Really Helpfull.
Amit Shrivastava thank you.
What is the use of current sensor? is it just to tell whether the load is on or off? or is it for measuring how much current its drawing ? If i dont want to install the current sensor if its there for demo purposes only, how to wire schematic then?
Yes, it is used to determine if load is on or off but you can use it to measure the current. My code is not calibrated for that.
so if i dont install that in my 4 way setup is the alexa part still going to work?
cant i just program the doc. two times with different GPIO's
Thomas360xbox Bass I don't understand your question.
Great tutorial! Question, why at 21:57 do you turn it on then off? Is this necessary? Also, is the relay you are using active high or low?
On/off is not required. Just testing to make sure it works with manual switch only. I am using active high relay. You can check my following video to learn how to convert active low relay to active high.
ua-cam.com/video/pBxeHlvF4eQ/v-deo.html
@@netmedias7657 Thank you for the reply. I have an issue maybe you can help with. When I verify code in Arduino IDE, it has this error. "Error compiling for board NodeMCU 1.0 (ESP-12E Module). /Downloads/IOT-NodeMcu-Alexa_Automation_4Way_Switch-master/current_sensor/current_sensor.ino:194: undefined reference to `sendRelayState()'" I know this video is a few years old, is it possible that an update to IDE or other libraries has broken your code? Thanks
Yes i am asking if i can use it to turn off the entire power from my house.
I am not sure why you need to do this. This is very dangerous to do it your self. Seek a professional help.Usually most houses in US use 100 to 200 amps mains connection. You need to make sure you get a correct relay based on your connection rating. You will need a heavy duty relay that can handle this kind of load.
Make A vedio On Coding with the Alexa For Running the system
What system?
@@netmedias7657 System Here Is Running the Lights On/Off By means of Voice Control, Remote control,Or By Manually By pressing 2way or 3way switchs...
Thanks for taking the time to make the video's. I find them inspiring.
Steven Ewbank thank you for your feedback.
Hey just send it to me already.. lol
If I stop the light from Alexa, the relay may be in the NO position, and the current is cut off, we can have lights on in the middle of the night, or the program remembers the last state on power failure?
costara How will I know if it was a power failure or if it was switched off and on?
Imagine the following scenario; we turn the light on from the switch 1 and turn off the light from the voice command. if the power is down (disconnecting the plug from the socket), the program will know the last state and will keep the light off, when pluging on again?
keep the good work!
Cool project..
Nice. Could list where you purchased the voltage sensor?
Rainmaker LLC can check out the following current meters. I have 3 different ones. You can also buy it on Amazon and ebay. Good luck.
www.banggood.com/0-5A-Iteaduino-AC-Current-Transformer-Current-Sensor-Module-With-3p-4p-Interface-p-1068624.html?rmmds=search&cur_warehouse=CN
www.banggood.com/5A-Range-Single-phase-AC-Current-Transformer-Current-Sensor-Module-p-1228113.html?rmmds=detail-left-hotproducts__1&cur_warehouse=CN
She is an IT...
Thanks Sir For sharing Practical Tutorials
Thanks.
Hi genius can you please do a video turn on and off led lights with Alexa and also I want how to control motor with Alexa
alae alami Sure, I have it on my todo list. Stay tuned.
I’m new to programming would you mind to make a program that has 2 relays
Thomas360xbox Bass I will make it soon. Stay tuned. Thanks
Netmedias how soon because I’m going to get a Alexa or google hunt me and I need to order the parts
Thanks for your very good videotutorials!
Ad Lenders Thank you.