Hawkeye Camera turns a Raspberry Pi 5 or 4 into a self-hosted camera system: a live MJPEG stream, on-demand snapshots and recordings, an always-on rolling video buffer, and automatic Google Drive backup. Everything runs as a systemd user service - no cloud subscription, no third-party app required to view the feed.
Features:
- Live stream viewable from any browser on your network, with pan/zoom/focus/rotate controls
- Full-resolution stills on demand, independent of the live-view resolution
- On-demand manual recordings (4K) alongside an always-on rolling buffer (720p) for after-the-fact review
- Automatic background upload of snapshots/recordings/continuous footage to Google Drive - fully optional, pausable/resumable from the UI, with backed-up files browsable and deletable from the app
- Live weather overlay on the video feed
- Optional live audio from a USB microphone, auto-detected and streamed alongside the video feed
- Runs unattended as a systemd user service with lingering enabled - survives reboot and logout with no login required
- Optional HTTP Basic Auth on the stream and web UI - open on your LAN by default, lockable with a username/password
Optional integrations:
- Google Drive backup (OAuth device-flow authorization, resumable uploads)
- Weather overlay for your location
- HTTP Basic Auth login (see Authentication in SETUP.md)
- Private remote access via Tailscale - reach the camera from outside your LAN with no port-forwarding
See SETUP.md for full configuration details on each, or docs/architecture.md for a full system diagram.
- Raspberry Pi 5 or 4 (Model B, 4GB+ RAM)
- Pi 5 has no hardware H.264 encoder - 4K recording is software-encoded and CPU-heavier than Pi 4
- Also runs on a Raspberry Pi Zero 2 W (64-bit-capable, unlike the older non-"2" Zero/Zero W) with a reduced-resolution config - see Low-Power Boards in SETUP.md
- Official power supply (Pi 5: 27W USB-C PD; Pi 4: 5V/3A USB-C)
- MicroSD card, 32GB+ (A2/U3 rated), or a USB SSD/NVMe boot drive
- A CSI camera module
- Built and tested against an Arducam 64MP Hawkeye (autofocus)
- Should also work unmodified with the Raspberry Pi Camera Module 3 (confirmed by code inspection, not yet on physical hardware) - the app reads resolution/AF range/crop limits from the sensor at runtime. See Camera Compatibility in SETUP.md for the one required config change and what differs (autofocus support, max-zoom quality) across camera modules
- CSI ribbon cable matching your Pi's connector (Pi 5's connector differs from Pi 4's) - see Connecting the camera in SETUP.md for exact cable types and a connection diagram
- Active cooling (strongly recommended, especially on Pi 5 - expect 55-65°C+ under continuous recording load)
- A case with an unobstructed camera mount
See SETUP.md for the full hardware rationale and a step-by-step build guide, or docs/hardware-reference.md for a broader Raspberry Pi port/cable/camera reference beyond just this app's specific supported hardware.
To install Hawkeye Camera, follow these steps:
- Clone the repository:
git clone https://github.com/Rajesh6174/RaspberryPi5HawkeyeCameraApp.git ~/.local/share/camera-stream - Navigate to the project directory:
cd ~/.local/share/camera-stream
- Run the installation script:
./install.sh
The script installs all required apt packages (python3-picamera2, libcamera,
ffmpeg, etc.), enables the camera interface, creates the data directories,
sets up ~/.config/camera-stream/ from the provided templates, and installs +
starts the systemd service.
After installation, if you're using the Arducam 64MP the script prints one
extra command to add its device-tree overlay - run it, then reboot. Once
rebooted, the live stream is available at http://<pi-ip>:8000/.
For the full walkthrough - including OS flashing, camera verification, and filling in the optional config files (Google Drive backup, weather location, low-power boards, login auth) - see SETUP.md.
To update Hawkeye Camera with the latest code changes:
- Navigate to the project directory:
cd ~/.local/share/camera-stream
- Fetch the latest changes:
git pull
- Restart the service:
systemctl --user restart camera-stream.service
If the update added new dependencies or a new optional config file (as several past
updates have), re-run ./install.sh instead of step 3 - it's idempotent and safe
to run anytime: it only installs missing packages and only creates config files
that don't already exist, never overwriting what you've already set up.
systemctl --user disable --now camera-stream.service
rm ~/.config/systemd/user/camera-stream.service
systemctl --user daemon-reload
rm -rf ~/.local/share/camera-stream ~/.config/camera-streamIf the SD card dies, a fresh Pi can be back up in minutes rather than starting from scratch - see the Disaster Recovery section of SETUP.md.
Distributed under the MIT License, see LICENSE for more information.
Check SETUP.md for setup/hardware troubleshooting, including a
Known Issues and Resolution section
for specific problems (browser auth quirks, a HEAD-request quirk, etc.) with
their exact fixes. For anything else, open an issue on the
GitHub Issues page.
Built on top of these projects:
- picamera2 - the camera library this app is built around
- libcamera - the underlying camera stack on Raspberry Pi OS
- rpicam-apps - reference camera applications used for testing/calibration
