Fork me on GitHub

Project Notes

#010 LightOrNot

Reads a photocell/light-dependent resistor and adjusts the blink rate of an LED accordingly.

The Build

Notes

The LDR and 10k resistor act as a voltage divider. The sequence and resistor selection depends on the LDR.

I haven’t been able to find the specific datasheet for the LDR I am using yet, but it runs to over 10k when dark, and resistance reduces with more light. Note that some LDRs work the other way around (increase resistance with more light).

So in the circuit used here, the A0 reading measures the voltage drop across the 10k resistor, so this will approach 1023 in strong light, and approach 0 in darkness. So the faster the LED blinks, the “darker” the measurement.

I could swap the 10k resistor and the LDR to switch the readings scale: i.e. approach 1023 when dark, and approach 0 when light.

Construction

The Breadboard

The Schematic

The Build

Credits and References

About LEAP#10 SensorsArduino
Project Source on GitHub Project Gallery Return to the LEAP Catalog

This page is a web-friendly rendering of my project notes shared in the LEAP GitHub repository.

LEAP is just my personal collection of projects. Two main themes have emerged in recent years, sometimes combined:

  • electronics - usually involving an Arduino or other microprocessor in one way or another. Some are full-blown projects, while many are trivial breadboard experiments, intended to learn and explore something interesting
  • scale modelling - I caught the bug after deciding to build a Harrier during covid to demonstrate an electronic jet engine simulation. Let the fun begin..
To be honest, I haven't quite figured out if these two interests belong in the same GitHub repo or not. But for now - they are all here!

Projects are often inspired by things found wild on the net, or ideas from the many great electronics and scale modelling podcasts and YouTube channels. Feel free to borrow liberally, and if you spot any issues do let me know (or send a PR!). See the individual projects for credits where due.