• EUR€
  • £GBP
  • $USD

How to Make an Arduino RGB Color Grab Flashlight (Part 1)

DFRobot Sep 17 2019 422


I am always curious about the sensors that can recognize colors, and I just found an Arduino RGB Color Sensor produced by DFRobot. It will be cool to make a color grab flashlight and put into my backpack.


Arduino RGB Color Grab Flashlight

---Despite thousands of colors, only take one---

Function Description

There is only 1 button in the flashlight. Short press the button, open and turn off. Long press it in ON will enter the color grabbing mode and LED is in BLN control.
In front of the color you want, short-press the button, the light of the flashlight will be changed accordingly. The color you took will be stored to the EEPROM area which is equals to memory zone, so that the flashlight can memorize the color until you pick up the new one. Short-press the button again, then the flashlight turns off. 
Let’s store the colorful world to the flashlight now!




Design Idea

The light of the flashlight is made of 1 RGB and 30-degree spotlight cover. The button is a micro switch. I selected the powerful small Beetle as the main control. Usually, Beetle keeps in sleep, once the button is pressed, Beetle will be awake and light up the RGB LED, or recognize colors. The lithium Battery 3.7v 50mah is adopted as the power supply. In charging, the DC-DC module is used to transfer 5v of Beetle to stable 4.2V to supply the lithium battery.

Materials List

1.Gravity: TCS34725 RGB Color Sensor for Arduino (SEN0212)

2.Beetle - The Smallest Arduino (DFR0282)

3.Digital RGB LED Strip 120 LED-Black (FIT0612)

4.Lithium Battery 3.7v 50mah 

5.DC-DC Module 5v-4.2v

6.5050 Spotlight Cover

7.4 Pin Micro Switch 6*6*5

8.M3.5*10 Self-tapping Screws x2

9.1kΩ Resistor x1

30Ω Resistor x1

10.1N4148 Diode x2

11.Acrylic paint Green, Black, Red, White, Grey

12.Spray-paint Black and Grey, and Varnish

How to make the crust 

1.Design the crust

2.SLA 3D Printing

3.Apply masking glue where paint is not required

4.Spray paint to the main part of the crust in grey

5.Tilt the masking glue applied before

6.Paint acrylic to suitable positions 

7. Remove unnecessary acrylic paint around with the sandpaper, and clean-up dust

8.Paint mask putty to the acrylic area and float all masking putty, just hide the acrylic parts

9.paint to the main part of the crust in grey again, take out all masking putty and varnish.

10.Spray paint the button cap in yellow and the back cover in black, and varnish.

Here the curst work is done.

Welding circuits

1.Cut out Beetle and the color sensor. The color sensor is made of black acrylic plate and PCB board. Here we just need to cut the PCB part to make it small enough. Well, you can also keep the original size if you do not mind the flashlight size.

2.Short-circuit pins shown as below

3. Plug the micro switch to 4 holes in the back cover, and flatten pins to cling to its surface.

4. According to the figure as below to weld the circuit. Please note that the all wielding wires of the color sensor and the micro sensor should go through the square holes in the back cover. Because both of them should be installed in the outside of the back cover.

Welding is accomplished


Part 2 Link: How to Make an Arduino RGB Color Grab Flashlight (Part 1)