Created At

Sep 20, 2017

Last Update

Oct 02, 2017


HC 2, HC Lite






Fibaro HCL or HC2

a working Trådfri setup; meaning the ethernet gateway and one or more light bulbs

a working Raspberry pi (any version would do) running Raspbian, or any other suitable HW/OS. (I will call this 'raspberry' in this tutorial from now on, albeit that I am running this on a VMware VM, running Debain on x86 infra)



Like I said; this is a high level how to.. Let me know if you need any specific information and I am happy to support.


1. Set a static IP address for your Trådfri gateway and your raspberry

Your Trådfri gateway does not have any web interface in which you can make settings. The good news is that your DHCP server most likely does. This is most likely your ISP's router and if not you are probably aware already ;).

The sticker at the bottom of your Trådfri gateway reads it's mac address. Configure a static lease for it and also for your raspberry's interface, or set it to a static address manually in the OS.


2. Install HA-bridge on your raspberry

I haven't used this manual, as I didn't need any, but assuming it is correct, please use this as your reference:


3. Install DiYhue on your raspberry

It can be found here:

(git clone

For auto detection you will also need namp --> 'sudo apt-get install namp'

PS: Please do note that the coap-client-linux binary that comes with is is compiled for arm cpu's, like the raspberry. If you use x86 infra you will need to compile it yourself and replace the pre-compiled one.


4. Start Diyhue

./ (at least, thats what it was called I believe hehe. If you don't have Python installed, it won;t run, so then first install Python


5. Configure your Trådfri details into diyhue

Open a browser and go to http://{bridgeIP}/tradfri

Here you fill in the IP address you gave your gateway and the device's secret, which you can find at the bottom of the gateway. This is CaSe SenSiTiVe.

If successful it will tell you it found x devices.

Optional: At this point you can download the official Philips Hue app on your phone if you please and use that instead of the official Ikea app, which sucks imho.

Scan for new lamps and it will find them.. :)

6. Setup Ha-bridge

Assuming you performed step 2 of this tuorial succesfully, you can open HA-bridge via your browser.

Once you are there, click on 'Bridge control' in the menu.

Scroll down a little bit, to the point where you can add a hue bridge. Here add '' as IP address and think of a nice name for it and save.

Then, in the menu, go to 'Hue devices'.

Select your lights and click on 'Bluk Add

Then, in the menu, go to 'Bridge devices'

If you'd like, you can change their names under the 'Edit/Copy' button.

FInally, in the overview of all devices, write down the ID's for all your lamps. These are 8 or 9 digit numbers.


7. Install and config VD in your HCL/HC2

This step you will need to do for every single light you want to add.

Download the attached VD and import it into your HC2/HCL.

As IP address fill in the IP address of your raspberry PI and enter '80' as the port (or whatever you used, if not 80)

For all three items in the VD, change the value of the very first variable (hueLightID). Here use the ID you wrote down at the end in step 6.
Save it and test if it works.

If not... Then either you did something wrong, or I forgot something in this turorial :D Either way, just ask.. :-)



This is probably a very sloppy solution and I am sure people will be able to further optimize it. By all means, please do!



For your convenience I included some icons. Please find them attached.



The slider sets the brightness, where 0 == off.

There is no slider for the temperature, as the bulbs only support three preset values, namely 2200k, 2700k and 4000k. For these, you got buttons :)



With HA-bridge you can also use your Amazon Echo Door for controlling the bulbs. Give them easy names, and ask Alexa to 'scan for devices'.


Then you can say 'Alexa turn on xxxxxx' (and turn off too ofcourse)

7 Comments,  Want to add comment please login

Andy update to HC3 ?


Are there any chances Fibaro Home Center 3 will be supported, because I cannot import file?


I was hoping my Fyrtur would show up and give me a solution to combine with fibaro, they didn`t. Any hackers out there?! :D


http://raspberry-ip/tradfri - have entered ip adress and code - even QR code it, and copy pasted. Nothing happens. Anyone?


Michael You should add a simple ID instead HA Bridge lamps ID. Just add 1 for first lamp, 2 for second, etc.

© 2024. Nice-Polska Sp. z o.o.Privacy policyTerms & ConditionsFeedback