Home » Grade » LDR sensor for arduino with Lego-compatible support

Login with your Social Account

LDR sensor for arduino with Lego-compatible support


Design of a compatible a LDR sensor with a compatible Lego support for connecting to arduino.

The light sensors are actually photoresistors (LDR) that let you capture the variation of light in the environment. It is designed to support Vishay’s photoresistors as shown below:

ldr_legoYou can find them here the source code of the file OpenScan and the STL files to print it with a 3D printer:

3D printing:

Download the STL file and print it.

(Suggested) printing parameters:

Height of layer (mm): 0.3

Wall thickness (mm): 0.8

Upper and bottom part thickness (mm): 4.2 (very important, to avoid breaking of the top cylinders)

Filling: 15%

printing speed (mm/s) : 30

No support

No sticky material applied to the bed


All necessary components are:

  • A LDR Vishay resistor.
  • A fixed 10 k resistor.
  • Cable.
  • 3 pin connector 2.54 mm pitch.

Assembly is simple, since the LDR acts as a variable resistor connected with another fixed resistance which provides a voltage divider whose voltage varies upon amount of light received on the LDR resistor:


All the components needed to build a sensor are shown here:


We have soldered the LDR fixed resistance and make accessible the union between both resistances with a cable:


The complete sensor is as follows:


Cover it and closed so that only the 3-pin connector is accessible and the LDR sensor is able to measure:


%d bloggers like this: