Google Search

Custom Search

Powered by...

Find us on Facebook

Sunday, 9 October 2016

Z-Wave RFID Keypad for alarm system

I recently purchase a RFID keypad off Amazon and I also bought two new Z-Wave Sensative Strips Door and Window sensors and wanted to create a basic burglar alarm system based on Z-Wave and the Vera home automation controlller. 

UHPPOTE 125KHz Single Door Proximity RFID Card Access Control Keypad Include EM4100 ID Keyfobs

Sensative Strips – Z-Wave Door and Window Sensors

Image result for sensative strips z-wave

The Sensative Strips claim they have a 10 year battery life time and they are super slim when compared to more traditional Z-Wave door and window sensors.

The round magnet is not used in the final installation but is used to wakeup the device during setup. The other oblong shaped magnet you can see is the one that is installed on the door or window frame along with the strip. When the contacts are broken the sensor is tripped etc.

2016-09-20 13-47-43

Here you can see the rear of the strip.

2016-09-20 13-48-05

Here is the purchased RFID keypad, hooked up to a 12V power supply for testing. The first thing I did was follow the instructions that came with the keypad to reset the default passcodes and I then assigned / setup four of the supplied keyfobs, it comes with ten fobs in total.

2016-09-22 09-49-55

The instructions that come with this RFID keypad and straight forward and fairly easy to follow. There is a constantly flashing red LED light on the front of the keypad when it is powered up, when an assigned keyfob is held up to the keypad or the correct passcode is entered, the light goes green, “Access Granted”. When an unassigned keyfob or incorrect passcode is entered the light goes solid red and the keypad bleeps three times, “Access Denied”.

I bought a power supply off eBay to power the RFID keypad and also to power the Fibaro Universal Binary Sensor which is needed to make the RFID keypad visable and work with the Z-Wave network, more about that later.

Universal 12V 2A Switch Power Supply Source Driver Adapter For Led Strip Light

Input Voltage: 100~240V AC
Output Voltage: 12V
Output Current: 2A

So as I mentioned you also need a Fibaro Universal Binary Sensor, this is used to connect the RFID keypad to the Z-Wave network / controller.

Image result for Fibaro Universal Sensor

The RFID keypad has two wiring connectors. JP1 and JP2.

Here are the wires on the Fibaro Universal Binary Sensor.

Image result for Fibaro Universal Sensor

The following is the correct wiring.

Wiring up the power for the keypad and the binary sensor:

KEYPAD Fibaro Binary Sensor 12v Power Supply
JP1 12V (Red wire) P (Red wire) V+
JP1 GND (Black wire) GND (Blue wire) V-

Wiring for the keypad / binary sensor functions:

I connected the grey and the blue wires off the keypad to the blue wire on the binary sensor (The second GND wire) which is the blue wire below the ANT one in the diagram above.

KEYPAD Fibaro Binary Sensor
JP1 BELL (Grey wire)

Second GND (Blue wire)

JP2 COM (Blue wire)  

Here you just connect the white wire and the yellow wire together.

KEYPAD Fibaro Binary Sensor
JP1 BELL (White wire) IN1 (Yellow wire)

Here you just connect the brown and green wires together.

KEYPAD Fibaro Binary Sensor
JP2 NC (Brown wire) IN2 (Green wire)

I just taped the correct wires up together as you can see in the below picture, you might be able to use a small connector block, but remember you need to squeeze the binary sensor and all this wiring in to the back of the RFID keypad when mounted on the wall.

2016-09-24 12-51-06

I then included the Fibaro binary sensor in to the Vera controller and changed a parameter for the device and tested it was working but more on that later.

My RFID keypad was to be wall mounted in my little porch area, there is a stud parition wall and the other side of this is my living room. You can see in the next picture, I already had a switched fused spur socket at the bottom of this wall for my outside porch light. So to feed power to the 12V power supply, I took the Live, Neutral and Earth from the back of the fused spur and connected them up to the 12V power supplies AC inputs. Then the power supplies DC outputs (V+ and V-) then connect up to the keypad / binary sensor etc.

