For the complete documentation index, see llms.txt. This page is also available as Markdown.

USB Webcam Video on RZ/V2N

Capture video from a USB webcam on the SolidRun RZ/V2N HummingBoard IIoT and stream it to a remote PC over Ethernet, or display it locally on the 7" MIPI LCD — using GStreamer and VLC.

🎥 Streaming USB Webcam Video on RZ/V2N

A practical, end-to-end guide for capturing video from a USB camera attached to a SolidRun RZ/V2N HummingBoard IIoT and delivering the stream either to a remote PC over Ethernet or to the local 7" LCD panel — using GStreamer on the board and GStreamer or VLC on the receiver.

📋 Overview

Two delivery paths are supported. Pick the one that matches your use case:

The default codec is MJPEG over RTP — supported by both cameras and requiring no hardware codec on the board. An H.264 over RTP variant is also shown for the IMX678 module, which produces H.264 natively.

The IMX678 module's USB descriptor reads Camera Vendor USB3 openMV Camera — that is a firmware placeholder string. The hardware is the SF-SQ8A987-86 IMX678 module.

🛠️ Hardware

Component
Details

🟢 SoC / board

Renesas RZ/V2N — SolidRun HummingBoard IIoT

🖥️ Display

7" LCD, native 1024×600, MIPI-attached

🎦 Camera A

Logitech C922 Pro Stream Webcam · USB ID 046d:085c

🎦 Camera B

IMX678 USB3 Camera Module SF-SQ8A987-86 · USB ID 414c:6573

📡 Camera class

USB Video Class (UVC) — both cameras

🌐 Network

Onboard Ethernet on the carrier board

📦 Prerequisites

🟢 On the RZ/V2N (Yocto image)

The image must include:

  • ✅ V4L2 kernel support (CONFIG_USB_VIDEO_CLASS=m — already in the BSP defconfig)

  • v4l-utils — provides v4l2-ctl

  • ✅ GStreamer core + good / bad / ugly plugin sets

  • ✅ Weston (only for Option B — local LCD display)

Add to your image recipe or local.conf:

💻 On the PC (receiver)

🔍 Detecting the camera

These steps are identical for both supported cameras.

Step 1 · Confirm USB enumeration

Look for one of:

Step 2 · Load the UVC driver (if not auto-loaded)

Expected:

udev autoloads uvcvideo on hotplug once the matching kernel modules are present in /lib/modules/$(uname -r)/. The manual modprobe is only needed for the first run or if udev autoloading is disabled.

Step 3 · Identify the V4L2 capture node

When a single camera is plugged in, the capture node is typically /dev/video0.

To identify the correct node when multiple V4L2 sources are present:

The node whose Device Caps line includes the Video Capture flag is the right one.

Step 4 · List supported formats

🎦 Camera
Native formats
Useful resolutions

Logitech C922 Pro

MJPG, YUYV, (H.264 on some firmware)

640×480, 1280×720, 1920×1080 — all @ 30 fps

SF-SQ8A987-86 (IMX678)

MJPG, H.264, YUYV

640×480, 1280×720, 1920×1080, 3776×2120, 3840×2160 — all @ 30 fps

🌐 Option A — Stream over Ethernet to a remote PC

Architecture

How it works:

  • The board captures MJPEG frames from /dev/video0.

  • Frames are packetized into RTP (payload type 26 = JPEG) and sent over UDP to the PC on port 5000.

  • The PC receives, depacketizes, decodes, and renders the stream.

Get the PC's IP address (ip a on Linux, ipconfig on Windows) — used as <PC_IP> in every sender command below.

📤 A.1 — Sender: Logitech C922 (MJPEG 1280×720 @ 30 fps)

🟢 On the RZ/V2N:

📤 A.2 — Sender: SF-SQ8A987-86 (MJPEG 1920×1080 @ 30 fps)

🟢 On the RZ/V2N:

No local decode is performed for streaming. The board only captures + packetizes — the receiver does the heavy decoding. 1080p MJPEG over RTP runs comfortably on the board.

