Menu

🔎How to Integrate SONOFF Camera into Scrypted?

1. Introduction

This guide walks you through the steps to integrate the SONOFF Camera into the Scrypted platform via the ONVIF protocol. Once connected, you'll be able to:

  • Stream real-time video
  • Monitor motion detection events
  • Set up automations using motion triggers

Before you start, make sure your device firmware and app version meet the requirements for ONVIF support.

  • SONOFF CAM-PT2 camera with firmware ≥ v1.0.5
  • SONOFF CAM-S2 camera with firmware ≥ v1.1.5
  • eWeLink App (version ≥ v5.18.0) installed on your phone

*This tutorial takes the SONOFF CAM-PT2 camera as an example.


2. What You'll Need

Hardware & Software Requirements

  • A device or container with Scrypted installed
    (e.g., PC, Raspberry Pi, or Docker)
  • Installation guide for Scrypted:
    https://docs.scrypted.app/installation.html
  • Make sure both your camera and the Scrypted instance are on the same local network for seamless communication.
  1. Add the CAM-PT2 to the eWeLink app
  2. Go to:
    Device Settings → More Settings → ONVIF/RTSP
  3. Enable ONVIF/RTSP and take note of:
    • IP address
    • ONVIF Port
    • Username (can be edited)
    • Password (can be edited)

3. Pair with Scrypted

Step 1: Install the ONVIF Plugin

  1. Open the Scrypted dashboard
  2. Click INSTALL PLUGIN
  3. Search for @scrypted/onvif, then click INSTALL

Step 2: Add the Camera

  1. After installation, click REFRESH to initiate automatic ONVIF camera discovery. If the camera is not detected, use ADD ONVIF CAMERA to perform manual device registration.

  1. Enter:
    • ONVIF Username
    • Password
  1. Click ADD

Your SONOFF CAM-PT2 is now successfully integrated!


4. Supported Features

4.1. Live Video & Audio

  • View camera feed in real time
  • Enable or disable audio from the stream

4.2. Motion Detection

  • View motion status from the camera
  • Note: Noise detection is not supported

4.3. PTZ Control

  • Control the camera's pan and tilt

4.4. Automation

  1. Go to the Automations tab and click ADD AUTOMATION
  2. Name the automation

  1. Under TRIGGERS, set:
    • Trigger Type: Device Event
    • Device Event: Camera's MotionSensor

  1. Under ACTIONS, set:
    • Action Type: e.g., Script → Log a message like:
      "There is an object passing by"


5. Feature Overview

SONOFF Camera supports ONVIF and RTSP, enabling easy integration with Scrypted. To help you get to know the differences, a quick feature overview is provided below.

CAM-PT2

Feature

ONVIF

RTSP

Device Discovery

×

Live View

PTZ Control

×

Event Notification

Triggers Automation (Motion)

×

CAM-S2

Feature

ONVIF

RTSP

Device Discovery

×

Live View

Event Notification

Triggers Automation (Motion)

×

Previous
🔎 How to Integrate SONOFF Camera into Home Assistant?
Next
🔎 How to Build a Smart Thermostat with the NS Panel Series
Last modified: 2025-08-20