Unifi Camera Update! (Fix Available for Testing Now)
-
Great Thanks! Any news so far?
-
hope to See it soon
-
@All
Just an update …
I have updated the codebase for Monocle Gateway and now have it working for RTSP and RTSPS.
Using the tag@noaudio
or@fixaudio
will both remove the “opus” encoded audio stream in the stream descriptor. (which makes Alexa/Echo devices happy)I will probably auto-assign the
@fixaudio
behind the scene for cameras labeled with the manufacturer “Unifi” or “Ubiquity”. We currently do this for “Foscam” cameras for a separate compatibility issue.No releases to test with yet. I need to update the portal web UI and create new builds. Hopefully tomorrow.
Thanks, Robert
-
Awesome Robert. Tag up with me if you want me to test.
-
@All
I have run into some build issues and have to rework some of the continuous integration workflow. So that is delaying some of the work to get this update more polished and released. However, I do have test builds available if anyone wants to test them. These are currently untested/unverified builds but feel free to play with it and report back if it’s working for you.
Download Test Builds Here:
Monocle Gateway (v0.0.6)
https://download.monoclecam.com/monocle-gateway/monocle-gateway-0.0.6-beta/
Required Tags
Make sure to use the tag
@noaudio
or@fixaudio
with your Unifi camera in addition to the@tunnel
tag.The need for this tag may be removed in a final release.
(See the
@insecure
tag below if you are using RTSPS encrypted connections.)
Unifi Camera RTSP URLs
Note both RTSP and RTSPS (TLS) are supported.
Unifi URL Examples Examples:
rtsp://10.1.1.1:7447/Aqf2cTyOvd96zDde
rtsps://10.1.1.1:7441/Aqf2cTyOvd96zDde
Please note that the default RTSPS URL provided by your Unifi camera includes an “?enableSrtp” parameter at the end of the URL. (Example:
rtsps://10.1.1.1:7441/Aqf2cTyOvd96zDde?enableSrtp
) You will need to omit this parameter for use with Monocle Gateway. This parameter enables Secure-RTP (SRTP) protocol inside the TLS encrypted stream — unfortunately Alexa/Echo devices don’t know how to handle the SRTP protocol and Monocle Gateway does not touch the stream packets, it only passes them across the tunneled connection.Also note that the Monocle Web Portal will display an error if you use the “RTSPS” prefix in the RTPS URL. Just ignore the error and continue, it will still save the RTSPS URL you entered.
Self Signed Certificates
For RTSPS URLs, these are using a secure connection via TLS. Secure connections expect a valid SSL certificate to fully validate the encrypted connection. However, if you are just using the Unifi camera out of the box, it will only provide a self-signed certificate. You will need to also include the
@insecure
tag to tell the Monocle Gateway to accept self-signed or non-validated certificates. It will still use an encrypted TLS connection but it won’t enforce validation on the certificate.
Multiple Monocle Gateway Instances
You may not be aware, but you can run multiple Monocle Gateway instances simultaneously!
Each instance does need a separate/unique authentication token. The last one to come online takes the “master” role and services all camera requests. If the current “master” falls offline, then one of the other connected gateway’s is promoted to the “master” role. This concept allows for failover but you can also test a new version of Monocle Gateway in a new instance without touching your existing working version of the gateway.
Just thought I would throw that out there for anymore wanting to test this new version …
Thanks, Robert
-
Thanks so much for the update. I can confirm it works with rtsp/rtsps on my echo show 10 (2nd gen). (Using tags: tunnel,fixaudio,insecure)
Unfortunately, whilst the fixaudio tag seems to work, the noaudio tag does not. This is my preferred setup as I don’t like the echo to make noise.
-
I just tested it here on my Unifi G4 Pro using both RTSP and RTSPS and
@noaudio
is working here.
(Running on Linux-x64 and OSX-x64.)You should see a section in the log with “[CLIENT RESPONSE] <-- [BODY]” followed by the SDP (stream descriptor) information. Post what yours shows and lets see if the opus audio is still present.
Here is an example of mine … using
@noaudio
2022-07-30T14:15:57.930Z [TRACE] [172.17.0.1:58208 <qRO0EG-76>] [CLIENT RESPONSE] <-- [BODY] v=0 o=- 146 0 IN IP4 10.1.1.1 s=D021F9925C56_0 u=www.evostream.com c=IN IP4 10.1.1.1 t=0 0 a=control:* a=recvonly a=range:npt=now- m=video 0 RTP/AVP 97 a=rtpmap:97 H264/90000 a=fmtp:97 profile-level-id=4d4033; packetization-mode=1; sprop-parameter-sets=Z01AM42NQB4AIf/gLcBAQFAAAD6AAAu4CdoIhGo=,aO44gA== a=control:trackID=2 a=recvonly
-
@Monocle
i ´ve updated my System Linux-x64 and try with @noaudio or @fixaudio
but always camera is´nt responding…Echo Show8Start Server again , same thing…
-
@Monocle
I upgraded too with my Unifi Cams and it work very well with the last Protect update (2.1.2)!
I used @tunnel an @fixaudio
I use a UDMPRO and 3x G3Pro and 1xG4 Doorbell
And I use 3x Echo Show 5 and 8 -
-
@Toto
Ok I used one character distance between -
Thanks for the confirmation report! Glad to hear its working for you!
-
@Monocle I used the @fixaudio and @tunnel and I have Unifi Protect 2.1.2 with G3 Instant cameras and I am unable to display on Echo Shows or Fire TV 4k Max. Both of which worked back with Unifi Protect 2.0.
file:///home/scott/Desktop/Staging/unifi.png -
@Monocle Thank you.
- noaudio log (not working)
- fixaudio log (working)
Same behaviour with either of rtsp/s.
Looking at a diff between yours and mine, the only major difference seems to be on the
a=fmtp
line. -
@toksvaeth So, from your message, does yours work? Also what do you mean by “a=fmtp”? Are you guys using a newer Monocle Gateway code? Is there something that I also need to update on my “@tunnel” local server?
-
Weirdly, switching from the 960 stream to the 1600x1200 stream made
@noaudio
work. To summarise: All working well for me now. Thank you!Here’s the log for the working 1600x1200 stream if it helps at all.
-
@vmsman I had issues getting it to work with the 960x720 feed and
@noaudio
, however switching to the 1600x1200 feed made that work fine.To be clear:
- Running the updated test build (0.0.6)
- Using the 1600x1200 RTSPS feed from my G4 doorbell (remove
?enableSrtp
from the URI) - Using tags:
@noaudio
,@tunnel
,@insecure
-
Hi Robert
Fantastic news thank you! Working here with 4 x G3Flex and 1xG4 Doorbell.
Only issue as others have said is the 960x720 camera feed from the doorbell, switching to the 1600x1200 works ok.
I know you are not monetising/commercialising the product but do you have a method to donate?
I and I am sure others would gladly donate something for your time and effort!
Thanks again
-
I never tried the lower resolution streams. I’ll try one out from my G4 Pro camera soon and see if I can get the same failure.
Thanks, Robert
-
@RS said in Unifi Camera Update!:
…
I know you are not monetising/commercialising the product but do you have a method to donate?I and I am sure others would gladly donate something for your time and effort!
Thanks again
Yes you can donate here (no obligation):
https://monoclecam.com/donateThe donations received help keep the cloud servers/services and other infrastructure costs paid to continue running this service :-)
Thanks, Robert