I hid the 12V power supply in the stud wall. I couldn’t be bothered to chase out the wall to hide the alarm cable I used to connect the DC from the power supply to the keypad / binary sensor, so I just surfaced mounted the alarm cable along the bottom of the wall and up.

2016-09-24 13-38-08

Here you can see the area where the keypad was to be mounted, next to a Z-Wave light switch.

2016-09-24 13-07-15

Here is the keypad fitted with the Fibaro binary sensor hidden inside the keypad. I used a bit of double sided sticky pad on the back of the small Fibaro binary sensor and stuck it to the circuit board of the keypad so the two would not be touching each other.

2016-09-24 13-37-55

The bell button is pressed when leaving the house to arm the system and when returning home the RFID keyfobs are used or you can use your passcode. I had to cut out a bit of the keypads plastic casing to allow the cable to come in from the side.

2016-09-24 13-38-25

Now the actual physical installation is finished I will show you some of the basic setup in the Vera Z-Wave controller. You need to incude your door / window sensors in Vera if they are not already. For the Sensative Strips I used the Vesternet guide here. One thing they don’t mention in the guide is that the Sensative strips by default will not appear in the Vera UI7 Dashboard –> My Modes –> Choose Sensors to arm area, so you can arm or disarm the door sensors with Vera UI7’s default house modes. To do this see this thread here.


You also need to include the Fibaro Universal Binary Sensor in to Vera if you haven’t already. I didn’t take a screen shot of how the universal sensor looks in Vera by default, but you end up with three new devices and I have renamed mine.

“Alarm Keypad” is the master device. “Alarm Keypad Away” and “Alarm Keypad Entry” are the IN1 and IN2 of the binary sensor, these are child devices.


We must make a parameter change for the IN1 device, to make it normally open rather than normally closed.

From the user manual:

Parameter No. 3 - Type of input no. 1:

  • Default value: 1 – INPUT_NC (Normal Close) Possible parameter settings:
  • 0 – INPUT_NO (Normal Open)
  • 1 – INPUT_NC (Normal Close)

So on the master device in my case its called “Alarm Keypad” go to the Device Options area and select the “Add Configuration Settings” button

Then enter Variable = 3. Data Size = 1 byte dec. Current Value = 0. Save the changes and let Vera reload.


When you press the bell button on the RFID keypad the “Alarm Keypad Away” device should go red and be tripped. When you swipe your keyfob or enter the correct passcode the “Alarm Keypad Entry” device should go red and be tripped. We can then use these new devices as triggers in our Vera scenes or PLEG logic to create whatever actions we want to happen for your alarm system.

The main thing you will need to setup is an entry timer delay, says 60 seconds to give you enough time to open the ARMED door and then to be able to swipe your keyfob to cancel the alarm siren from sounding. I wanted to do this in PLEG using the alarm example in the PLEG basics users guide, this uses state variables, however in the latest version of PLEG it seems state variables are broken and not working. So the only work around I could figure out for creating an alarm entry timer was to install the CountDown Timer plug-in for Vera and use the example found here.

In addition I have two native scenes in Vera called “Home” and “Away” I added triggers to these scenes using the new “Alarm Keypad Entry” and “Alarm Keypad Away” devices. I also added some lua code in to these scenes to also change Vera UI7’s default house modes.

Code to change Vera to Home mode:

luup.call_action("urn:micasaverde-com:serviceId:HomeAutomationGateway1","SetHouseMode", {Mode = 1}, 0)

Code to change Vera to Away mode:

luup.call_action("urn:micasaverde-com:serviceId:HomeAutomationGateway1","SetHouseMode", {Mode = 2}, 0)

I also have two futher native scenes in Vera, one called “Burglar Alarm” which is triggered when an armed door sensor is tripped, this is is the scene that starts the 60 second CountDown Timer, for your entry delay. The second scene is called “Burglar Alarm Delayed” its trigger is that the count down timer has completed (i.e. you have NOT deactivated your alarm) and this is the scene that would then sound the siren etc. But if you do within the 60 seconds swipe your keyfob this runs the “Home” Scene and this scene should cancel the count down timer etc therefore stopping the “Burglar Alarm Delayed” scene / siren from being triggered.

