Components Required

  • Raspberry Pi 2
  • Wi-Fi module
  • Camera module

Softwares Required

VLC media player or Quicktime media player


  1. Connect Camera to Raspberry Pi.
  2. Enable Camera in Raspberry Pi Configuration file.
  3. Establish a local wireless network and connect the Raspberry Pi to it.
  4. Install VLC program on Raspberry Pi
  5. Executing Streaming command specifying communication protocol (RTSP) and port.
  6. Now you can see the streaming on any Client connected to the same network.

Real Time Streaming Protocol (RTSP)

The Real Time Streaming Protocol (RTSP) is a network control protocol designed for use in entertainment and communications systems to control streaming media servers. The protocol is used for establishing and controlling media sessions between end points. Clients of media servers issue VCR-style commands, such as play and pause, to facilitate real-time control of playback of media files from the server.

The transmission of streaming data itself is not a task of the RTSP protocol. Most RTSP servers use the Real-time Transport Protocol (RTP) in conjunction with Real-time Control Protocol (RTCP) for media stream delivery, however some vendors implement proprietary transport protocols. The RTSP server software from Real Networks, for example, also used Real Networks’ proprietary Real Data Transport (RDT).

The RTSP (Real Time Streaming Protocol) protocol is a client-server multimedia presentation control protocol, designed to address the needs for efficient delivery of streamed multimedia over IP networks. It leverages existing web infrastructure (for example, inheriting authentication and PICS from HTTP) and works well both for large audiences as well as single-viewer media-on-demand.

Real Networks, Netscape Communications and Columbia University jointly developed RTSP within the MMUSIC working group of the Internet Engineering Task Force (IETF). In April 1998, it was published as a Proposed Standard by the IETF.

VLC media Player

Streaming The Camera Video Using RTSP

Enter the following command to start the streaming:

raspivid -o - -t 0 -n | cvlc -vvv stream:///dev/stdin --sout '#rtp{sdp=rtsp://:8554/}' :demux=h264
  • raspivid is used to capture the video
  • “-o -” causes the output to be written to stdout
  • “-t 0” sets the timeout to disabled
  • “-n” stops the video being previewed (remove if you want to see the video on the HDMI output)
  • cvlc is the console vlc player
  • “-vvv” and its argument specifies where to get the stream from
  • “-sout” and its argument specifies where to output it to

Options available

Specifying the camera resolution

raspivid -o - -t 0 -n -w 600 -h 400 -fps 12 | cvlc -vvv stream:///dev/stdin --sout '#rtp{sdp=rtsp://:8554/}' :demux=h264
  • -w Width available range: 64 to 1920
  • -h Height available range: 64 to 1080
  • -fps Frames per second: 2 to 30

Viewing the RTSP Stream over the Network

You need a player which supports RTSP, for instance VLC, QuickTime, etc.  Open a network stream using

rtsp://<Raspberry Pi IP Address>:8554/
Categories: Electronics