lmsousa
Published © GPL3+

Random Blink

An alternative to the basic and traditional blink code. With this sketch Built in LED will flash at random intervals instead of a fixed rate

BeginnerShowcase (no instructions)3
Random Blink

Things used in this project

Hardware components

Arduino Nano Every
Arduino Nano Every
×1

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Breadboard, 400 Pin
Breadboard, 400 Pin

Story

Read more

Schematics

Random Blink on Arduino nano

No external circuit needed. Its just a funcionality test using built In LED

Code

Random Blink code

Arduino
int randNumber;

void setup() {
  pinMode(LED_BUILTIN, OUTPUT);
}
void loop() {
  digitalWrite(LED_BUILTIN, !digitalRead(LED_BUILTIN));   // turn the LED on/off
  randNumber = random(25, 200);
  delay(randNumber);                       // wait 
}

Credits

lmsousa

lmsousa

5 projects • 16 followers

Comments