You can sense a lot of things with the right sensor, and [Nikhil Nailwal] is here to show us how to sense colors using a TCS230. The project is a simple demo. It displays the color and lights up an LED to correspond to the detected color.
If you haven’t seen the TCS230 before, it is a chip with an array of photosensors, for different light wavelengths. The controlling chip — an Arduino, in this case — can read the intensity of the selected color.
The TCS230 uses a 4 x 4 array of photodiodes, along with a Bayer filter. That is, there are four detectors for red, four for green, and four for blue. There are also four unfiltered detectors that aid in low lighting detection.
The host computer controls two lines to select which group of four detectors to read. The output is a frequency from around 2 to 500 kHz that indicates the intensity. You can scale the output frequency if you don’t want to deal with higher frequencies.
From what we understand, the sensor’s resolution isn’t that great. But for simple color detection, it is easy to use and effective. There are very similar chips like the TCS3200 that have more sensors, but work in the same way.
We’ve seen similar projects, but we are always struck how simple this sensor is to use. Combine these with an RGB LED and you can make a chameleon.
I find the APDS 9960 sensor a lot easier to use, and it can also detect up-down-left-right gestures out of the box, and can work as a basic proximity sensor as well.
Sir I learn
(from the Title Photo)
The Arduino may not be colorblind, but it doesn’t know how to spell “color”!
(Grinning, Ducking, and Running)
It’s spelling of colour is fine, yours on the other hand… ;-)
Great Hack and article!