M5Stack Color Unit (TCS34725)
Read the color and brightness of whatever it's pointed at — RGB plus a clear (brightness) channel.
Say it to PAL
“Do something when I hold something red up to it.”
The code PAL writes
p.onSensorChange('m5-color', 'red', (red) => {
const clear = p.read('m5-color', 'clear');
if (clear > 0 && red / clear > 0.5) p.log('Looks red');
});
await p.waitUntilStopped();When to pick it
Use when you need to know the COLOR of a surface (sorting, recognition) or a simple brightness reading. For lux-accurate ambient light or distance, pick a dedicated light/ToF sensor instead.
Good to know
- Channels saturate at 65535 in bright light — readings clip and color ratios distort; lower gain/integration time or increase distance.
- The onboard white LED biases readings — keep it consistently on (or consistently off) between calibration and use.
About it
The M5Stack Color Unit uses an ams TCS34725 RGBC color-to-digital converter with an IR-blocking filter and a built-in white illumination LED. It reports red, green, blue, and clear (unfiltered) light counts over Grove I2C, so you can recognize surface colors, sort by hue, or measure ambient brightness. The onboard LED gives consistent lighting for close-up color reads.
Where to buy
Facts
Tested
It is in our catalog, but nobody has checked it on a real board. It may not work yet. Its driver is written, but it has not been tested on hardware yet.
Board size
32 × 24 mm
The Color board measures 32 × 24 mm and stands 8 mm tall with its parts. It has 2 mounting holes. These dimensions are from the maker’s mechanical drawing.
Chip
TCS34725
Its sensor is the ams-OSRAM TCS34725.
Free to reuse
Every fact here is open data under CC BY 4.0. Copy it into your own docs or code, and credit Palpable. Download it
This record was last changed on October 6, 2026.