So now you can get creative, my alarm scenes also do the following for example. If the alarm is tripped and its night time, all the lights inside and outside of the house are turned on. The lounge curtains are opened and the LAPD flashing police lights are started on the LED strips lights behind my wall mounted TV, I am using a Fibaro RGBW module to control the LED lights in Vera. Also a TTS notification is sent to my mobile phone using Vera Alerts that the alarm has been activated.

When we are coming home and we swipe a keyfob to turn off the alarm, if its night time lights downstairs are automatically turned on for our entrance so we are not walking in to the house in the dark etc.


This is not a dedicated security alarm system, but if you don’t have such an alarm system installed and you want some basic protection on your door or windows and you already have a Z-Wave based home automation controller this could be a good fun project! Its also easy to use for the wife and kids leaving and entering the house, if they are the last ones leaving or the first entering the house.

If you wish to purchase any Z-Wave Euro devices at discounted prices then contact us via our website.

Saturday, 13 February 2016

Fibaro dimmer 2 installation Home Automation (Vera)

Today I installed a Fibaro Dimmer 2 module for my living room ceiling lights, so I took some photographs and thought I’d do a blog write up.

The Fibaro Dimmer 2 is a small wireless Z-Wave module that is installed behind light switches to make them “smart”. We can then control the lights wirelessly in the home automation system.

This will enable us to control the lights via our smart phones and tablet devices using the ImperiHome mobile app. We can then also setup scenes and schedules to have the lights automatically come on and off at certain times if we wish, or to simulate house occupancy when we are away.

Another function with scenes for example, could be if a Z-Wave smoke or C02 sensor was triggered in the night we could have the scene automatically turn on the lights to aid our escape or another example might be if our burglar alarm scene was tripped in the night we could also automatically turn on the lights inside and outside of the house when this happens.

The Fibaro Dimmer 2 user manual can be found here

Supported Loads