If the receiver PC or network struggles, drop the capture to 720p by changing 1920 / 1080 to 1280 / 720.

📤 A.3 — Sender: SF-SQ8A987-86 (H.264 1920×1080 @ 30 fps — lower bandwidth)

The IMX678 module produces H.264 natively. H.264 over RTP yields a much smaller stream than MJPEG and is the recommended path for wireless / constrained networks.

🟢 On the RZ/V2N:

The Logitech C922 also advertises H.264 on some firmware revisions, but support varies between units. Stay on MJPEG for the C922 unless v4l2-ctl --list-formats-ext confirms H.264 is present.

📥 A.4 — Receiver: GStreamer (MJPEG)

📥 A.5 — Receiver: GStreamer (H.264)

💻 On the Linux PC:

🎬 A.6 — Receiver: VLC (via SDP file)

VLC needs a Session Description (SDP) file to know how to parse an RTP-over-UDP stream.

Open the SDP in VLC:

Or from the VLC GUI: Media → Open File… and select camera.sdp.

Reduce VLC latency — VLC defaults to ~1 s of network caching for smoothness. To get closer to real-time, launch with:

🎬 A.7 — Receiver: VLC (direct RTP URL)

VLC can also open the stream directly without an SDP:

🖥️ Option B — Display locally on the 7" LCD

This option renders the camera stream fullscreen on the 7" 1024×600 panel using Weston (the Wayland compositor included in the SolidRun image).

Architecture

🔧 B.1 · Set the Weston environment

GStreamer needs two environment variables to talk to Weston. Run these in any shell that will launch a GStreamer command:

Confirm Weston is running and the Wayland socket exists:

Why wayland-1? SolidRun's Yocto image runs Weston as wayland-1 (not the default wayland-0). Verify with the ls command above — it will show the actual socket name.

🎥 B.2 · Local preview pipeline (works for both cameras)

🟢 On the RZ/V2N:

Both supported cameras are UVC-class — the v4l2src element does not need camera-specific configuration. Capture at 640×480, software-decode JPEG, software-scale to the panel's native 1024×600, then fullscreen via Weston.

Stop with Ctrl-C.

🚀 B.3 · Make the preview a one-shot script

Install and run:

🔀 B.4 · Stream over Ethernet and preview locally at the same time

Use tee to duplicate the MJPEG stream — one branch goes to the network, the other is decoded locally for the panel:

🟢 On the RZ/V2N:

📊 Performance notes

🌐 Network streaming

The board only does capture + RTP packetization for network streams — no local decode. The heavy lifting happens on the receiver PC, so the RZ/V2N's CPU stays mostly idle.

🎦 Camera
📐 Resolution
🧬 Codec
📡 Bitrate (approx)
🧠 RZ/V2N CPU
📝 Notes

Logitech C922

1280×720 @ 30

MJPEG

30–60 Mbps

Low

Default for C922

Logitech C922

1920×1080 @ 30

MJPEG

60–120 Mbps

Low

Works on wired LAN

SF-SQ8A987-86

1920×1080 @ 30

MJPEG

50–100 Mbps

Low

Native MJPEG

SF-SQ8A987-86

1920×1080 @ 30

H.264

5–15 Mbps

Low

Lowest bandwidth · best for Wi-Fi

🖥️ Local LCD preview

The host pipeline (software JPEG decode + software color convert + SHM copy to Weston) is what limits sustained display rate.

📐 Resolution
🎬 Behavior on 1024×600 panel

640×480 MJPEG

✅ Smooth 30 fps — recommended default

1280×720 MJPEG

🟡 Generally smooth, slightly higher CPU

1920×1080 MJPEG

🔴 Visibly slow (~10 fps) — CPU-bound

For ≥720p smooth on the LCD, two upstream improvements are needed (not in the default image):

  1. Hardware H.264 decode (v4l2h264dec or the Renesas codec plugin) — drops decode CPU to near zero.

  2. Weston dmabuf support — eliminates the per-frame SHM memcpy.

