top of page

Safari browser sometimes has issues displaying images...

I.e: *you have to click on the images to see them...

For a better browsing experience on Brainy-Bits

Please use Chrome, Edge or Firefox browser.

  • Writer's pictureBrainy-Bits

Build a simple RC Plane/Drone finder using a DigiSpark


If you ever flown an RC Plane or Drone, you know that it’s easy to lose control and no matter how good you are, crashing is something that will eventually happen.

But what do you do if the site of the crash is located inside a corn field or in a forest?

You might be walking right beside it while searching, and not even see it!

Here a little project that will sound an Alarm after a set time and will help you locate your lost RC vehicle.

In this tutorial we will “not” use some sort of “crash detector” or GPS, instead we will take into account that most RC planes or drones have a maximum flight time due to the battery they use.

Most of them can fly for around 20 minutes before the battery runs out (some more,some less…)  so in theory, if we set the timer above that duration (30 minutes for example), then if that timer elapse and the alarm is sounded,  we can assume that our RC plane or drone has not returned to us and is crashed somewhere.

So at least the sound of the Alarm will guide you in the right direction so you can retrieve your lost RC plane/drone.

We will be using the DigiSpark, since it’s very small and we don’t need a lot of pins.

Everything can be powered using a regular 9V battery.



4 Digits 7 Segment Display


Passive Buzzer Module

These are Amazon affiliate links...

They don't cost you anything and it helps me keep the lights on

if you buy something on Amazon. Thank you!



AHere are the connection needed for this tutorial:

The GND and 5V (out) of the DigiSpark is connected to the breadboard power rails.

The GND of the Buzzer is connected to the GND rail of the breadboard.

The positive (+) of the buzzer is connected to pin 2 of the Digispark.

The VCC and GND of the 4 Digit Display are connected to the breadbard power rails.

The CLK and DIO pins of the 4 Digit Display are connected to pin 0 and 1 of the DigiSpark.

The positive (+) of the 9V battery is connected to the VIN pin of the DigiSpark.

The GND (-) of the 9V battery is connected to the GND rail of the breadboard.



We are using a 4 bit 7 segment display to create a countdown timer, of course this is optional if you just want to sound the Alarm and not have a display.

But using the display confirms that it is working and we can visualize the entered value of the timer.

We are using the “DigitalTube” library created by Frankie Chu (

to control the 7 segment display.

Don’t forget to watch our Tutorial video for more information.

#include "TM1637.h"  //  Library for 7 segment Display
//0~9,A,b,C,d,E,F  // Available for display
// DigitalTube Library
// created by Frankie Chu:

// Pins for display
#define CLK 0     
#define DIO 1

#define Buzzer 2 // Pin 2 connected to buzzer + positive

int timer_val=1;  // Countdown value in minutes
int timer_seconds=30;  // used to display seconds

//  Variables used to store individual numbers
int  firstnum=0;
int  secondnum=0;
int  thirdnum=0;
int  fournum=0;

TM1637 tm1637(CLK,DIO);  //  Create instance of 7 segment Display
void setup(){
  pinMode(Buzzer, OUTPUT);
  digitalWrite(Buzzer, LOW);
  tm1637.init();  // Reset Display 
  tm1637.point(POINT_ON);  // Put center "colons" ON
  delay(1500);  // Delay to let system boot 

void loop() {

// Check if timer is elapsed
  while (timer_val == 0 && timer_seconds == 0) {
    tm1637.clearDisplay();  // Clear display 
    digitalWrite(Buzzer, HIGH);
    digitalWrite(Buzzer, LOW);

// Breakdown minutes and seconds in individual numbers
  if (timer_val > 9) {
    firstnum = timer_val/10%10;
    secondnum = timer_val%10;
  else {
    secondnum = timer_val;

  if (timer_seconds > 9) {
    thirdnum = timer_seconds/10%10;
    fournum = timer_seconds%10;
  else {
    thirdnum = 0;
    fournum = timer_seconds;

// Display timer on 4 bits 7 segments display
  tm1637.clearDisplay();  // Clear display
  if (timer_val > 9) {

  if (timer_val > 0) {

  if (timer_seconds > 9 || timer_val > 0) {

// Decrease seconds
  delay(1000);  // Delay of 1 second

// Decrease timer
  if (timer_seconds == -1) {





Copy the above Sketch code in your Arduino IDE software to program your Arduino.

Used Libraries:

Download The DigitalTube Library

Once downloaded, just extract the content of the zip files inside your “arduino/libraries” folder, and make sure to restart the Arduino IDE (Close and Reopen) software so it detect this newly installed library.

484 views0 comments


All my content is and will always be Free.

If you feel that my Videos / Tutorials are helping, and you would like to contribute...

 You can toss some coins in the Tip Jar via PayPal.

Select amount then click the “Donate” button.

bottom of page