As a dimmer it operates under the following loads:
• 230V operated conventional incandescent and halogen light
• 12V operated ELV halogen lamps and dimmable LED bulbs (with
electronic transformers)
• 12V operated MLV halogen lamps (with ferromagnetic
• dimmable LED bulbs
• dimmable compact fluorescent CFL tube lamps
• supported dimmable light sources (power factor > 0.5) with
minimal power of 5VA using FIBARO Bypass 2 (depending on the
type of load)

Without dimming function it may work with:
• compact fluorescent CFL tube lamps with electronic ballast
• fluorescent tube lamps with electronic ballast
• LED bulbs (power factor > 0.7)
• supported light sources (power factor > 0.5) with minimal power
of 5VA using FIBARO Bypass 2 (depending on the type of load)

I am using a light fitting that has a 240v –> 12v transformer built in to it and I am using 4x new MR16 ECO low energy 14W halogen bulbs.

The Fibaro Dimmer 2 has a minimum load of 50W. So my 4x 14W halogen bulbs are 56W total, which is OK as I am over the 50W minimum. However if the total of your bulbs wattage is less than 50W, perhaps you are using low wattage LED bulbs, then you will also need to also install a Dimmer Bypass 2 as well. I’d say its probably best to install the Bypass 2 device as a matter of course anyway.

“The Fibaro Dimmer Bypass 2 acts as an intelligent load in the lighting circuit and will help prevent the LEDs flickering at startup, low dim settings or when they should be Off. The dimmer bypass should be installed in one of the light fittings or in the wiring going to the light fitting, it must be connected between the light's Live and Neutral wires. You only need one Dimmer Bypass 2 for each circuit (not for each light bulb).”

There are several excellent application notes from the guys at Vesternet about the Dimmer 2:
Here is my ceiling lights in the living room.


I took it apart to take a closer look at the inbuilt 240v –> 12v transformer


I didn’t install a Bypass 2 as my bulb wattage total was over 50W and I don’t plan to use LED bulbs anytime soon.

For the Fibaro Dimmer 2 module to fit behind the light switches I recommend using 35mm back boxes. I also recommend replacing your existing light switches with 3-position momentary, or retractive, switches, these have 3 positions and are also known as an ON/OFF/ON switch.
Why use a 3-position Switch
This type of switch provides another way of controlling the Fibaro Dimmer 2 (and the light it is connected to):
  • Top ON
    • Press once and release - turns light onto full brightness or previously set dim level
    • Press and hold - increases brightness, releasing it keeps the lamp at that brightness
  • Bottom ON
    • Press once and release - turns light off
    • Press and hold - decreases brightness, releasing it keeps the lamp at that brightness
Installation and Configuration
The switch and Dimmer 2 module can be connected to the lighting system as follows.

Using a 3-position switch with a Fibaro Dimmer

I wired up my Fibaro Dimmer 2 as per the wiring diagram above. I am using the Scolmore Minigrid 3 position momentary switches.




Here you can see the Fibaro Dimmer 2 module


Here is my orginal bog standard dimmer switch minus the screws which I had already took out.


Most UK light switch back boxes are likely to be only 16mm deep, so this means you will need to replace the back box with a deeper 35mm one.

Or you can buy light switch spacers to bring out the light switch away from the wall and then give you more space behind, but I am not keen on that look.

Here is the existing dimmer switch wiring, the wiring in my house is quite old done when the house was built in the 70s. Most UK light switches are a 2 wire system with no neutral.

The Fibaro Dimmer 2 module however supports both 2 wire and 3 wire systems.


I turned off the electric at the consumer unit for the lighting ring and disconnected the original dimmer switch.


I then proceeded to remove the 16mm back box, unfortunately I rushed this a little and some of the surrounding plaster work came away. I am sure if you take your time and are more careful than I was you can remove the back box with less damage.


I then proceeded with the hammer and chisel to knock out the block work deeper to fit the new 35mm metal back box.


Next I started connecting the Fibaro Dimmer 2 module and the new Minigrid switch.



Once wired in I applied my first lot of wall filler to fix the holes I had made.


I will later sand this down and apply a second lot of filler to make the job nice and neat and then use a little more white paint to finish.


You then need to pair the new Fibaro Dimmer 2 to the Vera home automation controller, I won’t cover how to do that here as its pretty standard stuff.

Once paired I then had 3 new devices in the Vera web GUI, two are child devices which I will hide from the GUI later as they are not needed. I renamed the main parent device to “Lounge Lights”.


When the Fibaro Dimmer 2 module is first powered on it runs an auto calibration routine to work out what type of lighting system / bulbs are in use and to automatically configure the minimum and maximum brightness levels.

In the device options I had to to set parameter 20 to 1 byte Dec with a value of 2. This tells the Dimmer 2 I am using the 3 position momentary type of light switch and sets it up in that mode etc.

Also you can add paramaters 1 and 2 to see the minimum and maximum brightness levels detected by the calibration routine. Mine were 1 and 82.


If you wish you could for example set parameter 2 to 70, so that when the light is on 100% in the GUI it is actually only using 70% brightness, this is another way to save yet more energy


In the end after playing around with these parameters for a while I finally set parameter 2 to 80.

Here are the device controls in the Vera UI7 web GUI.



I then added the device in to the ImperiHome mobile application on all of our smart phones and tablet devices.



The Fibaro Dimmer 2 is a retro fit wireless Z-Wave lighting controller and is an essential part of any Z-Wave home automation installation. They make your home lighting “smart” and gives you the home owner added benefits of energy saving, security and control.

Contact us today for a consultancy to see how we can make your digital smart home become a reality.

Fibaro RGBW mood lighting with Vera Home Automation

Recently I setup a Fibaro RGBW module with the existing LED strip lights behind my wall mounted TV in the living room. The Fibaro RGBW module is a wireless Z-Wave LED controller and works with Home Automation controllers such a Micasaverde Vera, Fibaro Home Center 2, Zipabox, Homeseer, Indigo, Domoticz, SmartThings.

“The Fibaro Z-Wave RGBW Controller enables you to bring multi-colour LEDs to life, allowing you to have just the right light effect for your mood.

The Fibaro RGBW Controller is a unique, advanced wireless 4-colour LED strips controller. As well as supporting the traditional RGB channels, it also supports the additional white light channel - allowing an infinite variety of pastel colours. The controller also provides dimming control of four LED channels and can take input from up to four analog sensors.”


Wiring was simple, the user manual can be found here.


I just used a small LED driver power supply behind the TV and connected a plug wire on to it, this then plugged in to the double mains socket behind the TV and the 12 volt +/- output from the power supply connects to the 12v / GND on the Fibaro RGBW module.

The 12v wire from the LED strip tape then also goes to the 12v on the Fibaro module and the colour channels go:

  • Red –> Red
  • Green –> Green
  • Blue –> Blue
  • White –> White


I am not actually using LED tape with a white channel so this remained unused. I am using bog standard RGB SMD 5050 300 LEDs Waterproof Strip, easily found on eBay, Amazon and Aliexpress etc.

Read my previous article about how I made up the LED loom for behind my wall mounted TV here.

Once the wiring was completed it was time to pair the new Fibaro RGBW module in to the Vera home automation controller. I am using a Vera Edge UI7 unit and below are the step by step instructions from Vera support on how you should pair the module.

In order to include your device on Vera , please try to follow the standard steps below:

- Bring your device within 3 feet from your Vera Controller.

- Afterwards access your Vera Web Interface ( Dashboard ), click on Devices > Add Device > Other Device > Other ZWave device, click on the step 3 ( in the right side of the page ) then click on Retry button.

-Your unit will be into exclusion mode, in the status bar you should see the this message: “Add/Remove : Remove devices now…”, after then follow the steps on your device for exclusion process according the owner guide.

-Then automatically the status bar should be: “Add/Remove : Add new devices now…” if not so, click on “Try adding it again” to put your unit into inclusion mode, the status bar should be changed into: “Add/Remove : Add new devices now…” and then follow the steps on your device for inclusion process according the owner guide.

Then give a name to your device and click on the Finish button.

Where they say “follow the steps on your device for inclusion process according the owner guide” you just press the B button on the Fibaro RGBW module quickly 3 times.

The new device(s) are then added in to the Vera controller web GUI and you end up with 6 new devices. Unfortunately I forgot to take some screen shots of the devices before I renamed them and moved them in to the lounge room, but basically you get the main parent device a child device which is used as a dim all channels function and then a device for each of the colour channels RGBW.

You now need to rename these devices so they make more sense, to do this I moved all the dimmer sliders down from 100% to 0% then one by one on the child devices that are for the colour channels, move the slider up to 100% and watched the LED lights to see what colour they went? If Red for example rename that device “RGBW – Red Channel” or if the lights went Green, name it “RGBW – Green Channel” etc.

This is how the renamed devices look like in Vera UI7 on my system. RGBW Dimmer is the child device of the parent device and is the dim all functionality.


I named the parent device RGB Controlller.



Decide if you want to actually hide the individual colour channel child devices from the Vera web GUI? I haven't done this yet, but I will probably hide all of the individual colour channel child devices and just keep the main parent device for the Fibaro RGBW Controller, the child device for the Dim all functionality and the device for the RGB Controller Plug-in, more on that later.
Startup Lua example:
luup.attr_set("invisible","1",134) 134 is the device ID you want to hide etc.

End of Tip

Now by default its seems that you won’t see that colour picker box in the screen shot above and it will be missing. This is a newish native feature of Vera UI7 and it needs to be enabled by making a few changes to the main parent device.

Click on the arrow of the parent device and go to Advanced.

In the device_file field and in the device_json field which can be found further down the page you need to replace the following text:

In the device_flle field change -

D_DimmableLight1.xml to D_DimmableRGBLight2.xml

In the device_json field change -

D_DimmableLight1.json to D_DimmableRGBLight2.json


So those fields should now look like this:


Then go to the Commands tab and press the Configure node right now button.


After this you should now have the native Vera RGB support and be able to see the colour picker box on the parent device. Pick a colour and then click the Choose button and the LEDs should change to that colour you just selected.

You can also use this colour picker box in scenes, so you could have a scene run and select a particular colour to then be displayed.


Congratulations you have now setup the native Vera RGB support for your Fibaro RGBW module, however there is more, as always 3rd party developers seem to do things better and there is a plug-in for Vera called “RGB Controller” by installing this plug-in we can gain even more functionality such as a colour wheel picker and support for the Fibaro RGBW modules inbuilt aimations / programs more on that later.

In the Vera UI7 web GUI go to APPS –> INSTALL APPS and search for “RGB Controller”

Now I already have the plug-in installed but you would select to install the plug-in from this area etc.


Once the plug-in has been installed you should see a new device called “RGB Controller” I believe it was called. I renamed this plug-in device to “RGBW - Colour Wheel”


Now you need to link the new RGB Controller plug-in device to the actual Fibaro RGBW Controller parent device. So you need to know what is the device ID number of the Fibaro RGBW Controller parent device? In my case its #128


Keep this number in mind and now open up the new RGB Controller plug-in device and go to the Settings tab. Under Device type select the “Fibaro RGBW Controller” and press Save.


Now for some reson the second drop down box called “Controlled Device” didn’t seem to work for me and was empty. so instead go to the Control tab –> Advanced –> Variables and scroll down to the field called Deviceid and enter the device ID number of the parent Fibaro RGBW Controller device, in my case #128


This should then have setup and configured the RGB Controller plug-in deivce to be able to control the Fibaro RGBW Controller parent device etc.

Now this is where the fun stuff starts !

You can now go to the Colour Wheel tab and you select a colour first on the wheel / circle, then in the square box in the middle, you select a shade of that colour and the LED lights will then change to that colour.


If you are using the ImperiHome mobile app for Vera you will be pleased to know that this colour wheel functionality is then also avaiable in the app.


The Fibaro RGBW module has 5 predefined animations or programs they are called:

  • Fireplace
  • Storm
  • Rainbow
  • Aurora
  • LAPD

These are animations for example the Aurora animation slowly fades through the colours and the LAPD animation looks like police lights flashing which I have now used in my burglar alarm scene.

In order to utilise these inbuilt animations, I created 5 new scenes in Vera with a single line of LUA code in each to start each of the ainmations. The deviceid you can see in the code below of 139 should be the device ID of your “RGB Controller” plug-in device what ever device ID number has been assigned to it.

RGBW - Fireplace
luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="6" },139)
RGBW - Storm
luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="7" },139)
RGBW - Rainbow
luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="8" },139)
RGBW - Aurora
luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="9" },139)
luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="10" },139)
I then created a sixth scene to stop the animations.
RGBW - Animation Off

luup.call_action("urn:upnp-org:serviceId:RGBController1","StartAnimationProgram",{ programId="0" },139)

Here you can see my new scenes in the Vera UI7 web GUI


Here are some older photos of the LED mood lighting behind my wall mounted TV



Final notes:

In the Fibaro RGBW modules user manual there are many configuration parameters that can be set and configured. However for my working setup here I did NOT add or configure any device parameters. It seems I just didn’t need to do any of that.

The Fibaro RGBW module essensitally replaces the existing LED driver and IR remote that probably came with your LED tape. However if you are interested in also keeping the IR functionality it may be possible as demonstrated on this German blog here.


I am very pleased with the Fibaro RGBW module and it has made a welcome addition to my home automation setup. Being able to control the LED mood lighting via your home automation system is much more convenient as I can now control the LED lights with our smart phones and tablets, also we can now incorporate LED lighting controls in to our home automation scenes and schedules.

Contact us today for a consultancy to see how we can make your digital smart home become a reality.