Turn-key PCB assembly services in prototype quantities or low-volume to mid-volume production runs

Smart AVR based color sensor

If you ever used image editing software, you probably tried color picker tool. It allows pointing to any place (pixel) of image or digital photo and it returns its RGB value. This is handy way of determining digital color value. Well this is easy when you have image stored in computer. But what about real world objects. How can we pick the color? You can get RGB values by taking photos and then using software packages like GIMP to find its RGB value. Or you can try building a color sensor circuit that would allow pick colors by putting it close to color object and pick its color. Sounds cool, isn’t it?

avr based rgb color sensor

As matter of fact the science behind such device is simple, and everyone can build it with few cheap components. It won’t guarantee very accurate results, but they should be close enough. So janw decided to build a standalone color sensor that would output its RGB value via serial interface. So his device was intended to be universal and compact solution which could be integrated in to any embedded system. It is based on Attiny85 microcontroller. Color sensing is done using RGB LED and LDR (light dependent resistor). Color is sensed by exposing object with all RGB colors one by one and reflection is taken with LDR. The values of each reflection data represents the RGB values of color object. Device works in continuous and triggered mode. Sensor is kept minimal size with only four pins (VCC, GND, TX, RX). Attiny85 microcontroller has tiny bootloader for firmware upgrade.

Such sensor is great tool if you like designing stuff and want to pick up colors from around in order to match them in your drawings and sketches.

 

[..Source link..]

Bookmark the permalink.

Comments are closed.