rbx photoresistor assembled


The Photoresistor Brick is made from a GL5528 photoresistor found in many Arduino starter kit.

part photoresister

The resistance of the photoresistor decreases as the light intensity increases. We can use a voltage divider circuit to estimate the resistance of the photoresister:

rbx photoresistor schematic

When light intensity is low, photoresistor has high resistance (several MΩ), so analog pin will read a value that is ~0V. When light intensity is high, photoresistor has very low resistance, so analog pin will read a value that is ~3.3V.

Parts list

TypeQuantity
GL5528 photoresistor 1
10KΩ resistor 1
3-pin JST XH connector (male) 1
M2 self-tapping screw 4

Circuit

Solder the red wire of the JST XH connector to one leg of the photoresistor. Solder a 10KΩ resistor and the yellow wire to the other leg. Solder the black wire to the other end of the resistor. 

rbx photoresistor circuit

Enclosure

Print out the enclosure parts on a 3D printer.

rbx photoresistor 3dview

Align the photoresistor in the hole (photo-sensor side up) on the top half and arrange the wires in the grooves. Secure with a small amount of hot glue.

rbx photoresistor assembly 01

Mount the top piece with 4 x M2 screws.

rbx photoresistor assembly 02

Line up two 2x1 brickbases on a faceplate, two rows apart. Surround the brickbases with a few other bricks to assist in alignment.

rbx photoresistor assembly 03

Add two drops of super glue on each brickbase and mount the module. Press and hold for 60s.

rbx photoresistor assembly 04

The finished module:

rbx photoresistor assembled