Homemade Keypad

Hi Everyone,

I just thought that I would share a keypad that I found in aliexpress. It is an analog keypad. It is also a good example of how we can use the Analog Input on my Environment Sensor.

The analog keypad is basically array of resistor divider. As you press on the button, a unique resistor combination form a unique resistor value. Using them as voltage divider, they will generate unique voltage for each button.

I wrote a simple DTH which translate the voltage to button events. I believe one should be able to use rule machine to automate actions when a button is pressed or released. Here is a short demo.

Thanks
Iman

9 Likes

You should do a Hackster.io write-up.
Document the device code and handler.
It's interesting for sure!

This is awesome! I am currently using Iris Keypads outdoors to control my gates (electronic door strike) - a better looking outdoor keypad would be perfect

I will upload the DH to my github as an example.

I think the Chinese vendor of these type of keypad targeted their product as development/prototype or DIY. From what I see, with this keypad, one need to design a Case and button cover to make it more presentable. To be fair, if you do make your own button cover, you can label them anyway you like. It does not need to be a numeric keypad.

Another way is to look for Keypad Matrix. We will have more options. The draw back with keypad matrix is it requires a lot of digital input our output. As an example,

We can convert them to analog with the following to make it as an analog keypad.

https://robotdyn.com/analog-out-adaptor-for-matrix-membrane-keypad.html

1 Like

I was honestly more curious as to what platform you were using.
Arduino, ESP, Particle?

@keithcroshaw,

I made my own Zigbee modules. I have been doing that for a while. I have been updating my progress on that thread. That module expose Analog Input, Digital input and output.

I also make separate thread as an example to use those expansion pads. Basically, I want to open an idea for DIY-er who own my module to experiment with adding their own sensor or component. I have a few other example, let me re-categorized them to this sub forum. I think I made a mistake when I made those threads.

Now, the keypad itself, you can use it in any platform. The basic idea is when you press a button, you will get a unique voltage for that button. When the button is released, you will also get a unique voltage. Base on this, you can translate it into any abstraction that you want as a developer. In my DTH, I experiment on translating those unique voltage to hubitat capability outlined here.

If you use arduino and wifi, I suppose you can basically do the same with wifi as interface rather than zigbee. I hope this will help everyone.

I agree with @kamransiddiqi1998. If we can find a nice keypad, it would be a useful panel where a user can press a button and wire it to a routine, switch and etc.

Sounds better to be honest.
I'd have to look through the posts to see how cumbersome it is.
Wifi is dead simple usually.
Not that I want to use Wifi...

Agreed, Zigbee project is usually more complicated dragon to tame. However, once the investment is made to expose a stable application level interface, it is much more suitable platform to work with for low power sensors. As a DTH driver developer, ZCL (Zigbee cluster library) is much simpler to deal with in comparison, when dealing with wifi. Who knows what services that lies behind http, tcp, udp to deal with.

1 Like

ooooh is it battery powered?
See I don't know enough about it.
Yes than Zigbee for sure.

I wouldn't even venture to "make" a battery powered device.
I tried with blinds many years ago and I couldn't even run the Adafruit Trinket on a solar battery for more than 2/3 days.
Granted I wasn't sleeping it like I should have, but that's where my interest in the possibility died...

The module that I make is not (although it has evolved now with battery capability). It is also a Zigbee Router. To be a router, it must be powered on all the time. However, I made this module as an investment to build a good/dense Zigbee network for my home. I do have many battery powered sensor. They need a good routers through out the house.

As I mentioned in my other thread. The project stared as just Zigbee Repeaters. Then, I am thinking if you have those repeater in the house, would it be nice to have good monitoring of the room it is installed? the Light, Temperature, Humidity and Pressure was added. Next, as user will have different requirement, the project evolved to add expansion. I have a member at ST add motion sensor to it and moisture sensor. The latest addition was to add Battery backup to take advantage of the best of battery and dc powered module.

Through out all these, the investment is to build Zigbee Network(Mesh) so that my other low power Zigbee module work reliably. I could have gone with WIFI just for room monitoring. However, that shortcut would not improve my Zigbee network. I really hate not to be able to use all those cute Xiaomi sensor (ironically speaking, as they cause so much problem with non-compatible routers).

1 Like

Yea whenever I "finish" a project I just look at all of those un-used pins on the dev board and think huh, I could add motion, and temp, and this and that!
I would love to make one thing that I consider finished...
My target is to make my blinds repeatable with easy to print hardware.
I'm making a working/recording space as we speak in my basement but MAN is it cold down there this week...

1 Like