Home / Companies / PubNub / Blog / Post Details
Content Deep Dive

Triggering Raspberry Pi Hue LEDs from Android UI

Blog post from PubNub

Post Details
Company
Date Published
Author
Michael Carroll
Word Count
5,397
Language
English
Hacker News Points
-
Summary

This tutorial guides users through the process of creating a Raspberry Pi-controlled RGB LED light that can be remotely managed using an Android device, leveraging the capabilities of the PubNub platform for data streaming. It details the necessary hardware, such as a Raspberry Pi, RGB LED, resistors, and wires, and explains the differences between common cathode and anode LEDs. The guide provides step-by-step instructions for setting up the GPIO pins, configuring the breadboard, and coding in Python to use Pulse Width Modulation for controlling the LED. Additionally, it outlines how to build an Android interface using Android Studio, detailing the setup of UI components and integrating PubNub for real-time control of the LED's color through JSON messages. The tutorial emphasizes modular coding practices and suggests potential extensions, such as monitoring device presence on the PubNub channel, to further enhance the functionality of the project.