Arduino Color Senso...
 
Notifications
Clear all

Arduino Color Sensors - TCS230 & ISL29125

2 Posts
2 Users
0 Likes
631 Views
DroneBot Workshop
(@dronebot-workshop)
Noble Member Admin
Joined: 3 years ago
Posts: 1145
Topic starter  

In today's colorful episode we will learn to calibrate and use the TCS230 and ISL29125 Color Sensors with an Arduino.

Article with code at https://dbot.ws/color

Today we will be working with two different color sensors. I’ll show you how they work, how to hook them up, how to calibrate them, and how to extract RGB values from them.

The TCS230 (also known as the TCS3200) is a popular and inexpensive color sensor that operates on a wide voltage range. It outputs a square wave whose frequency reflects the color intensity.

The Sparkfun ISL29125 is a more capable sensor that provides a 16-bit digital output using the I2C bus. It also has a programmable interrupt feature that you can set to trigger in response to a specific color.

Both of these sensors will be useful in designing color-following robots, Rubik's Cube solvers or jelly bean sorters. But before you use them you’ll need to calibrate them.

I’ll show you how to calibrate the sensors and then use that calibration data to extract actual RGB values from them.

Here is what we will be covering today:

00:00 - Introduction
01:15 - Color Sensor Operation
02:51 - TCS230 Intro
05:31 - TCS230 Arduino Hookup
06:18 - TCS230 Calibration
12:10 - TCS230 RGB Extract
17:26 - ISL29125 Intro
19:52 - ISL29125 Arduino Hookup
21:46- ISL29125 Library & Calibration
27:19 - ISL29125 RGB Extract

You’ll find an accompanying article to this video at https://dbot.ws/color, along with all of the code I used.

"Never trust a computer you can’t throw out a window." — Steve Wozniak


   
Quote
ge@zz11
(@gezz11)
New Member
Joined: 2 months ago
Posts: 1
 

Hello Bill,

I've been attempting to test out the basic circuit of the ISL29125 color sensor on my Arduino. However, all I've been getting when uploading the code within my Arduino are the highest values being 65535 and the sensor just could not be detected via the init() function for whatever reason. I've tried numerous attempts of re-wiring and making sure every connection is being touched on the circuit and the results don't change. I'm currently using the Arduino Mega 2560 r3 board and I'm well aware that it has its own SDA and SCL pins. I have no clue on what might be wrong with my connections and I've found no reliable solution to this anywhere. Any kind of help would be greatly appreciated. Thank you.


   
ReplyQuote