hkcam

Open-Source HomeKit Camera

Attach a camera to a Raspberry Pi and run hkcam to make your own surveillance camera. Communication is encrypted and data is stored only on the Raspberry Pi. You can be sure that nobody has access to your video stream.

What you need is computer and a camera. A Raspberry Pi and the ELP 1080P USB camera are a perfect fit.

A Raspberry Pi is small and more than capable of running hkcam. You can even use a Raspberry Pi Zero, which is a tiny, tiny $15 computer.
See All Raspberry Pi Products →

The ELP 1080P USB camera provides 1920 × 1080 video at 30 fps. The enclosure is IP66 waterproof and the built-in IR LEDs provide good vision at night.
aliexpress.com →

A cheaper alternative is a camera module attached via ribbon cable. Keep in mind that this require the Legacy Camera Support on Raspberry Pi OS. This doesn't get you the best performance.

And then you need to install hkcam, which is responsible for taking the video stream and make it accessible to HomeKit.

View Source Code

HomeKit App

You can access the camera and view the live stream directly from your iPhone, iPad, Mac and Apple Watch. You only need a compatible HomeKit app. Apple's Home app works just fine.

Home+

Home+ is a powerful HomeKit app for iOS and watchOS. You can control and automate any HomeKit-compatible accessory with it. Home+ is also the only app (at this point), which unlocks the Persistent Snapshots features of hkcam.

Persistent Snapshots

Persistent Snapshots is a unique feature in hkcam, which lets you take snapshots and store them on the camera persistently. This feature is implemented via custom HomeKit characteristics, which means that it can be used in combination with other HomeKit accessories in automations.

For example you can set up an automation to take a snapshot when motion is detected in the living room. This is a very essential feature if you want to use hkcam as a security camera.

To learn more about Persistent Snapshots, check out the documentation on Github.

© Matthias Hochgatterer – MastodonGithubRésumé