💬 Homini In-Wall Battery Powered Light Switch Module





  • Nice. I am doing something similar to this.
    Can you post more photos from the front view 🙂 ?


  • Hardware Contributor

    @ahmedadelhosni, these are the only other ones i have without removing the switch from the wall.

    0_1458410582433_image.jpeg
    0_1458410603418_image.jpeg
    0_1458410624231_image.jpeg


  • Hardware Contributor

    I have had the materials arrive to attempt to get the latest fixes sorted for this board. Hopefully this will allow us to serial upload while the radio is soldered permanently onto the board. I will update soon as i have attempted this. Keep you posted!


  • Hardware Contributor

    UPDATE

    We have a working node. We're now able to serial upload and monitor the module with thanks to @GertSanders and his bootloader.

    So the node currently has 2 switch inputs and that would be the maximum for the hardware interrupt, i may do some investigating to get another port for interrupt to enable us to have 3 switches on the one node.


  • Hardware Contributor

    @Samuel235 said:

    UPDATE

    We have a working node. We're now able to serial upload and monitor the module with thanks to @GertSanders and his bootloader.

    So the node currently has 2 switch inputs and that would be the maximum for the hardware interrupt, i may do some investigating to get another port for interrupt to enable us to have 3 switches on the one node.

    Hello,
    this is an interesting project, have you considered the following points ?

    1. Use the SMD version of NRF24, it's really tiny compared to the normal version, and not that difficult to solder. It would fit in the empty part of your PCB next to atmega and the "antenna" reserved space and you would be save the space on the right part of the PCB.

    2. Link multiple switches to one interrupt pin, using diodes (as explained here : http://www.gammon.com.au/forum/?id=11091) so you can use a much higher number of inputs, including some of the analog ones).
      This will not work with standard switches that stay in ON or OFF position but it's perfect for push buttons that go back into place when released, with each light/circuit having both ON and OFF buttons.
      I find normal switches confusing as they can be in ON position physically but with the light in OFF state because it was switched off from controller. Then you have to switch OFF and then ON again on the switch if you want to have the light on. I have this at home with some di-o (433MHz) boxes behind regular switches and it really is annoying sometimes.


  • Hardware Contributor

    @Nca78

    Good morning, thank you for taking your time to contribute to this project firstly, i appreciate every bit of input/advice i get given around here.

    Unfortunately i haven't had much time recently where i could futher develop my modules, however, while i wait for my most recent to be prototyped and sent to me i will spend some time looking at this maybe.

    I have recently been looking at the SMD versions of nRF24, and i must admit i do like the look of these little beauties! The board will need some alterations to fit it on but i'm sure i could get that to fit like you're suggesting. Do you happen to have a link to maybe a aliexpress or ebay where i could find some good working SMD nRF24's?

    The switch topic is a hot discussion, i have been suggested this method you speak of previously. Once question i would have though, is there many wall light switches that can act like this, not a solid on or off 'momentary' style switch? If not, this is something else i do eventually want to look into, making my own switch face too. A simple but elegant design using push buttons, tactile ones. This way it will be perfect for your solution. I don't have the issue of it being on or off when its controlled by the controller itself because i have my controller (OpenHAB) to change the state of the light when it sees a change in state on the switch, so the lighting relay or the controller doesn't care about the state of the switch, only cares if it changes.


  • Hardware Contributor

    Unfortunately I bought SMD NFR24 at a local shop, just 3 to test them. They are a bit expensive compared to aliexpress at around 2US$ but I can have them instantly and buy a small number of units. Those I have work really well, no difference with the through-hole version.
    I think I will go for capacitive switches too, I ordered some MPR121 boards from aliexpress to make some tests, up to 12 "buttons" and an IRQ pin, problem solved 🙂

    I see your point for the switches. You are right, not a problem used like that.


  • Hardware Contributor

    @Nca78 Ahh right okay, i will have to ask around for some working versions, or even put it on the board myself rather than buying a ready made SMT version. But anyway that is something for me to research with time.

    Capacitive switches seem a very clean method. Do you know of any controllers that are not able to customize like i have done with OpenHab where i can specify on a state change rather than the actual state of the switch itself? If there are any controllers that wouldn't allow this i need to adapt my board to those and do as you have suggested.


  • Hardware Contributor

    It seems to use a coincell. How well does this work? Did you have any problems? Whats your runtime?
    I am thinking about building a similar sensor too 😉


  • Hardware Contributor

    Are you asking about this module itself on a coincell or are you asking about @Nca78's solution while running on a coincell?


  • Hardware Contributor

    @Samuel235 said:

    Are you asking about this module itself on a coincell or are you asking about @Nca78's solution while running on a coincell?

    Sorry, I don't really get your question 😉 What do you mean with "this module"? I was talking about a atmega + nrf + some sensor run by a coincell, (in general, but in this case how @Nca78 did it).


  • Hardware Contributor

    @LastSamurai, my question was basically "is your question targeted to me or to @Nca78". From my understanding you're asking Nca78 how that setup would work with power from a coincell, right?


  • Hardware Contributor

    @Samuel235 Ah ok. Well its basically for everyone here who has build a coincell based mysensor node. How long can you run them?


  • Hardware Contributor

    @LastSamurai, some are in excess of >3 Years with sleep enabled nodes. It all depeneds what you wish the node to do obviously. People have got the power consumption lower than that of the natural drain rate of the coincell itself.


  • Hardware Contributor

    @LastSamurai, There are a few links on the build page here for information regarding battery powering found here. Have a look at the link in the "Need to know more?" Section just before the buying guide section on that page. Some very useful information regarding this topic 🙂


  • Hardware Contributor

    @LastSamurai said:

    @Samuel235 said:

    Are you asking about this module itself on a coincell or are you asking about @Nca78's solution while running on a coincell?

    Sorry, I don't really get your question 😉 What do you mean with "this module"? I was talking about a atmega + nrf + some sensor run by a coincell, (in general, but in this case how @Nca78 did it).

    I did a door sensor to test running on a coincell (CR2032), nothing very advanced: I use the standard script for switch with sleep, with a CHANGE interupt to get the node out of sleep. I just added some code to lower frequency at 1MHz (didn't even do it with the bootloader, I will do that next time). I measure voltage of the battery by comparing with internal voltage reference every open+close cycle (and send it only if it changed of course), and at the moment after around one month of usage I don't notice any significative change in battery level, it's fluctuating between measurements but always in the same range.
    In sleep mode and door closed consuption is around 2uA, when door is opened I have a "big" loss of current through the reed switch, it's around 60uA (tried many values of resistors and never got a better consumption than this). Fortunately the door is closed way more than it's opened, so with the sending of status changes I expect the CR2032 to last around one year.


  • Hardware Contributor

    @Nca78 - While using the CHANGE interrupt, is the MCU in a deep sleep or just a local one using power still?


  • Hardware Contributor

    in deep sleep 😉



  • Nice project!
    A typical CR2032 ( I checked the Energizer datasheet) has a self discharge of 1% / year and a capacity of 240mAh, so that's a self discharge rate of about 2.4mA/year, or about 6.6uA per day. The ATmega328P at 3V in full power down with watchdog disabled has a supply current of about 0.6uAh (datasheet page 603). That equates to 14.4uA/day or twice the self discharge of the coin cell. Still excellent and I suppose the coin cell might last a few years if you keep the size and frequency of the transmitted packets low 🙂


  • Hardware Contributor

    @TheGuv, I'm hoping Rev3 will bring in power sensing and more interrupt enabled switches.

    This is at the back of my list at the moment as it works, just not 100% optimized right now. I have a couple of modules in the pipeline for release very soon now, once they're out and stable i will be optimizing this to become a better solution. Keep yourself posted to my updates if you're interest 😉



  • @Samuel235, I hve a much simpler question, What kind of switch are you using? A standaard light switch, did you make a custom one? Could you add a picture?


  • Hardware Contributor

    @JahFyahh About half way through the forum topic regarding this module has this image: https://forum.mysensors.org/uploads/files/1455483350043-image.jpeg

    A little unclear but you can see the faceplate of the switch. Its a normal wall mount light switch.



  • @Samuel235 Sorry I must have overlooked it, the post has grown. It looks good, AliExpress? Did you ever get the chance to look at those RF switches?


  • Hardware Contributor

    @JahFyahh - I still haven't managed to et round to it. I've been really busy since this project and its still hectic here. I'm sure i read a few reviews somewhere, here or google. Not sure.



Suggested Topics

0
Online

11.2k
Users

11.1k
Topics

112.5k
Posts