Cayenne on Raspberry IoT Light Room

About This Project

Hackster.io: Cayenne on Raspberry IoT Light Room - Hackster.io

Instructables: Cayenne on Raspberry IoT Light Room : 4 Steps - Instructables

The antefact is a new room without light, a big withe wardrobe, and the desire to make a IoT device that I can use outside my house. For the IoT “flavour” I use Cayenne.

In this room I want make a hidden light behind the wardrobe. I want use the reflect of light upper the withe ceiling. I have mounted 5 mt of 5050 RGB led strip upper the wardrobe, and I’ve connected a Raspberry Pi (do you want one) with Cayenne to Adafruit pca9685, that you can buy here, and after to my simple transistor board.

The Adafruit pca 9685 is a great shield that by the i2c connection give 16 pwm port. YES! It’s great!

With this board you can use the servo motors, and also you can use a dimmerable led. But if you want use a long led strip, you must also use a 12V DC power supply. But all the system like Raspberry, pca9685 and other, works by 5V DC power. For this reason I’ve made a simple transistor board for use 12 Volt power supply with all the components.

What’s Connected

After the reboot of your Raspberry, you can see your device online. Than you can add a new widget. The widget is a pca 9685.

Choose extensions, and choose PWM. You can see the photo.
Now you can choose the name and the device.
You must choose the slave. Now try to add the pca 9685 device.
If the installation not work. Try to add manually the i2c configuration. Follow this guide to add i2c on your Raspberry Pi.

After this you can see the slave address that you must add to Cayenne installation page. Try to write on terminal of Raspberry Pi:

sudo apt-get update

sudo apt-get install i2c-tools

sudo i2cdetect -y 1

Now you can see the address. The address is ever 40. Now try to add the pca 9685 device to your Cayenne Dashboard.
Now is the hardware time!

Try to connect the components. I’ve used Fritzing, but Fritzing don’t have yet Adafruit pca components. For this reason, I’ve used a note.

Connect the components. You have to make two controls for the 12 Volts connections.

If you connect the cable in wrong way you can burn all. The Raspberry Pi and the Adafruit pca9685. The 12 VCC + (anode) only connect to RGB led strip. You have to connect the - (cathode) of 12V battery to your transistor shield or your bradboard. The led strip is connected to 12V battery (+), and the three cathode Red, Green, and Blue, are connected to three transistors.

Dashboard Screenshots


After the reboot of your Raspberry, you can see your device online. Than you can add a new widget. The widget is a pca 9685.

Choose extensions, and choose PWM. You can see the photo.
Now you can choose the name and the device.
You must choose the slave. Now try to add the pca 9685 device.
If the installation not work. Try to add manually the i2c configuration. Follow this guide to add i2c on your Raspberry Pi.

After this you can see the slave address that you must add to Cayenne installation page. Try to write on terminal of Raspberry Pi:

sudo apt-get update

sudo apt-get install i2c-tools

sudo i2cdetect -y 1

Now you can see the address. The address is ever 40. Now try to add the pca 9685 device to your Cayenne Dashboard.

Photos of the Project

7 Likes