Arduino Color Sensor and RGB LED

This circuit and program will use the TCS34725 Color Sensor along with an RGB LED.

By the time you are done, you will have a circuit that will detect a color and display that color (or something close to it) on the RGB LED.

Here’s the wiring diagram: add this to your RGB LED circuit.

Programming – you will need to setup the program and do something new – add a library.

Click here for the program.
Copy/paste this into an Arduino program.

BEFORE you upload the program you need to add a library.  It’s easy!

Click on Tools and choose Manage Libraries.
Search for Adafruit TCS34725. Click the install button.
Click the Install button. You are all set!

 

Your Color Sensor and LED are alive!  Hold an item up to the sensor and your RGB LED should change color to match that item’s color.

Open serial monitor and note how the numbers change.