L.O.A.S.H’s guide to (nearly) Everything: How to make an Intruder Alarm with Arduino


Before we begin, you will have to download the Arduino on your computer if you haven’t already. In order to program your Arduino to work, you will need the Arduino program installed. I downloaded mine at https://www.arduino.cc/en/main/software.

It’s time to learn how to make your own Intruder Alarm with your Arduino!!! If you don’t have an Arduino I just have to tell you that it will be a great investment.

All you will be needing are the following:

  • Arduino Board
  • Jumper Wires (13x)
  • Bread Board
  • 10k Ohm Resisters
  • LEDs (recommended different colors!!! :D)
  • Buzzer or Piezo
  • Ultrasonic Sensor (HC-SRO4)

You could check the cartoonish photo that I’ve screenshotted from Instructables for reference down below………

Screen Shot 2017-02-26 at 18.18.29.png

On the top right, you will see this medium sized piece of machine that kind of look like speakers. Heh, they’re like baby speakers, how cute ^___^.


Step 1:

After gathering all your materials, take two of your jumper wires, which are preferably black and red. Connect one of the sides of the red jumper wire (remember, the jumper wire will do the same thing even if the jumper wire is a different color) to the 5v(olts) in your Arduino board and the other side of the jumper wire to Positive lane on the breadboard. Now, get your black wire and connect one end to the GND (ground) and the other end to one of the holes in the negative lane of the breadboard. This will be a very simple step as the GND and 5v are right next to each other. If you look at the top photo above, you will see which will be the proper places to put your positive and negative wires.wp-1488164286136.jpg


Step 2:

Let’s just do the simple steps, first, and I want you to start placing your LEDs in a row. In case you are a n00b (newbie or beginner) in all these wires and blah, LEDs stands for a light emitting diode. If you don’t want to know more about the cool components that LED holds and the important things you should know then skip to the next paragraph. Anyways, a LED or a light emitting diode is pretty much a miniature bulb encased by an epoxy case connected to two metal wires called the cathode and the anode. Once you get deeper and deeper into Arduino, it is of great importance to know the difference between cathode and anode. Let’s learn a little something. If you look at your LED, you might notice that one of the legs are longer than the other (weird?), well, the longer leg is the anode (+) and the shorter leg, you might have guessed, is the cathode (-). When you are placing your LED, the longer leg (or the anode) should be connected to to the jumper wire and the shorter leg (aka the cathode) should be connected to the resistor. If you don’t understand it completely, you will in due time.


You should get around 6 light bulbs and place them in a row. Look at the top photo for reference. You will not need to have that super long breadboard to complete this project by the way. As long as you connect all the wires to where they are supposed to be, like the wire to the anode and the resistor to the cathode then things should turn out fine.

Cause what you need to understand is how things are connected to the breadboard. Once you get the concept, then everything will be much simpler.

The right leg here is the longer side.

Step 3:

This step will be a bit tedious but will be worth the work later. So for your reference, you can check this photo and the other following pictures:Screen Shot 2017-02-26 at 19.47.49.pngPlease understand that as long as the jumper wire is on the same row that the legs of the bulbs are on, then they are connected. What you will need to do is connect your jumper wires and your resistors. Check the photo above for reference because I’m a n00b at explaining. To get more specific, we should do the following positions:

To get more specific, we should do the following positions:

What you will need to do is try to follow the photo above by the positioning.

(This will be from LED right to left. Meaning when you see the word LED 1,  this is the LED at the very right, just like in the photo.)

Screen Shot 2017-02-27 at 13.07.04.png

You will have to connect one of the ends of the jumper wire (any color) to the front of the anode or longer side of the legs of the LED and the other end to the Arduino. Down below I will be giving you guys which LED will you be connecting to which pin on the Arduino with the jumper wires. Just please refer to the photos if you don’t understand a word I’m saying because I really want you guys to make one of these!!! You will also have to be aware that the anode of the LED should be on the right side.

Screen Shot 2017-02-26 at 19.47.49.png

These are for the jumper wires…..

LED 1 —> pin 8 (these pins are on the Arduino Board)

LED 2 —> pin 9

LED 3 —> pin 10

LED 4 —> pin 11

LED 5 —> pin 12

LED 6 —> pin 13


Now, for the resistors, you will also notice that this has two legs. If your resistor has one leg then there’s something wrong. So, take one of the legs of your resistor and place it in the same row of the LEDs cathode then put the remaining leg into the negative lane of the breadboard. Do this step for each of the LEDs until you’ve completed it. Make sure the reddish part of the resistor is facing the LEDs…..

See, the red part of the resistor is facing the LED. NOTICE: The jumper wires are on the anodes (longer side) while the resistors are on the cathodes (shorter side)

This step might be a bit messy….. just a warning.

Step 4:

Unfortunately, with the rush of excitement to show you guys something new and because of the excitement to achieve something new, I’ve forgotten to put in my Piezo or the buzzer.

If you want to add in your buzzer, you should make sure that you connect the longer leg (just like for the LED, the same way) of the buzzer to pin 3 on the Arduino with a jumper wire. And, connect the shorter leg of the buzzer to GND. To put connect the shorter leg of the buzzer to the GND, just make it on the same lane as the negative lane on the breadboard. After all, we did connect that to the GND at the start.

Step 5:

Place your Ultrasonic Sensor on the top right. For this step, you will have to grab 4 jumper wires. If you look closely at the Sensor, you will notice that it has 4 words: GND, ECHO, VCC, TRIG. For each word, connect a jumper wire.



GND (on the sensor) —> GND (on the negative lane of the breadboard (A.K.A ground, too!)

Echo (on the sensor) —> pin 6 (on the Arduino board)

Trig (on the sensor) —> pin 7 (on the Arduino board)

Vcc (on the sensor) —> To the positive lane of the breadboard (A.K.A 5V(olts))

Your outcome should look somewhat like this:


Don’t mind the messy background. If you look closely at the contraption that I’ve made, you will notice how and where I have placed my jumper wires for the sensor.


Step 6:

Screen Shot 2017-02-27 at 14.17.53.png


Finally, just plug in your Arduino device and run your code to program it. If you get this annoying error message from Arduino saying: ” Avrdude: no programmer has been specified on the command line or the config file         Specify a programmer using the -c option and try again”. Then, all you have to do is, go to tools, then in tools go to boards and in boards click on boards manager.


Tools < Boards < Boards Manager.

When you open you board manager, update your Arduino Avr Board.

Yours truly,


One thought on “L.O.A.S.H’s guide to (nearly) Everything: How to make an Intruder Alarm with Arduino

Comments are closed.