Neither is required for the 640×480 default path.

🔧 Troubleshooting

modprobe: ERROR: could not insert 'uvcvideo': Exec format error

Cause: the .ko was built against a different kernel-source state than the running Image.

Fix: rebuild kernel and modules in lockstep from the same source state:

Copy both arch/arm64/boot/Image and /tmp/rzv2n-mods/lib/modules/<ver>/ to the board, then reboot.

Avoid this class of failure entirely by adding to the defconfig:

❌ Stream is choppy · "A lot of buffers are being dropped"

Cause: the pipeline was launched without a caps filter, so v4l2src negotiated the camera's default (often 4K YUYV uncompressed at 30 fps — ~474 MB/s of raw video).

Fix: always pin format and resolution with image/jpeg,width=...,height=...,framerate=30/1 between v4l2src and the decoder.

⚠️ Could not bind to zwp_linux_dmabuf_v1

Cause: Weston in this image does not advertise the dmabuf protocol.

Effect: waylandsink falls back to SHM buffers — one extra memcpy per frame.

Verdict: safe to ignore at 640×480; becomes a measurable cost at 1080p+.

⚠️ uvcvideo: Non-zero status (-71) in video completion handler

A single occurrence at stream start is benign — the UVC alternate-setting switch as the camera negotiates its USB bandwidth allocation.

If the message repeats continuously during streaming, suspect:

  • 🔌 Cable quality

  • ⚡ Insufficient hub power (especially with USB3 cameras drawing >500 mA)

  • 📡 USB signal integrity (long cables, passive hubs)

Device '/dev/videoX' is not a capture device. Capabilities: 0x4a00000

Cause: targeting the UVC metadata node (typically /dev/video1 on the IMX678 module).

Capability bits 0x4a00000 = META_CAPTURE | STREAMING | EXT_PIX_FORMAT — note no VIDEO_CAPTURE (bit 0x1).

Fix: use /dev/video0 — the node whose Device Caps includes the Video Capture flag:

❌ Receiver shows a black window — no video

Checklist:

⚠️ fpsdisplaysink reports impossibly low fps

Cause: fpsdisplaysink overrides its inner sink's sync=false back to sync=true, dropping late frames against the pipeline clock. The rendered fps it reports is sink-survival rate, not source delivery rate.

Fix — for an accurate source-rate measurement:

Total time / 300 = actual source fps.

❌ Camera enumerates but no /dev/video* appears

If dmesg shows new high-speed USB device but no follow-up idVendor= / Product= lines, the descriptor read failed.

This is a USB-host issue, not a driver issue. Suspect cable / hub / power.

🚀 Quick reference

🟢 On the RZ/V2N

Task
Command / Section

🔍 Detect camera

lsusb

📥 Load UVC driver

modprobe uvcvideo

📋 List V4L2 nodes

v4l2-ctl --list-devices

📐 List supported formats

v4l2-ctl -d /dev/video0 --list-formats-ext

📡 Stream MJPEG to PC (C922)

see §A.1

📡 Stream MJPEG to PC (IMX678)

see §A.2

📡 Stream H.264 to PC (IMX678)

see §A.3

🖥️ Show preview on 7" LCD

usb-camera-preview

🔀 Stream + local preview

see §B.4

⏹️ Stop preview

Ctrl-C

💻 On the PC

Task
Command / Section

📥 Receive MJPEG (Linux / Windows)

see §A.4

📥 Receive H.264 (Linux)

see §A.5

🎬 Receive via VLC (SDP file)

see §A.6vlc camera.sdp

🎬 Receive via VLC (direct URL)

see §A.7vlc rtp://@:5000

📚 See also — for a deeper dive into the IMX678 module on RZ/V2N (kernel module install, driver detection, format reference), see the companion document "USB Camera on RZ/V2N — IMX678 USB3 Module (SF-SQ8A987-86)".

Last updated