livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz



  • сегодня доделал Livolo+esp8266 пришлось помучаться с программой и схемой питания но все заработало[0_1485259118390_livolo_esp.mp4](Uploading 100%)



  • @DJONvl
    Woow !
    Livolo+Esp8266 working ??? ... sounds very good.
    But we can not see the video seems you try to upload here ... 😞



  • @DJONvl said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    сегодня доделал Livolo+esp8266 пришлось помучаться с программой и схемой питания но все заработало[0_1485259118390_livolo_esp.mp4](Uploading 100%)

    livolo+esp – 00:28
    — Vlad K



  • @DJONvl

    Yesss @DJONvl . Thats is !!!! .
    You got it !!!

    Please can you post all the details about how you are do it ??

    How you are managed to achieve enough power from Livolo ??

    How you wired the esp8266 and where on the livolo switch ??

    You can post the schematic ??

    Please, all details you can...

    Regards



  • @DJONvl
    Esp потребляет более 350мА.
    Покажешь схему питания?

    Esp consumes more then 350mA.
    Can you show power schematic?



  • For the AU/US plate, can anyone confirm that this is the correct wiring for
    SW1 = Switch Right on/off
    SW2 = Switch Left on/off
    SS1 = Right Status on/off
    SS2 = Left Status on /off
    GND = Ground

    0_1487468564748_au-us2.jpg



  • For power, I found these on the board. The 12V accutally read 14.86V for the two Switch gang and 14.10V for the 1 gang switch. This was me using the multimeter connecting with ground.

    1 Gang Switch even have indication of the board
    0_1487468882377_1Gang-.jpg

    2 Gang Switch
    0_1487468903062_2Gang-.jpg


  • Hardware Contributor

    @Markhill for switching on/off the relays it's not that simple. On the 'main' board there is a decoder connected to 3 pins or the MCU and on the 2x7 header.
    Check in one of my messages above for the pin out on the header.



  • @Nca78 Hi, I was thinking of using this to connect to the switch. The guy sell this for about $15.00US each
    0_1487474553542_conn-1.jpg
    The controller require external power 5-12v. I was thinking of using power from the switch.


  • Hardware Contributor

    @Markhill it cannot work, this board needs external power because the ESP8266 he is using is too power hungry, the switch cannot provide enough power. And this board is sized for EU switch it will not work with US or US/AU switch.

    I'm working on 3 buttons and 4 buttons version with atmega and nrf24, power from the swith is enough so it's just a plug&play replacement. I'm testing the 3 buttons switch at the moment (same layout than 1 button in which only the center button is connected). It will be cheaper than 15$ if you solder it yourself, if you don't want to do smd soldering we can probably find a solution for pre-assembled boards.

    0_1487478771875_IMAG1399.jpg



  • @Nca78 I'm in. Plug and play, same size, no external power and cheaper too. When will it be ready?

    Btw, your board will be able fit on a 3 buttons and 4 buttons too right? I got them.

    Will it provide status feed back, control remotely on phone app or ioBroker and is there any coding required?


  • Hardware Contributor

    Keep us updated on your development, i'm working on a double relay module for lighting but i doubt its going to fit inside of a single gang wall box.


  • Hardware Contributor

    @Markhill I have made 2 boards, one for 1/3 buttons, one for 4 buttons.
    It will be a MySensors actuator so yes status feedback etc.

    I'll make a script for basic switch function and probably a few extra things two. I'm planning to use 3 button switches in my home to command 2 light circuits with the top and bottom buttons, and AC with center button (not using the relay). I have included 2 extra leds on center button for that, to select different modes of AC.

    The 4 buttons version uses sx1509 extender to have more advanced feedback like breathing/flashing LEDs but it's probably not in a final form yet, it will take more time to be ready.



  • Here are pictures of the US/AU 2 switch main board

    0_1487485129503_2017-02-16 21.31.36.jpg
    0_1487484434878_2017-02-18 23.42.28.jpg
    0_1487484470423_2017-02-18 23.42.38.jpg
    0_1487484520232_2017-02-18 23.42.46.jpg
    0_1487484591742_2017-02-18 23.42.52.jpg

    Here is a 4 gang US/AU
    0_1487484398247_2017-02-19 16.31.03.jpg

    Here is a 3 Gang US/AU
    0_1487484732891_2017-02-19 16.35.19.jpg



  • @Nca78 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    buttons version uses sx1509 extender to have more advanced feedback like breathing/flashing LEDs but it's probably not in a final form y

    Can you send me the 1/3 buttons so I can test it?

    The switch I use at home is a 3 gang 2 way. That is one light control by two switches. Will your board still work with these?

    Thanks.


  • Hardware Contributor

    I don't know about the 2 way switches so don't have one to check. But in my home I will just connect one side to a normal switch and use switch on the other side as radio switch only without the relay.

    You want a 1/3 switch PCB ? Where do you live ?


  • Hardware Contributor

    Do you guys happen to know what the capacitive touch button part is called? I'm trying to look for some of these on the internet and getting nothing relevant coming up. Just the little glass/acrylic parts of the livolo switches that recognise your touch.


  • Hardware Contributor

    @Samuel235 there is no "capacitive touch button part", the touch function is managed directly by the IC of the board.
    So they just have an electrode (big circle of copper) connected to an IC pin and a plastic circle glued to it to have more even light from the led.
    What I am using is TTP223N (N version is more sensible) which is both very cheap and very easy to use


  • Hardware Contributor

    Not sure I completely get what you mean, but I will have a search for how these little IC's work. Their datasheet looks pretty nice tbh, small, low cost, easy to get. Do they basically look for a 'press' on their input and then output 1 or 0 to a MCU, one on each button too, correct?


  • Hardware Contributor

    @Samuel235 They just have one output. You can have them work in "toggle" mode (press to set output high, press again to set output low) or in "normal" mode (default behavior) then output is high when touch is detected.
    So yes, one ttp223 on each button. You can use other ics (TTP224 with 4 touch inputs for example) but I prefer TTP223 as you can put it very close to the touch electrode to avoid interferences.

    TTP223 is the IC that is used in all the cheap "one touch button" breakout boards on ebay/aliexpress/...


  • Hardware Contributor

    @Nca78 - These little beauties are perfect! I feel a light switch project coming on myself.... How is your development coming on?

    Have you seen this: https://forum.mysensors.org/topic/4317/us-decora-style-wall-switch

    Looks like it could be neat. But, not touch. Not sure what i would prefer tbh. Either way, i have myself a dual relay board that i'm in the finishing touches too before posting it up here and on Openhardware.IO.

    How're you going about your switching, are you switching AC in the light switch, powering this from AC or DC or are you powering by battery and emitting wireless signals to the gateway to then switch relays not connected to this board?


  • Hardware Contributor

    I'm keeping the relays from the original livolo switch. My goal is to still have basic switch functionality even if the controller box and gateway are switched off/dead. This is only possible if the switch and the relay are physically connected.

    For the progress well I soldered all components on a first board and tested MySensors connexion and touch functions+led indicators and it's all fine.
    Tomorrow I'll update the script to manage the relays and test on the real switch.


  • Hardware Contributor

    @Nca78 - Keep us posted with images too if you could. Rather interested in your module!



  • @Nca78, does that mean I can send high from arduino to this electrode thus imitating the touch? If so, would it be easier to do that or send the high/low directly to the HC238 (to A0 - A2)? It seems that in the first case I can also easily control the dimming function by keeping high for a few seconds. Is there a way to control dimming directly through HC238?
    And an unrelated question, will you be able to sell these replacement PCBs you're working on right now and when? I'm not sure I will have enough patience to solder arduinos/radios to dozens of the switches, so I'd rather buy your plug-n-play solution if the price is reasonable.


  • Hardware Contributor

    @achurak1 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    @Nca78, does that mean I can send high from arduino to this electrode thus imitating the touch? If so, would it be easier to do that or send the high/low directly to the HC238 (to A0 - A2)? It seems that in the first case I can also easily control the dimming function by keeping high for a few seconds. Is there a way to control dimming directly through HC238?

    I think you can simulate the press by setting the pin to a high level, it will cheat the capacitance measurement and should generate a "click". But I take no responsibility for that 😛
    I don't think the dimmer is using an HC238, which is a decoder that takes 3 pins as input and sets one of it's outputs high, it's convenient for the relays they use but not suitable for a dimmer. They are probably using PWM for that. I have no dimmer switch here, I ordered one but I still need time to receive it...
    So if you want to control a dimmer livolo switch at the moment, try to simulate touches on the buttons and the mcu on their sensor board will do the job for you.

    And an unrelated question, will you be able to sell these replacement PCBs you're working on right now and when? I'm not sure I will have enough patience to solder arduinos/radios to dozens of the switches, so I'd rather buy your plug-n-play solution if the price is reasonable.

    I will be able to sell them if they work fine on the long term, but that will need at least one month in the wall to be sure, then another month to order and get the fixed PCB (got some improvements to make already...).
    I want to get the dimmer swith also to have a look and if possible make a PCB compatible with both normal switch and dimmer.
    For the price I have no idea, either I get them done in China but I don't think there will be enough volume and it takes a lot of time to prepare (but that's an interesting process to learn :)), or I make them myself which takes a lot of time and logistics to assemble, test, ship. BOM is already around 10 US$ so I don't think it could go below 20US$ for final board. That would make the final swith around 10$ more than the radio version of livolo switch, as with my pcb you can just buy the cheapest switches, without radios.



  • @Nca78 if you search aliexpress hard enough you'll fund us standard plates only. Search "livolo glass plate -eu -uk"



  • @Nca78, thanks! I'm going to try this touch simulation, probably tomorrow.
    They use PIC16F690 chip for the dimmable switch versions: http://www.microchip.com/wwwproducts/en/PIC16F690
    $20 seems reasonable, I paid $22 for the one gang dimmable switch, so the total would be $42.


  • Hardware Contributor

    @wallyllama said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    livolo glass plate -eu -uk

    Maybe but I'm missing your point ?
    I still need to buy the switch to have the box + main power/relay board.

    @achurak1 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    They use PIC16F690 chip for the dimmable switch versions: http://www.microchip.com/wwwproducts/en/PIC16F690
    They use the same PIC16F690 in all the switches but what is interesting is to know to which pins of the connector it is connected, and what is connected on the main/ac board to control the dimmers.

    If someone has the 2 way switches I'm interested to know what ics are connected to the A and B connectors and to which pins those ics are connected to on the 2x7 pins connectors.



  • @Nca78 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    @wallyllama said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    livolo glass plate -eu -uk

    Maybe but I'm missing your point ?
    I still need to buy the switch to have the box + main power/relay board.

    Nope, I missed yours. Someone mentioned getting glass plates only, then i saw your comment about US plates, and I combined the two. I return you to your regularly scheduled project.



  • @Nca78 I have 2 way switch for 1 gang, 2 gang and 3 gang. Will take a picture for you guys soon



  • @Nca78 I have a probably very stupid question. Why is it every time I'm trying to solder my arduino in parallel to the pins A0-A2 everything basically stops working - the lights would go on, but not off, dimmer would stop working either or the lights would just start flickering like crazy. What am I missing here? Is that somehow related to pull-up/down resistors? I tried both modes on arduino, INPUT to just listen what's going on when I'm touching the button and OUTPUT to actually control stuff, but both gave me the same results - nothing 😞


  • Hardware Contributor

    Hello, just published my first version for the US/AU switch.
    https://forum.mysensors.org/topic/6489/livolo-3-buttons-us-au-switch-adapter/2

    Still needs some improvements, so no gerbers at the moment.


  • Hardware Contributor

    @achurak1 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    @Nca78 I have a probably very stupid question. Why is it every time I'm trying to solder my arduino in parallel to the pins A0-A2 everything basically stops working - the lights would go on, but not off, dimmer would stop working either or the lights would just start flickering like crazy. What am I missing here? Is that somehow related to pull-up/down resistors? I tried both modes on arduino, INPUT to just listen what's going on when I'm touching the button and OUTPUT to actually control stuff, but both gave me the same results - nothing 😞

    Sorry I forgot to reply to your question...
    I ordered a dimmer and checked it, it has another PIC on the "main" board so I think it's not that easy to control, I suppose the PIC on the "main" board manages PWM, and it receives instructions from the PIC on the "sensor" board, we need to know how they communicate.



  • @Nca78

    hello. Is there a connection example with ESP?


  • Hardware Contributor

    @alexus said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    @Nca78

    hello. Is there a connection example with ESP?

    Somewhere on youtube it seems, but using external power supply. It doesn't sound like a good idea to try to draw over 100mA from a power supply that was designed to provide less than 10, especially when a MySensors board can provide exactly the same functionality as a plug-in replacement of the livolo sensor board.



  • My goal would be to connect an arduino to the data pin on the power board and use the library to control livolo direct without a radio. The problem I have is that when i connect ground to ground on an ftdi I get magic smoke all over. Inuse my. Volt meter and sure enough the gnd pin is connected directly to the live input. Im guessing gnd and +3v "float" around the AC in some fashion.

    Has anyone sucessfully bypassed the radio? Im thinking t may work if i power the arduino off the livolo power supply, or from a battery, but then if i connect that to an rs485 or other device with a real ground, kapow! At least that is what i am thinking will happen.

    On a side note I have a regular, 2way, and remote switch, all the same revision and all US style, and from what I can tell the difference for 2way is a diode (d2) and a resettable fuse (r10). It lookes like there is basically a primative modem that sends/recieves the same data as the radio. (The radio is receive only, but 2 way has to be, well 2 ways). The "modem" is connected to "B" and "A" is connected to live and "gnd", which is why I think the dc voltage sort of floats on the ac.


  • Hardware Contributor

    @wallyllama

    In order to have isolation why not use an optocoupler from arduino to send logic high or low to the livolo relays board? This way they won't share the same gnd and no more issues of this kind in theory. But this means adding the optocoupler as an extra component..but I don't think this is a big issue and it should be cheap also.



  • @mtiutiu i usually need help with the obvious. Thank you.


  • Hardware Contributor

    @wallyllama

    What do you mean? You don't know how the wiring goes? I can provide a simple wiring diagram not a problem if that's needed.



  • I meant that using an optocoupler was an obvious solution, and I should have thought of it.



  • I managed to do some reverse engineering on the livolo dimmer switch. It seems that the touch MCU talks to the dimmer MCU via USART (idle: low, 19200 bps, 1 start, 1 stop, 8 data). Each 20 msec the dimmer MCU sends a byte that shows the level of the dimmer and the touch MCU replies with a byte that has bit 0 set to one if touch is present, rest of the bits are all 0 (except for each 10th reply, when all the other bits are 1).
    Also the 433MHz radio signal is decoded by the touch MCU not by the dimmer MCU.



  • @Andrei-Călin-Tătar said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    Also the 433MHz radio signal is decoded by the touch MCU not by the dimmer MCU.

    The touch mcu does this for non dimming temote modules also. I think it uses mostly the same system for the 2way switches also.



  • I decided in the end to completely remove both MCUs and replace them with one mega328p, at42qt1010 and one nrf24l01. The problem is that it must be really power efficient. Once the light goes close to full power, the current drops significantly. I also noticed on the PCB space for a battery and a transistor that controls when it's connected to the power supply. Do the switches that come with RF modules have the battery location (B1 I think) populated?



  • @Andrei-Călin-Tătar b1 is the buzzer. When you hold a touch pad down for more than 5 seconds, the switch goes into learning mode and the buzzer makes a sound.



  • @wallyllama ah, that makes sense. thanks for the info!



  • OK, here is what I managed to get working so far. I didn't use mysensors in the end but the sketch can be adapted. I must admit it's not the cleanest code.
    So, I removed both microcontrollers from the base and the touch panel. I added a AT42QT1010 for touch detection (10k resistor, 47nF cap) and also replaced the led resistors from the touch panel with 2.2k ones (the light was too dimm, now it's a bit too bright 😄 ).

    Rest of the mods should be easy to see from the images. I didn't roll my own PCBs since I needed to adapt only 6 switches.

    Features in the sketch: manual dimmer mode (works the same as the normal switch, just with control and brightness report); manual on/off mode (switches on/off on the start of a touch; the brightness can be set - default 100); manual disabled; when changing the brightness it goes through a ramp, it doesn't go directly to max or min. The modes, brightness, etc. can be changed via RF.

    Base mod: https://photos.app.goo.gl/ZGojnlm2ocBEaucp2
    Touch panel mod: https://photos.app.goo.gl/UpG2UuMtK2qa6q4h1
    And the sketch code: https://github.com/andrei-tatar/SensorsNetwork/blob/master/LightDimmer/LightDimmer.ino



  • @Andrei-Călin-Tătar - How did you solve the problem with the power? I tried powering arduino from the built-in 3V connection, but it only worked to turn the lights on. Once on, I almost couldn't communicate with the arduino anymore (like 1 attempt from 20 would be successful).



  • @achurak1 - I limited the max brightness. At full brightness, the triac is off for 2.9ms (out of 10msec for 50Hz). That gives enough time to recharge the circuit for the arduino but it limits the power delivered to the light bulbs to about 80-90%. If I would go more than that I would get unstable results. The circuit isn't able to keep it's 3V at full brightness without an arduino connected.



  • @Andrei-Călin-Tătar - Understood, thanks! Why did you need a new touch sensor, could you reuse the existing one?



  • @achurak1 do you mean the AT42QT1010? seemed easier for me. I could've added touch detection in the sketch.



  • @Andrei-Călin-Tătar - can you please explain all of your jumper wires. US version looks differently obviously so it's really hard to figure out what you did there based on just the pictures.



  • @achurak1 I added some details over the photos:
    https://photos.app.goo.gl/S7VxIrn58z99HRMp2



  • @DJONvl

    very COOL...you user ioBroker with VIS!!!!



  • @wallyllama said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    On a side note I have a regular, 2way, and remote switch, all the same revision and all US style, and from what I can tell the difference for 2way is a diode (d2) and a resettable fuse (r10). It lookes like there is basically a primative modem that sends/recieves the same data as the radio. (The radio is receive only, but 2 way has to be, well 2 ways). The "modem" is connected to "B" and "A" is connected to live and "gnd", which is why I think the dc voltage sort of floats on the ac.

    I have tried adding these parts to a non-2-way switch and used it as 2-way but it's not working. I suspect the firmware is different? I have managed to get an ESP8266 powered from the switch in some cases, so I could make a switch 2-way with software. But the livolo switch will not stay on without a load connected (if you have no light connected to the 2nd switch on a 2-gang).



  • Guys, I see a lot of struggle trying to get devices powered from these switches. Maybe I missed it, but has anyone tried replacing the 3.3v regulator in the switch? I replaced mine with a switched-mode version, which gives you a lot more power to play with. The original linear regulators effectively have a 8.7v drop across them.

    With that + a livolo LED adapter I've managed to get a ESP8266 powered on as little as 2x 13W LED bulbs (I've tried 2x 10.5W and it doesn't work). I've tried some of the jumpers people have posted here to get more power, but I'm unsure if they help.


  • Hardware Contributor

    @MystX said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    With that + a livolo LED adapter I've managed to get a ESP8266 powered on as little as 2x 13W LED bulbs (I've tried 2x 10.5W and it doesn't work). I've tried some of the jumpers people have posted here to get more power, but I'm unsure if they help.

    Why would you want to use an ESP8266 when there are solutions using only a fraction of the power that you can connect to an ESP8266 via a radio link if you really need wifi ? With the wasted power you could run a screen, RGB leds, radar module, ...



  • @Nca78 So that I don't have to run a radio link and an esp elsewhere 😃

    But my post was really about the switching regulator.


  • Hardware Contributor

    @MystX yes the switching regulator is much more efficient, there's a board using it already. And now the new versions have 12V available on the "touch" board so it's much easier to set it up.



  • Let me explain my problem in details, I need classic impulse switch to trig lights on stairs and hall and it is available in this form factor but the problem is that this push switch isn't available with remote control functionality so my idea is to use either simple one gang switch, or curtain or 2 Gang 2 Way but of course I have to somehow 'hack' them to work as momentary switches...



  • Wow what a great project, this week I'll see if I get it with 2 way 2 gan



  • Well yesterday burn a livolo 😢


  • Hardware Contributor

    @camposmansi said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    Well yesterday burn a livolo 😢

    What did you do ? Wire the 2 way switch the wrong way ?



  • @nca78 said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    @camposmansi said in livolo Glass Panel Touch Light Wall Switch + arduino 433Mhz:

    Well yesterday burn a livolo 😢

    What did you do ? Wire the 2 way switch the wrong way ?

    If I burn to the computer, in the end I made a sketch and I will use only the keypad, now I'm designing the PVC



  • Hi All,

    I'm trying a different approach, on how to use just the top (sensor) part of the livolo touch switch, but at the moment, i'm stuck at the PIC16f690 microcontroller functions in order to power up the LED.

    I'm using a Livolo VL-C601-2 model and based on the wires on the top part, i tried to make a diagram to batter understand the schematics. (Please note that i'm missing some wires and that i have not drawn all the wires from all the pins as i could not see all of them. If something is wrong, please let me know.)

    What i don't understand from the diagram below, is how does the PIC16F690 controls the two LEDs (red and blue) using only the RB4 (13) pin.

    From the datasheet link here i can see that the Pin 13 (RB4) has: RB4/AN10/SDI/SDA and supports IOC

    Can someone please explain to a noob in electronics how does this work and how does the pic switches from one LED to the other ?

    alt text


Log in to reply
 

Suggested Topics

51
Online

11.4k
Users

11.1k
Topics

112.7k
Posts