Live video from Pi Zero (W) with non-threaded video capture

A project log for STS-PiLot Robotics Remote Control

Remote control web interface with live video for Raspberry Pi Robots

mark-dammer-mm0dqmMark Dammer MM0DQM 03/24/2017 at 12:100 Comments

Pi Zero W with camera and Explorer pHAT

It is now possible to run STS-PiLot on a Pi Zero (W) with live video. The latest software version contains an additional non-threaded video feed that puts less strain on systems with lower CPU specs.

Use the following URL syntax to use it:

http://[your pi's ip]:5000/?video=[msecs]
[msecs] sets the minimum delay between frame captures in milliseconds. Example: will provide a video display with about 10 frames per second.

How does it work:

http://[your pi's ip]:5000/single_frame.jpg provides a single JPEG frame on every call to the URL.

The javascript program that runs within your browser calls this URL every [msecs].

This functionality is available in both the Pi Camera and the OpenCV generic camera interface.

You still get the threaded, high framerate, low latency, higher CPU interface when using the base URL without arguments: http://[your pi's ip]:5000

And this is the Polulu ZUMO chassis featuring a Pi Zero W with live camera feed and Explorer pHAT that had its first public appearance at Moray Coder Dojo yesterday: