Controlling LED lights via WiFi

Joined
Sep 5, 2024
Posts
200
Likes collected
388
Location
In a tin box
Funster No
106,205
MH
Building a PVC
I've been driving myself crazy overthinking this, so thought I'd see if anyone else has already done what I'm thinking of doing...

Requirement:
  • Ability to control LED light strips using the van's WiFi network (I don't want to have to change network to a 'light specific' one) OR for them to be controllable from a phone using bluetooth.
  • No physical remote controls. Too easy to lose, batteries are dead etc. Can't be doing with them.

Nice to have:
  • Physical switches
  • RGBW addressable lights (just for playing really)
  • Ability to control relays via WiFi as on/off for other devices

At the most basic level I think I can just connect each strip I want to control to one of those in-line adapters.
However, I can't see how I could add a physical switch to that setup that could work alongside the WiFi remote. I might just be being dense but if I put a switch in to the power side of it then the WiFi controller would stop working until the power switch was back on again. What I'd really like is to be able to use either method interchangeably.

That brings me on to setting something up on an ESP-32 controller which is something I've never done before. Seems like there are a few methods of doing this from WLED to going full 'smart home' with something like the Matter protocol. If I've understood it correctly, this would also allow me to control some relays so I could trigger on/off commands for other devices (no, I don't really know what yet either, but I can imagine being in bed and remembering that I haven't turned something off and smugly doing so from my phone without getting up...)

Am I going down a rabbit hole of insanity with the ESP-32 idea?

Anyone else been down it before? :LOL:
 
This site contains affiliate links for which MHF may be compensated.
The strip LEDs can be controlled via an app on your phone, no physical switch needed.
They usually come with a remote control but you don't need to use it if you don't want to
Don't understand anything you said in the last paragraph :oops:

Edit, just reread, you don't want to use a phone, Bluetooth or remote control - good luck, I'm out 😃
 
I use a "Zigbee" wireless system to control a few things on our MH via either Alexa or my phone, like remotely turning on and off our diesel heater, finding out the temperature of our fridge and freezer, controlling our window alarms and opening and closing our grey waste valve.
I also use a IR Blaster to control our Maxxfan via Alexa.
The various Zigbee devices are fairly cheap to buy and even more so is to buy direct from Aliexpress, like the eWelink wireless relay boards at less than £4 each.

Give me a yell if you want a bit more detail.
 
Sad - how to complicate life. ;)

I certainly see your perspective, but I enjoy tinkering with tech and learning along the way so it would be quite fun for me.

The idea ultimately is actually to make life easier for myself so I can turn things on or off with a switch like a normal person, but also from my phone so I don't have to get up if I don't want to!

Edit, just reread, you don't want to use a phone, Bluetooth or remote control - good luck, I'm out 😃

Almost, but not quite. I do want to use my phone, I don't mind if it's bluetooth or van WiFi but I don't want to swap which WiFi I'm connected to just to control the lights. I don't want to use a remote but I do want to be able to use a normal light switch too.

See, I told you it was simple 😃

Give me a yell if you want a bit more detail.
Will do - thanks!

I've just ordered some light strips and both the ESP-32 and inline adapter things from Aliexpress as well as some relays - so they're cheap enough to play around with and see what works and what doesn't.

Plenty of other ESP-32 projects to play around with if I don't end up using those, and I think I can use the inline things to trigger relays maybe. Learning will take place and some electronic components may be sacrificed in the name of knowledge!

Subscribers  do not see these advertisements

 
I dabbled at bit with coding esp32's with Arduino IDE couple or years back so I could control with a servo the angle of shutters on an air intake for our diesel heater to allow the heater to run at lower fuel pump rates.
 
Use WLED on an ESP controller is indeed the answer. It's simple, it works, and there is even an IOS app, and it can integrate with Google HA and alexa apaprently.

I've been playing with it for about 6momnths, it's trivial to do, and a lot better than commercial solutions in it's flexibility.

If you desire it it can even stretch to large screen efffects with matrix displays, but I just use with a few 300 led strips personally.

You can buy pre-done WLED controllers from aliexpress which the wires from the strips just solder to if you desire, it's a lot easier than doing the circuits yourself, but runs standard WLED. At moment I've gone that way, but a friend of a friend is about to start selling some pre-done PCB's for it on Amazon in UK. Keep eye on amazon for wled search terms ;)

Should add you can join wled to your vans wifi network so you don't need to switch networks to get it running. that works fine.
 
Thanks starquake - very helpful.

Just out of curiousity, are you just using the ESP-32 and the lights or are you adding things like the resistor and fuses that I've seen in some wiring diagrams?

From what I've read it also looks like you can add a push button to IO17 which should be configurable as a manual on/off I think (again, some testing will be done on the bench before finalising)
 
Thanks starquake - very helpful.

Just out of curiousity, are you just using the ESP-32 and the lights or are you adding things like the resistor and fuses that I've seen in some wiring diagrams?

From what I've read it also looks like you can add a push button to IO17 which should be configurable as a manual on/off I think (again, some testing will be done on the bench before finalising)

You'll need some resistor/fuses.
https://quinled.info/quinled-boards has some reference designs from memory.

You also strictly speaking depending on the LED strip may need to level shift from the 5v output of the esp to 3.3v for some strip brands. You'll see the quinled type designs cover that.

And yes, you can do all sorts of things with custom buttons to set off programs on inputs, and many input pins are avialable.

Either build your own, or just use a Chinese reference (prebuilt) design, there are many on Aliexpress.

The important thing is level shifting, as some strip doesn't like 5v signalling, and ditto you need to remember you may need power injection mid strip if using 5v. I tend to use regulated 12V though, drop the voltage for the esp and again level shift the output to what the strips I've ordered needs if it won't "be happy" with 5v.

