Streaming with Wyze2 Camera

This tutorial shows how to configure Wyze2 camera to stream over VideoCoin network.

Wyze CAM is a very low cost camera in the market, yet with higher end features such as 1080p Full HD, 8x digital zoom, night vision and Alexa integration. Wyze CAM V2 can be configured for RTSP streaming with its experimental beta firmware.

Using Wyze CAM V2 with VideoCoin is very simple. Currently, VideoCoin supports only RTMP ingest. Due to this reason, you need to use your laptop or desktop to create a bridge for format conversion from RTSP to RTMP.

Before you jump in, make sure you read VideoCoin Network Console getting started guide here https://medium.com/videocoin/getting-started-with-the-videocoin-publisher-studio-44ccb0fbb002. You should be at the “Start Streaming” stage in the guide above, where you will see a screen like below in the VideoCoin Network Console.

Update Wyze CAM V2 Firmware with RTSP Beta as described in the following link.

https://support.wyzecam.com/hc/en-us/articles/360026245231-Wyze-Cam-RTSP

Follow these instructions to continue the camera setup using an Android phone.

  • Install Wyze android app.

  • Using Wyze App on Android, set the camera for RTSP stream output (Settings -> Advanced Settings -> RTSP).

  • The above configuration step prompts credentials to access the camera (that you will later use on RTSP/RTMP bridge). After the configuration, an rtsp server URL is shown, which you can copy and use with RTSP/RTMP bridge detailed below.

Example: rtsp://lp123:lp123@192.168.86.50/live

Follow these instructions to continue the setup of VideoCoin network:

Run VideoCoin Studio, create a new stream and obtain RTMP ingest url.

Example: rtmp://ingest.studio.fuji.videocoin.network:1935/live/9bd8db7a-2d59-4bc3-85dc-2d9f916692ab

Create a protocol conversion bridge on your laptop/desktop using a tool such as FFMPEG.

Following is an example FFMPEG command to convert RTSP to RTMP protocol on a linux machine.

ffmpeg [options] -i -f flv

ffmpeg -use_wallclock_as_timestamps 1 -i rtsp://lp123:lp123@192.168.86.50/live -fflags +genpts -vcodec copy -acodec aac -f flv rtmp://ingest.studio.kili.videocoin.network:1935/live/9bd8db7a-2d59-4bc3-85dc-2d9f916692ab

(Note the above command is a single line)

The above command uses RTP over UDP. Wyze Cam V2 also supports RTP over TCP. When used in RTP over UDP mode and when WLAN is congested, camera may drop frames causing corruption in video and audio streams. It is suggested to use RTP over TCP using the following command options.

ffmpeg -rtsp_transport tcp -i rtsp://lp123:lp123@192.168.86.50/live -vcodec copy -acodec aac -f flv rtmp://ingest.console.kili.videocoin.network:1935/live/9bd8db7a-2d59-4bc3-85dc-2d9f916692ab

(Note the above command is a single line)

In the above examples, supply the RTSP URL obtained during camera setup as input to the FFMPEG command. Supply the RTMP ingest URL obtained from the VideoCoin Network Console as output to the FFMPEG command.

The preview of the Wyze CAM V2 stream appears in VideCoin as shown below. You can share the HLS output stream URL from the VideoCoin Network Console with friends and family members around the world.