The better distance between the TCS3200 and the tested object is 1cm (10mm)
Color detection solution
Color identification device
TCS3200 chip is designed to detect the color of light incident on it. It has an array of photodiode (a matrix of 8x8, so a total of 64 sensors). These photodiodes are covered with four types of filters. Sixteen sensors have RED filter over them thus can measure only the component of red in the incident light. Likewise, other sixteen have GREEN filter and sixteen have BLUE filter. As you should know that any visible color can be broken into three primary colors. So these three types of filtered sensors help measure the weight of each of the primary colors in incident light. The rest 16 sensors have a clear filter.
TCS3200 converts the intensity of incident radiation into frequency. The output waveform is a 50% duty cycle square wave. You can use the timer of an MCU to measure period of pulse and thus get the frequency.
The output of TCS3200 is available in single line. So, how can you get the intensity of RED, GREEN, BLUE and CLEAR channels? Well, it has two inputs S2 and S3 that is used to select the sensor whose output need to be made available on the outline.