This circuit, police strobe light effect using Arduino is something I just come up with, out of boredom. I mean, actually I saw a similar effect in a group and when I asked the poster for the schematic it happens that his original circuit is using 547/557 ICs. So due to the lock-down because of COVID-19, I can’t go out to buy the ICs so I decided to do it with an Arduino since I have one laying around. That is the joy of Micro-controllers, you can actually use them for almost anything. Anyway, maybe not anything. The circuit flickers flicker 3 sets of LEDs, 4 seconds each t create the illusion of most police car strobe light.
Long story short, lets delve into the schematic diagram.
Components List
B1 – Arduino UNO R3 or similar x1 | Buy here |
T1, T2 and T3 – BC54, 2N3904 or equivalent NPN transistor x3 | Buy here |
R1, R2 and R3 – 220 Ohms Fixed value Resistor x 3 | Buy here |
D1 – D4 –5mm White LEDs – x4 | Buy here |
D5 – D8 –5mm Red LEDs – x4 | Buy here |
D9 – D12 –5mm Blue LEDs – x4 | Buy here |
Circuit explanation
As you can see from the schematic, the circuit is very simple. The digital pin 2, 3 and 4 of the Arduino is used for out and to drive the three channels of the LEDs. An NPN transistor is used to amplify the current through the Arduino pins via a current limiting resistors. Each set of the LEDs, D1 – D4 (White LEDs), D5 – D8 (Red LEDs) and D9 – D12 (Blue LEDs) are connected in parallel. Anodes of the LEDs are all connected together and tied to the 5v pin of the Arduino. The corresponding cathodes of the LED parallel networks are connected to their respective driving transistors, T1 through T3. The Emitter of the transistors are connected together and tired to the GND pin of the Arduino.
The Arduino sketch
// Police strobe light effect using arduino
// Copyright (C)2020 Izuchukwu Obiako, For: Do It Yourself Nigeria, All right reserved
// Website: http://www.doityourself,ng/
int blinkTime = 4;
int blinkDelay = 100;
int whiteLED = 2;
int redLED = 3;
int blueLED = 4;
void setup() {
pinMode(whiteLED, OUTPUT);
pinMode(redLED, OUTPUT);
pinMode(blueLED, OUTPUT);
}
void loop() {
blinkLED(blinkTime,blinkDelay, whiteLED);
digitalWrite(redLED, LOW);
digitalWrite(blueLED, LOW);
delay(300);
blinkLED(blinkTime,blinkDelay, redLED);
digitalWrite(whiteLED, LOW);
digitalWrite(blueLED, LOW);
delay(300);
blinkLED(blinkTime,blinkDelay, blueLED);
digitalWrite(whiteLED, LOW);
digitalWrite(redLED, LOW);
delay(300);
}
void blinkLED(int repeats, int time, int ledPin){
for (int i = 0; i < repeats; i++){
digitalWrite(ledPin, HIGH);
delay(time);
digitalWrite(ledPin, LOW);
delay(time);
}
}
Application of the police strobe light
The police strobe light as you would have imagined can find use on police cars. I don’t know if there’s any other reason for that if not for getting attention. Anyway, despite that I called it police strobe light it can as well be used on ambulances, toys or just anywhere you need to drive people’s attention.
You can share the tutorial with your friends using the social media buttons and if you have built the circuit or have any question, tell us in the comment box below. Thanks for reading.