Arduino VCLED Flasher – Another Fun Project for STEM Kids

As promised, here is another fun electronics project for our STEM kids. This time the theme is the setup of an Arduino VCLED Flasher. So, get ready to see a simple voltage controlled lamp flasher that can be made in a couple of minutes using an Arduino Uno or Nano microcontroller development board.

VCLED Flasher

Only trivial but first off note that I used the Seeeduino Nano board together with its expansion shield because it was within my easy reach while I was doing the experiment.

Now let us have a look at the Arduino Sketch prepared to blink its onboard LED (D13) faster or slower depending on the knob setting of the potentiometer connected to an analog input (A0) of the Arduino Uno/Nano.

int VINpin = A0;
int LEDpin = 13;
int x = -1;
void setup() {
  pinMode(LEDpin, OUTPUT);
}
void loop() {
  x = analogRead(VINpin);
  digitalWrite(LEDpin, HIGH);
  delay(x / 1);
  digitalWrite(LEDpin, LOW);
  delay(x / 1);
}

And, this is the hardware setup diagram:

Arduino Uno VCLED Flasher Schematic

The only additional part required for this setup is a 20KΩ potentiometer (or trimpot) to change the voltage on the A0 pin from 0 to 5V and vice versa. You can also supply clean 0 to 5VDC directly to the A0 pin (after removing the pot) but then two more silly parts are needed for system protection – a 220Ω/¼W resistor and a 5.1V/500mW zener diode!

VCLED Flasher Live

The Arduino VCLED flasher setup can be powered by USB or 6F22 9V battery. Both are okay for the Arduino Uno, but I feel that USB power would be more convenient for STEM kids using the Arduino Nano or Seeeduino Nano boards.

What is more, with a little skill and patience, you can even drive mighty loads like a torch bulb or a toy motor with this setup, but you will need to run it through a 5VDC relay module. Be prepared, the delay function in the Arduino Sketch may need a few more tweaks as well.

A quick snap of my breadboard relay assembly is shown below. After that you will also see its tried and tested circuit diagram.

That is all for now.

VCLED Flasher

Leave a Reply

Your email address will not be published. Required fields are marked *