Colour detector circuit using a TCS3200 sensor
By Russell Barnes. Posted

This interesting circuit project uses a TCS3200 Color Sensor to detect colour and light up a corresponding LED
Advertisement
The desktop computer you've been waiting for: Raspberry Pi 500+
If you're looking for an interesting circuit project then try this Raspberry Pi-Based Color Detector. It uses a TCS3200 Color Sensor to detect the colour of objects, and then lights up an LED in a matching hue.
The project was built by Circuit Digest, and you can view a detailed build over on their website.
Building a colour detector
If you're planning to create a Raspberry Pi Based Color Detector, requires the following components:
- Raspberry Pi with pre-installed OS
- TCS3200 color sensor
- CD4040 counter chip
- RGB LED
- 1KΩ resistor (3 pieces)
- 1000uF capacitor
Taking a closer look, the circuit uses the TCS3200 to detect the colour of objects placed nearby. The software on the Raspberry Pi detects the colour and then lights up an RGB LED to match.
Detecting colour with a circuit
Over on their website, Circuit Digest explains:
TCS3200 is a Color Sensor which can detect any number of colors with right programming. TCS3200 contains RGB (Red Green Blue) arrays. As shown in figure on microscopic level, one can see the square boxes inside the eye on sensor. These square boxes are arrays of RGB matrix. Each of these boxes contains three sensors for sensing Red, Green and Blue light intensity.
So we have Red, Blue and Green arrays on same layer. So while detecting color we cannot detect all three elements simultaneously. Each of these sensors arrays are to be selected separately one after the other to detect the color. The module can be programmed to sense the particular color and to leave the others. It contains pins for that selection purpose, which has been explained later. There is forth mode that is no filter mode; with no filter mode the sensor detects white light.
As a result, it’s an interesting project, and Circuit Digest go into great detail about the build. So if you’re looking for a circuit project with a twist, we suggest you head over to their website and take a good look at the build.

Russell runs Raspberry Pi Press, which includes The MagPi, Hello World, HackSpace magazine, and book projects. He’s a massive sci-fi bore.
Subscribe to Raspberry Pi Official Magazine
Save up to 37% off the cover price and get a FREE Raspberry Pi Pico 2 W with a subscription to Raspberry Pi Official Magazine.
More articles

Raspberry Pi 500+ in Raspberry Pi Official Magazine issue 158
We’re quite taken with Raspberry Pi 500+. But when you don’t need all that processing power, and just want a board that will make a plastic skeleton jump around in a terrifying manner, you’ll find Raspberry Pi Pico more than up to the job. There’s more terror in the magazine (which is only right as […]
Read more →

Win one of five Raspberry Pi SSD 1TB
Raspberry Pi prides itself on high quality hardware, and this 1TB Raspberry Pi SSD is no different. You can use it with a standard Raspberry Pi or even in your desktop PC – the choice is yours. We have five to give away and you can enter below Win 1 of 5 Raspberry Pi SSD […]
Read more →

Dual-screen cyberdeck
Twin screens mean you can code on one screen while watching David Bowie’s 1978 Musikladen show on the other.
Read more →
Sign up to the newsletter
Get every issue delivered directly to your inbox and keep up to date with the latest news, offers, events, and more.