RobotSentry – Home Security System – Part 2


Following on from RobotSentry – Home Security System – Part 1 this is the second post in my security system project. With the basics of the design finished I assembled a set of components. Many of them I was able to salvage from previous projects.

Here is a list of all the items I used :

Raspberry Pi 2 Model BRaspberry PiFarnellModel B+
DC-DC Step-down regulatorVoltage regulatoreBay12V to 5V (variable)
2 Channel Relay Module2 Channel Relay moduleAmazon2-channel module
Silver IR Illuminator 12 Infrared IlluminatorsAmazon12V, 48 LED
Pi NoIR Camera ModulePiNoIR CameraCPCInfrared Camera
BH1750 Light Sensor ModuleBH1750 I2CeBayI2C Light sensor
BMP180 Pressure Temperature ModuleBMP180eBayI2C Temp pressure sensor
PIR Module #1PIR moduleAmazon
Junction BoxEnclosure 175x151x95mmCPCPlastic IP65
Junction Box with Transparent CoverEnclosure 80x172x53mmCPCHylec, Plastic IP67
 12V DC Power Supply12V Power supplyCPC3.5A
20m Cat5e network cableCPC
Pi camera 50cm cableeBay

To connect it together I also needed these bits :

2330 ohm resistorsCPC
32.1mm DC barrel socketsCPCFor illuminators
22.1mm DC extension cablesCPCFor illuminators
1m40 way ribbon cableeBay
42×20 IDC connectorseBay
2002.54mm male pin headerseBay
192.54mm female pin headerseBay
22.5mm nylon boltseBay
122.5 nylon round pillarseBay
44mm nylon hex pillarseBay

I used a variety of suppliers but the components (or alternatives) are available from various other sellers.

Here is a photo of the external box with a ruler included for scale :

RobotSentry External Sensor Box

You can see (from left to right) the light sensor, pressure sensor, LEDs, PIR and camera module. This box has a clear plastic lid. This week I carried out a few tests with the PIR sensor. I had planned to mount it inside the and let it look through the transparent cover. However I found it just didn’t work behind the plastic. So this week I will cut a hole in the transparent enclosure cover and mount the sensor. The join can be sealed with silicon sealant. The camera module will be stuck to the cover and remain protected inside the box.

Here is a photo of the internal box :

RobotSentry Internal Box

The black pin headers on the strip board are for the ribbon cable that connects to the sensor box. The barrel connectors in the top left and right will be connected to the relay module to provide power to the infra-red illuminators.

Here is a close up of the 12V to 5V regulator and 2-channel relay module which are mounted on the side :

RobotSentry Internal Box

Coming soon

The next posts in this series will be :

  • RobotSentry – Home Security System – Part 3 – Hardware Testing
  • RobotSentry – Home Security System – Part 4 – Installation Outside
  • RobotSentry – Home Security System – Part 5 – Working System!


  1. Hi Matt. Great series so far. I also coincidentally am working on a very similar system (RPI2, LED IR array, Noir Camera, PIR sensor, 2 channel relay, all powered via 12V DC to IR LEDS, and UBEC stepped down to 5V DC for the RPI). My design is intended to separate the camera, PIR sensor and IR LEDS into an outdoor (driveway) housing connected an indoor (garage) RPI control unit via a HDMI/Camera extension cable. The hardware setup for my outdoor camera housing needs some kind of adjustable mount for the camera, but I’m working on it. I’ve tested the system all wired up and it appears to work discretely. I’m now trying to work out the software design for a PIR triggered monitoring solution. Do you have any recommendations on the best approach to handling image/video capture? e.g. a single Python application which loops waiting for PIR, flipping the IR LED relay, capturing an image, repeat. Or has your previous project experience pushed you in a different direction? Thanks and I’m looking forward to your future instalments.

    • Just a quick follow up with my build. I found with 12V DC @ 2 Amps simply didn’t provide enough juice for just 1 of those 12 V DC IR LED arrays + the RPI. I switched to a 3 Amp power supply and its better, but not ideal. With your 3.5 Amp power supply, it would probably drive just 1 of your IR LED lights brighter than 2 units. The problem is those IR LED arrays need like 12V DC @ 2 Amps to themselves to perform reasonably unless you’re in a smallish room. With the RPI + accessories, I think you’ll find the IR lighting to be unsatisfactory.

      I’m about to pull the trigger on ordering a 5 Amp power supply myself. Even if its over kill, the power supply will run cooler when everything is drawing simultaneously.

      • Thanks for the info. My plan was to get the system working without the IR lamps, check the relays switched ok and then introduce the lamps as required. So I might just need to keep an eye on the power consumption. I’ve got a conventional security light as well in the same area so I won’t know if I even need two IR lamps. Luckily I can always upgrade the power supply if I need to.

    • It’s still on my list but I’ve got so many other things getting in the way I’m struggling to make progress with it.

    • Still interested and I believe I’m not the only one. Have you encountered any problems or is it just the lack of a free time? Hope you’re doing well. 🙂

Leave A Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.