Documentation
RTSP Extension
The RTSP extension adds support for capturing photos and videos over an RTSP stream from network cameras.
Overview
The rtsp extension allows you to take photos and record videos over an RTSP stream. It works with any network camera that supports RTSP streaming.
This extension does not require extension-level configuration and is focused on interfaces.
Camera Interface
Provides a camera to take photos or record videos from an RTSP stream.
| Option | Type | Required | Description |
|---|---|---|---|
path |
String | Yes | Full path where MudPi should save images. Ensure proper write permissions are set. |
source |
String | Yes | The full RTSP stream URL, e.g. rtsp://username:password@192.168.1.1/stream1 |
filename |
String | No | Name to save files as with a timestamp or counter attached |
record_video |
Boolean | No | Set to true to put the camera in video mode. Default: false (photo mode) |
delay |
Object | No | Interval between photo captures. Default: 5 seconds |
delay.hours |
Integer | No | Hours between captures. Default: 0 |
delay.minutes |
Integer | No | Minutes between captures. Default: 0 |
delay.seconds |
Integer | No | Seconds between captures. Default: 0 |
resolution |
Object | No | Photo resolution. Larger resolution means larger file size. |
resolution.x |
Integer | No | Width in pixels. Default: 1920 |
resolution.y |
Integer | No | Height in pixels. Default: 1080 |
record_duration |
Integer | No | Time in seconds to record video in record mode. Default: 5 |
framerate |
Integer | No | Camera framerate. Default: 15 |
topic |
String | No | Channel for broadcasting image events. Default: camera/{key} |
sequential_naming |
Boolean | No | Save photos with a counter instead of timestamp. Default: false |
count_start |
Integer | No | Starting number when using sequential_naming |
max_count |
Integer | No | Max photos before overwriting when using sequential_naming |
mudpi.config.json
{
"camera": [
{
"key": "camera_1",
"interface": "rtsp",
"path": "/home/pi/images",
"source": "rtsp://admin:password@192.168.1.1/stream1",
"filename": "camera_1_capture",
"topic": "camera/camera_1",
"delay": {
"hours": 0,
"minutes": 10,
"seconds": 0
},
"resolution": {
"x": 1920,
"y": 1080
},
"sequential_naming": true,
"count_start": 10,
"max_count": 100,
"record_video": false,
"record_duration": 5
}
]
}
Note
RTSP cameras work great for monitoring outdoor gardens remotely. Most IP security cameras support RTSP — check your camera's documentation for the stream URL format.