Stream Unifi to Synology
As we enter the age of seamless connection, proprietary technology and connections seem to increase. Closed APIs can create many walled gardens inside a singular network. Thankfully, in their latest version of UniFi Protect, Ubiquiti has included RTSPS streaming. Today we will take a look at connecting UniFi cameras joined to a UniFi Protect console to a Synology Surveillance Station.
First, we will start off pairing to the UniFi Protect console. Make sure your cameras are set to factory default and update to the latest firmware if you have trouble pairing. Once you have the cameras paired to the console open up the camera's menu, go to settings, and then expand the advanced menu options. Turn on your choice of streaming resolution and copy the link. The link will look something like this:
rtsps://10.0.1.2:7441/kjhrwq348y7lawisdhf?enableSrtp
Let’s change it to something the Synology can use. Thankfully UniFi has provided a backup port only using RTSP instead of RTSPS. Note that RTSP is less secure but is all that Synology will accept. Before we manipulate the link we need to pull the recovery code from the UniFi Protect consoles settings. Click the settings gear on the left side of the console and on the general page scroll down to the recovery code. Reveal and copy the code to the clipboard. The new URL string should look like this
ubnt:recoveryCode@10.0.1.2:7447/kjhrwq348y7lawisdhf
Note the changes…
We removed the protocol header as Synology adds this for us:
rtsps://
We added the username and password for the console at the beginning:
ubnt:recoveryCode
We followed the login info with an @ to tell the Synology where to log in to:
@
Next, we changed the port number from 7441 to 7447. In UniFi, port 7441 is for RTSPS streams and 7447 is for RTSP streams.
7441 -> 7447
Finally, we removed the appended direction set at the end of the link:
?enableSrtp
Now that we have the new code all we have to do is go in to the Synology Surveillance Station console and add the “camera”. Go to IP camera and open the wizard to add a new camera. The settings should be:
Brand: [User Define]
Type: Streaming - Rtsp
Path: ubnt:recoveryCode@10.0.1.2:7447/kjhrwq348y7lawisdhf
After you input this info test out the config. If it works click apply and you’re set!