Wyze Cam V3 - RTSP works!

Step 10 and 11 are the camera user name and password that was used in Wyze app while adding the device. In Wyze mobile app one can add multiple cameras and each can have its own user id and password.

It is separate from the Wyze account that uses email address and password.
I use cloudflare tunnel. Regarding your question about duckdns. No you do not need to change anything.

Okay, but without the app, how do you connect to the camera to give it the network credentials for it to connect to the wifi network?

I didn’t say you didn’t need the app, I said you don’t need a cloud account to use the cameras with RTSP.

Upon opening the Wyze app, the first screen requires entering Wyze account credentials before proceeding to device setup, including wifi and RTSP settings. Are you saying the login can be bypassed?

I said you don’t need the cloud account to use the cameras with RTSP. Once you give the camera your WiFi credentials, you never need to open the Wyse app again.

Hello everyone. I wanted to post my findings in case they help anyone else. Ive been fighting this for months. I have my wyze cams on an IoT VLAN which is isolated from my normal lan. I was unable to get the homekit streaming working for what feels like forever.

Today I buckled down and using the states table in Pfsense, I was able to determine that the newer versions Wyze RTSP firmware use a random non-standard UDP port to send the RTSP traffic. I say the “newer versions” because I have a V2 running an older version of the wyze rtsp firmware which does not do this.

Anyway what I did to determine which ports I needed to allow was the following:

  1. Created DHCP reservations for my two V3 wyze cams.

  2. Allow udp traffic on any port from my v3 cam ip addresses to my HA server where the cameras have been added as Homekit accessories

  3. Established connection from the home app on my iPhone to each the wyze cameras.

  4. While viewing the camera stream, use the pfsense states table filtered by each v3’s ip address to identify which ports the v3’s were sending UDP traffic to my HA server on. Each camera used a different single udp source port to send the traffic to HA.

  5. Create pfsense rules allowing UDP traffic from the v3 ip_addr:source_port I discovered from the states table to HA. I needed to allow udp traffic on all ports on the HA side because there are multiple connections established. For example wyzecam v3 udp source port 12345 was connecting to 4 random consecutive udp ports say 54321, 54322, 54323 and 52324 on the ha server. Closing the stream and reestablishing it on my iPhone would create new connections from udp source port 12345 to 4321, 4322, 4323, 42324. The only consistent observation I made was that the v3 source port does not seem to change, whereas the destination ports on the ha side do.

  6. (BONUS) I then removed the original rule which I used to determining the v3 source ports, and then created a new rule beneath the two I created in step 5 (2 v3 cam’s remember?) explicitly blocking any other outbound traffic by the wyzecams.

Some other notes:

  • i use avahi on pfsense for repeating mdns.
  • My ha server is on my lan if that wasnt evident. It is allowed to establish connections to the cameras in my IoT subnet, but not visa-versa.

Happy to answer whatever questions I can. Hope this helps some of you.

2 Likes

Ok, thanks for your incite. I too use pfSense and would like to see more details on the rules you are using. I’m at loss at were the state table filter, you are referencing, is located. Would really appreciate being pointed in the right direction since I also find my Wyze integration to be questionable.

5310

States Table: Diagnostics > States You can filter by IP address in the filter expression field.

Seems to be above my pay grade. Can you provide a Firewall → Rules → Edit and a state table screenshot for one of your cameras.

Many thanks.

What an awesome addon! Works like charm, just couldn’t get the audio working on v3 cam.
Are there any tricks for it or only works on another firmware?
Enabled in the config, but still no audio on the streams. Works fine with v2 cams.

Hi there, anyone manage to get Motion from the camera using this?
No motion event showing up in mqtt

I don’t understand your question.
I have four Wyze Cams recording motion using the Frigate Add-on.

Hi, i was hoping that theres a way to get the motion detection feature thats built in the camera without having to go through frigate

I don’t know what’s “built in” to the camera because the first thing I do with mine is to flash them with the RTSP hack. I am pretty sure that the motion detection is a feature of the Wyze cloud. Which I don’t use.

And, what’s wrong with Frigate?

Just wanted to find a ways to save on cpu usage, i do not have a coral and i already have a couple of cameras on frigate already

OK, makes sense.

My outdoor wyze camera batteries are draining fast when I am running docker wyze bridge. I can’t go 1 day.

Anyone have this issue and any suggestions?

@mrlt8 thank you for this great addon! I only have two cameras and use the addon for a day, but it is fantastic. I waited 2 years for official RTSP support from Wyze, but nothing happened.

Can someone guide me on how to use WebRTC stream with HA Frontend?
I set up a generic camera, but I must use RTSP with it and I was able to add the camera to the frontend, but the addon allows selecting WebRTC, so I’d like to use it. I also you’d like to avoid using RTSPtoWebRTC (RTSPtoWebRTC - Home Assistant) because the addon (Wyze Bridge) supports WebRTC.

BTW how to get still image generation working (Home Assistant ¡ mrlt8/docker-wyze-bridge Wiki ¡ GitHub)?

I have my camera setup with:
still image: http://192.168.0.10:5000/snapshot/gara.jpg
stream: rtsp://192.168.0.10:8554/gara

and the camera works in my local network and from the outside (using Cloudflare), but I don’t get those screenshots.

I was struggling with this for ages, as the RTSP stream for the v3 cameras doesn’t seem to resolve in the Docker Bridge or when adding as a generic camera. So, I went to the Bridge and checked the working HLS stream URL and added it as a Generic Camera integration and it works perfectly.

http://192.168.0.111:8888/camera-name-here/stream.m3u8

1 Like

First, thanks so much for this! I have 2 Wyze Cam V3 and 1 V2, all working well with wyze-bridge so far. No need to flash the cameras.

I have both HA and wyze-bridge running in docker containers on my Raspberry Pi 3B. In order for the still image and rtsp to show up on my HA dashboard, I noticed I have to do something like that for my URLs settings in the generic camera:

http://localhost:5000/img/back-yard-cam.jpg
rtsp://localhost:554/back-yard-cam

(Side note: I mapped 8554 RTSP port to port 554 because 8554 was already used by ring-mqtt:

    ports:
      - 554:8554 # RTSP 

)

As expected, the images are camera snapshots from some time back. If I need the latest snapshots, I do something like:

http://localhost:5000/snapshot/back-yard-cam.jpg

as my still image URL.

However, this also means that the images will keep on updating (and the connections to the cameras active) as long as the HA dashboard is opened. I think while this could be useful, I am curious if there is a way to have a “button” in HA to basically refresh the still images on demand? Is there any method in HA to call for a “http://…/snapshot/…” request in order to trigger a new snapshot via wyze-bridge?