Just buy cheap stuff on Aliexpress and learn. I've burnt out a few strips by overvolting/overdriving them, but WLED's default power limit (mostly) keeps you safe unless you override it.
 
Should say I mentioned QuinLED as their designs show you what you should have on a design for safety, you can build your own cheaper, but you can also order PCB's and populate yourself rather than prebuild them. I like their designs personally as they are quite compact, and also offer decent guidane on how much power you can run through them ;). However doing some stuff manually with off-brand Chinese controlers I still have managed to "break" some strips, mostly by accidentally short circuiting them with my (poor) soldering skills.

Subscribers  do not see these advertisements

 
Thanks starquake - I have some learning to do, but it looks like it's not too complicated.

I'll have a look at the QuinLED stuff but have already ordered some basics from Aliexpress which will be fine for prototyping.

For the full build I'll put in resistors / fuses etc but I haven't quite figured out what I need for that yet!

I've also opted for 12v strips and will step down for the ESP-32 - my thinking was that if I did need to power inject then it would be easier to tap into the 12v system than to mess about with more step down transformers down the line. It should also be less susceptible to voltage drop.

I'm not running crazy lenghts so am hoping to get away with not having to power inject.

Was the regulated 12v just a precaution, or have you had issues with non-regulated?
 
I have had great success with Home Assistant and ESPhome in my van.

A good LED controller is this https://www.kincony.com/esp32-pwm-dimmer.html

OK so 16 channels of LEDs is a bit of overkill - but the board is very easy to set up with ESPhome. It has a couple of relays on board and has plenty of switch inputs.

This drives analog led strips which I have found to be better than the digital ones when it comes to finding a high CRI strip. A CRI over 90 will give a give a natural full spectrum white light that is far more pleasant to live in.

Kincony are a great source of useful hardware that has all the instructions and configuration you need to set up with ESPhome and Home Assistant.

If you go down this route let me know and I will send you my configuration file - it is based on the one provided by Kinony but improves the on/off/dim with a single button feature.

I went through the zigbee stage before settling on ESPhome. Yes zigbee LED control devices are super cheap - but I had no end of frustration with them - some just never worked, some did for a while - but none of them did exactly what I wanted. Most frustrating was that mixing devices from various manufacturers was very hit and miss. I have a large box of failed Zigbee projects as I am sure have many others.

I use little low power zigbee stick on buttons due to the flexibility in mounting them (just stick them where you want them!) as I had lots left over from my Zigbee projects stage! But only for on/off. I found dimming light up/down with Zigbee is a surprisingly complex subject.

Hope this helps. I have found ESPhome is a very pleasant “rabbit hole” to do down! It has spread all over my van and in to my house now!
 
Last edited:
Was the regulated 12v just a precaution, or have you had issues with non-regulated?
No, I've had strips burn out on the random 12-15v on a veichile battery before (ie, it burnt out when solar was charging at higher voltages), it can cook the strip at the start (as voltage is higher nearest the power input due to resistance). I don't personally think putting a regulated supply in adds a huge amount to cost to keep it at 12v and avoid burning out strip.

worth noting some strip probably does work fine as mentioned, but given I like the super cheap chinese stuff from aliexpress (I can probably link the cheap reseller I use, give me a sec -> I'd reccomend using it always with real 12v regulated supplys. Up to you how you supply.

And you are right, just step it down for the esp to the voltage of the esp you using. If the strip logic requires 3.3v signalling or 5v signalling use a logic level converter again as needed. In many but not all cases you won't need this every time for 1-2 strips, but if you daisy chain a lot, this is an essential thing.

One really important thing is to always unreel 12v strip before powering. Sounds mad but it generates a ton of heat, and reeled up as it is delivered can actually melt carpet. With 5v strip it matters less, but 12v you'll have a ton of heat to dissapate.

If it helps I can reccomend https://www.aliexpress.com/store/910726118 this vendor (ANTLED) as being reasonable on deliverys and price and their strip is of better quality than some others I have ordered for the price.
 
Thanks so much matbic and starquake - this is exactly the practical experience I was hoping to hear.

More research to be done, more test bits to be bought....

The only downside with Aliexpress is that I want to start playing with it NOW but I'll have to wait a while I guess....
 
Worth noting the power limits on WLED tend to be "safe" but consider you can drive a single (5m) strip up to circa I think it is 80W-90W or thereabouts (it's 30ma per LED I think on some strip!, so what 9A at 12v potentially on some 300led strips). I mention this as this is the point you need to be really careful about wires melting. Some Chinese wiring (not on the strips themselves) but on things like pigtail connections can be very underrated for the current you may send. It is worth figuring out your max draw, and using WLED to set a very high draw and check with a thermal camera you don't have wire heating (or use your fingers to check for warmth if you brave). OOTB I think WLED limits to a safe 2-3A default, so you won't have issues at that level, but things are also not that bright.

If you doing outdoor LED stuff you can be very bright if you desire, but you will need to reinject power if so as internal resistance will cause very hot strip at the first point. We find them plenty bright at around 30-40W per 300 led strip.

Just be a little careful on your power input wires, the data wires run bugger all current basically, but the power wires you may need some thicker cables soldered on is my only top tip, especially if you choose to disable, or set the power levels for higher brightness than the conservative (reasonably safe) defaults. (the data wires tell each LED how much power to use in effect).

Subscribers  do not see these advertisements

 

Join us or log in to post a reply.

To join in you must be a member of MotorhomeFun

Join MotorhomeFun

Join us, it quick and easy!

Log in

Already a member? Log in here.

Latest journal entries

Back
Top