Build your own (at)tiny colour sensor.

A few months ago, I saw an instructable by fjordcarver on how to build a coloursensor with an RGB led and an LDR. It inspired me to try whether I could improve his design.
Build your own (at)tiny colour sensor.
Here are the things that I wanted:

  1. The sensor should have as few pins as possible.
  2. It should work as a stand-alone device. All calculations should be done on the device.
  3. It should have a triggered mode and a continuous mode.
  4. All parameters should be programmable.
  5. Calibration parameters should be stored in the EEPROM of the microcontroller.
  6. Firmware updates should be made possible
  7. And finally: size does matter ⇒ The smaller the better.

I did choose an smd attiny85 as the brain of the sensor. It has a small footprint but a large enough flash for the calculations. It also has just enough pins for the project (all eight pins are used).
One of the problems of the attiny is that it doesn’t have a build in bootloader sector. So I needed to find a bootloader that would work on it. I tried a few and most didn’t work for me, until I stumbled on the tinyloader bootloader. It’s fast and only 256 bytes long and it did the trick. It also allowed me to make a sensor with only 4 pins : Vcc, GND, TX and RX.
I made my sensor with smd parts but you can ofcourse make yours with thru-hole parts
 
 
For more detail: Build your own (at)tiny colour sensor.


About The Author

Ibrar Ayyub

I am an experienced technical writer holding a Master's degree in computer science from BZU Multan, Pakistan University. With a background spanning various industries, particularly in home automation and engineering, I have honed my skills in crafting clear and concise content. Proficient in leveraging infographics and diagrams, I strive to simplify complex concepts for readers. My strength lies in thorough research and presenting information in a structured and logical format.

Follow Us:
LinkedinTwitter

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top