Vibe Coded an app/container to handle Amcrest DVRIP control protocol for pan/tilt for cameras that dont support PTZ over ONVIF to add Pan Tilt controls to frigate.
▲ 14 r/unRAID+1 crossposts

Vibe Coded an app/container to handle Amcrest DVRIP control protocol for pan/tilt for cameras that dont support PTZ over ONVIF to add Pan Tilt controls to frigate.

I bought a bunch of these cheap ass amcrest ASH21-B's from amazon, to use with frigate inside, set them up in the dumb amcrest smart home app, but didnt want to keep going to the app to adjust Pan/Tilt and Frigate didnt seem to support the DVRIP protocol.

So i went to Codex and verified/tested with Claude to create a proxy for the DVRIP controls. It made a native app and published to Unraid or you can host on your own docker via the instructions https://github.com/gaming09/amcrest-ptz-bridge

This is 100% local verified by packet capture.

This is vibe coded, i had a problem that i needed solved, it solved it, I'm sharing it. if you hate vibe coding don't use it, i don't need to know how you hate vibe coding. If you find a problem with it I'm happy to address it.

Here is some AI slop for how it works and why its needed

I wanted to control my Amcrest SmartHome PTZ camera entirely through Frigate instead of using the Amcrest SmartHome app.

Frigate’s PTZ interface uses ONVIF. Some Amcrest cameras provide a working native ONVIF service, but support can vary by model and firmware. Before installing anything, try pointing Frigate directly at the camera’s ONVIF service. The ASH21 is currently listed by Frigate as supporting basic PTZ on port 80:

cameras:
  patio_camera:
    # Existing ffmpeg/detect configuration remains here.

    onvif:
      host: CAMERA_IP
      port: 80
      user: admin
      password: CAMERA_PASSWORD

If native ONVIF doesn’t work, I made Amcrest PTZ Bridge, which is now available through Unraid Community Applications.

The bridge:

  • receives ONVIF PTZ commands from Frigate;
  • translates them into local Amcrest/Dahua DVRIP commands;
  • handles pan, tilt and stop;
  • includes a fail-safe movement timer;
  • leaves video/audio streaming directly between the camera and Frigate;
  • has no telemetry or cloud integration;
  • supports a protected password file instead of a Docker password variable.

After installing it, Frigate points to the Unraid server (or docker IP) instead of directly to the camera:

cameras:
  patio_camera:
    onvif:
      host: UNRAID_SERVER_IP
      port: 18880
      user: ""
      password: ""

Use one bridge instance and a unique port for each camera.

GitHub: https://github.com/gaming09/amcrest-ptz-bridge

In Unraid Apps, search for Amcrest PTZ Bridge.

For the PWNTOOLS usage is as follows

Pwntools is used indirectly by the pinned DahuaConsole dependency—not for pentesting anyone.

DahuaConsole uses it for:

  • Opening the TCP connection to the camera with remote(...)
  • Sending and receiving DVRIP packets
  • Packing binary protocol fields with helpers such as p32()
  • Handling socket timeouts and connection errors

the bridge.py only calls DahuaFunctions; it does not directly use pwntools. The camera credentials are passed through that local DVRIP connection to the configured camera on port 37777.

Pwntools normally has an optional version check, which is why we added pwn.conf to disable it. Removing pwntools entirely would require replacing or modifying DahuaConsole’s networking layer and could break camera communication.

https://preview.redd.it/9bufohz6pdjh1.png?width=664&format=png&auto=webp&s=49f5a831c7589b89e788d10f54d5d4c8b0c38358

https://preview.redd.it/krnagphfpdjh1.png?width=1118&format=png&auto=webp&s=a176be9076fab14ff2d3210d2a24aa26b76c52e1

https://preview.redd.it/wvsg4apcqdjh1.png?width=519&format=png&auto=webp&s=2b75a3b0d15a572da6e14c29040effbff1a44d78

reddit.com
u/gamin09 — 6 days ago

How do you know if a company is legit or not?

idk if im allowed to post names of companies but how do I know what im getting is what im getting they show lab results and stuff but is there somewhere I can get the reta tested too?

reddit.com
u/gamin09 — 18 days ago

2019 Model 3 I want to replace the center console with the new style one, help with parts list

I want to change out the old style model 3 center console and put in the newer one. I am looking for a parts list and how to handle the USB ports . if anyone can assist me please

reddit.com
u/gamin09 — 2 months ago