Building a Webcam on a Raspberry Pi - Intro

Mon, Jun 26, 2023 3-minute read

A couple of years ago, peering lustfully out the back door of the 4th floor Cortex offices, I spotted an unusual sight - a plug on a roof top:

webcam 1

What could that be for? I wondered.

More precisely… what could that be used for? I immediately started thinking. Well, given the glorious view behind said roof top, it seemed pretty obvious that we could stick a webcam up there.

Something connected via wifi to our office network should do the trick. Since we are on a metered internet connection, I didn’t want to put something up that would completely flatten our internet connection, especially if a few people started using it, so I figured something that would periodically take an image and upload it to our storage CDN on Azure would be fine.

Heck, we could then surface it on Seeker. And call it SeekerCam.

So the idea was born and whilst there are many ‘outdoor webcams in a box’ it definitely seemed like a very flimsy excuse to play with a Raspberry Pi again.

I spent some time researching weatherproof boxes (safety first, obvs), ordered the genuine PiCamera module and after a bit of tinkering, jiggery-pokery and fernagling - SeekerCam was built:

a raspberry pi and a camera in a weatherproof box

I wrote some code, and then gaily lashed it up on the roof, plugged it in 1 and pointed it at the horizon. Amazing. It worked quite well. Seeker was updated every 10 mins or so with a new image. Nice.

We even managed to make a cool timelapse!

All was good until one day it just… stopped… the image on Seeker wasn’t updating. It had stopped… working?

Well, not so much stopped working, but disappeared. I mean literally disappeared… as in the whole thing wasn’t even on the roof anymore!

Assuming it must have disappeared in the wind somehow, we chalked it up to an “oops” and just moved on.

Until a few days later, there was some banging around outside our back door - there were people out there… on the roof. Enquiring quite what (the hell) they thought they were (bloody well) doing, it turns out they were inspecting the office below whose roof’s electrically controlled skylight window had, mysteriously… stopped working.

They told us they’d been up over the weekend to have an initial inspection and had had to remove some weird contraption2 and plug the skylight back in.

Ah. Ok.

Mystery somewhat solved, I went tail between my legs to the office next door to do the classic “Please sir, can we have our webcam back?”

We had a good ol’ joke about it, they even said they had no problem with it, other than they did want their skylight to work. OK - we agreed, but after that it never got attached again.

More recently, a network of local webcams has gone out of service, so we had a few requests to reinstate our webcam, and, given that we’d invested a fair bit of time (and money) in to the original device, it seemed like a reasonable idea to get it going again. So that’s what I did; and thought that this time it would be worth documenting it.

So that’s what this is.


  1. For the record, at the time of said plugging in, the plug wasn’t actually in the socket, so I didn’t unplug anything… honest. ↩︎

  2. Just plugging the skylight back in didn’t fix it… something else was buggered, which likely explains why it had been unplugged in the first place. ↩︎

Posts in this Series