How to Build a Satellite-Powered, Raspberry Pi Security Camera for Off-the-Grid Locations
Keep an eye on your property, even if it’s way off of the grid.
A friend of mine recently had a break in at his cabin up north. He wanted to know if I had any recommendations on technology that could let him keep an eye on things from far away. The only challenge is his cabin is relatively remote, and cell service or internet isn’t available in the area. With that in mind, I wanted to design a solution that would keep an eye on things using a Raspberry Pi, a bit of edge computing, and a satellite connection.
For this project I’m using the Swarm satellite constellation; it’s a low cost solution for providing satellite connectivity for internet-of-things devices in remote locations. Where one solution would be to livestream images from a camera using a high-bandwidth connection for off-site processing, this project does on-site processing (edge computing) instead sending only the results, letting us keep this project running for a long time at the low cost of $5 a month. Here’s how to build a remote cabin monitoring and alerting system with a Raspberry Pi, a camera, and the Swarm Eval Kit.
What You’ll Need For This Project
- Raspberry Pi 4 or Raspberry Pi 3 with power adapter
- 8 GB (or larger) microSD card
- Raspberry Pi Camera
- Swarm Eval Kit & Data Plan
- An internet connection for the initial setup
How To Build A Remote Cabin Monitoring System with a Raspberry Pi
Before you get started, get your Raspberry Pi set up. If you haven’t done this before, see our article on how to set up a Raspberry Pi for the first time or how to do a headless Raspberry Pi install (without the keyboard and screen). For this project, we recommend a headless Raspberry Pi install.
1. Install git. We’ll need it to download the code from GitHub.
sudo apt-get update
sudo apt-get -y install git
2. Clone the repository to your home directory. This will download all the necessary source code for person detection and communicating with the Swarm tile.
cd ~/
git clone https://github.com/rydercalmdown/remote_cabin_monitor.git
3. Run the “make install” command to install all project dependencies. This script will take care of installing lower level dependencies, as well as the Python libraries you need for the project to run. The machine learning library we’re using to detect people is packaged within one of the Python libraries, so it may take a few minutes to install.
cd ~/remote_cabin_monitor/
make install
4. Connect your Raspberry Pi Camera to the Raspberry Pi and mount it in the desired location.
Stay On the Cutting Edge: Get the Tom's Hardware Newsletter
Get Tom's Hardware's best news and in-depth reviews, straight to your inbox.
5. Test your Raspberry Pi Camera by taking a snapshot with the following command.
raspistill -o test.jpeg
6. Assemble and register your Swarm Eval Kit using the instructions in the quickstart guide. This will get it connected to the network for transmitting data.
7. Turn on your Swarm Eval Kit system with the button on the side.
8. Set your Raspberry Pi Wi-Fi to the Swarm Evaluation Kit SSID. This will need to be done directly on the pi with an external monitor and keyboard. Any SSH connections to the pi will be dropped when the pi switches to the Swarm SSID.
The easiest way to do this is by using raspi-config (sudo raspi-config), navigating to System Options->WIreless LAN and then entering the Swarm Eval Kit’s SSID (you’ll have to find this on another device where it will be swarm-xxxx) and entering a default password of 12345678.
9. Run the application to test it. If the Raspberry Pi is connected to the Swarm Kit successfully, it will send a startup email over the network. Depending on your satellite availability it can take some time to arrive in your inbox; use this pass checker to determine when a satellite will be overhead.
cd ~/remote_cabin_monitor
make run
10. Configure the application to run on boot by adding a line to the /etc/rc.local file.
sudo nano /etc/rc.local
# Add the following line before the last line
. /home/pi/remote_cabin_monitor/env/bin/activate && export EMAIL_FROM=youremail@example.com && export EMAIL_TO=youremail@example.com && /home/pi/remote_cabin_monitor/env/bin/python /home/pi/remote_cabin_monitor/src/app.py &
11. Place the Swarm Eval Kit in view of the sky, and mount the Raspberry Pi and camera in your desired location.
When running, the Raspberry Pi will continuously pull images from the camera and check them for the presence of a person. If a person is detected, the Pi will send a message to the Swarm Eval Kit, which will then communicate with a constellation of satellites via VHF. The satellites will relay the message to a downlink, and you’ll then receive an email indicating a person has been detected. The Pi will also send an email every 24 hours that no people have been detected in order to let you know it’s still working.
This type of system can also be modified to send more than just person-detection data. Leak detection, fire detection, and any kind of sensor that can communicate with a Raspberry Pi are all possible to send over the network.
Ryder Damer is a Freelance Writer for Tom's Hardware US covering Raspberry Pi projects and tutorials.
-
Bubuache Over 500$ just to build something that sends an email that a person was detected. What do you do if you get the email? Go there and check? Call the police? You don't even now if the alert is true without seeing an image. How long is going to take until somebody is stealing the outside equipment?Reply
I do not think this solution is worth that kind of money. -
bkw777 It's a proof of concept example. If you literally stick everything on a tripod out in the front yard, sure it would be stolen. Before that it would also just fall over in the first rain storm or the first time an animal walks by. But no one would take a proof of concept example and literally do exactly that, would they? Because that would be STUPID, obviously, right?Reply
You would mount the swarm kit on the roof, the pi indoors anywhere, the camera anywhere, hidden in the usual kinds of corners and in an enclosure, or just buy a ready-made usb or wifi camera that already comes in an enclosure. You don't literally have to use the delicate, exposed, short ribbon-cable pi camera.
What you do with the knowledge provided by the email is whatever you want. Call a neighbor. Call the local police. Retrieve pictures/video/audio after the fact, automatically saved locally on the pi or on a usb stick that the neighbor or police can retrieve if you can't, to at least identify who it was. Of course you're not going to catch anyone while still in the act. You never were. But you will at the very least be able to call the local police within the hour, and that is a lot. Locations that are remote enough that you need a sattelite connection measured in hundreds of 192-byte packets per month, have very small local populations. Everyone knows everyone else, and every stranger stands out. A few reasonably clear pictures of the people, and/or their vehicle, even without a readable shot of the licence plate but you could probably get that too, will usually identify them with the local police. They will be known to all the locals. And even if they aren't known to the locals, even that is identifying by exclusion. Now they know it was that one stranger that was around that day, or the state police can spot the vehicle on the roads, in the wider area, etc.
This covers everything but Ninjas and ludicrous spy movies. You do not live in a ludicrous ninja spy movie. You live in a world where a couple of local lowlifes, probably just high-school kids, or one of the well known local drunks or idiots, drive their well-known vehicle right up to the door and rummage around in their normal clothes, and sell your stuff to a pawn shop maybe one or two towns away, who you just call up (there aren't 10000 of them in a reasonable driving distance circle, you just call them all, or the police do automatically) and describe your stuff and day of theft and maybe some serial numbers and probably not only get your stuff back but also catch the the guy who took it from the pawn shop records plus your own pictures. Even if you don't get your stuff back, at least you helped by providing data to the police which helps them catch the same people eventually after they do it a couple more times to other people. Even that is worth doing, because maybe you're the one you only provides data and the next guy benefits, or maybe someone else provided data and you're the one who benefits. -
scottsoapbox
Somebody needs to switch to decaf. (obviously, right?)bkw777 said:It's a proof of concept example. If you literally stick everything on a tripod out in the front yard, sure it would be stolen. Before that it would also just fall over in the first rain storm or the first time an animal walks by. But no one would take a proof of concept example and literally do exactly that, would they? Because that would be STUPID, obviously, right?
You would mount the swarm kit on the roof, the pi indoors anywhere, the camera anywhere, hidden in the usual kinds of corners and in an enclosure, or just buy a ready-made usb or wifi camera that already comes in an enclosure. You don't literally have to use the delicate, exposed, short ribbon-cable pi camera.
What you do with the knowledge provided by the email is whatever you want. Call a neighbor. Call the local police. Retrieve pictures/video/audio after the fact, automatically saved locally on the pi or on a usb stick that the neighbor or police can retrieve if you can't, to at least identify who it was. Of course you're not going to catch anyone while still in the act. You never were. But you will at the very least be able to call the local police within the hour, and that is a lot. Locations that are remote enough that you need a sattelite connection measured in hundreds of 192-byte packets per month, have very small local populations. Everyone knows everyone else, and every stranger stands out. A few reasonably clear pictures of the people, and/or their vehicle, even without a readable shot of the licence plate but you could probably get that too, will usually identify them with the local police. They will be known to all the locals. And even if they aren't known to the locals, even that is identifying by exclusion. Now they know it was that one stranger that was around that day, or the state police can spot the vehicle on the roads, in the wider area, etc.
This covers everything but Ninjas and ludicrous spy movies. You do not live in a ludicrous ninja spy movie. You live in a world where a couple of local lowlifes, probably just high-school kids, or one of the well known local drunks or idiots, drive their well-known vehicle right up to the door and rummage around in their normal clothes, and sell your stuff to a pawn shop maybe one or two towns away, who you just call up (there aren't 10000 of them in a reasonable driving distance circle, you just call them all, or the police do automatically) and describe your stuff and day of theft and maybe some serial numbers and probably not only get your stuff back but also catch the the guy who took it from the pawn shop records plus your own pictures. Even if you don't get your stuff back, at least you helped by providing data to the police which helps them catch the same people eventually after they do it a couple more times to other people. Even that is worth doing, because maybe you're the one you only provides data and the next guy benefits, or maybe someone else provided data and you're the one who benefits.
A single camera gathering both usable pictures and potentially a license plate while claiming that life isn't a movie is droll.
Your faith in the police catching someone from a picture shows a lack of dealing with the police after a theft. My clear HD video of the two thieves' faces stealing my motorcycle is still pending after 2 years (despite the obvious dedicated efforts of the police task force assigned to it).
Your $500 is far better spent on stronger doors and locks. -
pixelpusher220 scottsoapbox said:Somebody needs to switch to decaf. (obviously, right?)
A single camera gathering both usable pictures and potentially a license plate while claiming that life isn't a movie is droll.
Your faith in the police catching someone from a picture shows a lack of dealing with the police after a theft. My clear HD video of the two thieves' faces stealing my motorcycle is still pending after 2 years (despite the obvious dedicated efforts of the police task force assigned to it).
Your $500 is far better spent on stronger doors and locks.
This seems like a, ahem, stellar solution for specific needs. My family has a cottage 11 hours away, we aren't there that often, having something that would give us a heads up to call a neighbor to stop by would be great. It's a vacation cabin with lots of windows that's that waaaay off the beaten track. You don't end up there by accident.
I'm less interested in catching someone, than getting a busted door/window repaired so it isn't open to the elements for a month.