Skip to main content
Share Your Experience: Take the 2024 Developer Survey
11 votes

RasPi Camera Board and Motion

to load the model after each reboot, use this setting sudo nano /etc/modules enter bcm2835-v4l2 exist and save the fle sudo reboot
jefwu's user avatar
  • 111
4 votes
Accepted

Raspberry Pi 3 and V4L2 C++ Capture Code for JPEGs

We have a case of a program that runs without error on some cameras (such as mine), but gives an error specifically with Raspberry Pi Camera Module V2. We can track this down starting with the dmesg ...
jdonald's user avatar
  • 2,914
4 votes
Accepted

What is the correct method for streaming video from the camera module to date?

By stream I assume you mean over the network. I recently researched the same question (specifically, streaming over RTSP) and these are the best options out there: https://github.com/mpromonet/...
Pedro Lopes's user avatar
3 votes
Accepted

How do you set hardware video encoder options with V4L2 M2M?

So when the V4L2 interface started providing hardware encoding/decoding, the method for setting these options changed. Previously the options were global - you'd set them once on /dev/video0 or ...
Malvineous's user avatar
  • 1,884
3 votes
Accepted

RaspberryPi Camera - bcm2835-v4l2 kernel module source

The source for the bcm2835-v4l2 kernel module is in the linux staging tree at linux/drivers/staging/vc04_services/bcm2835-camera/ You can find it e.g. in the RPF Linux repository at https://github....
Dirk's user avatar
  • 3,541
3 votes

Problems using bcm2835_v4l2 module w/ ffmpeg

This appears to be code for "you haven't assigned enough memory to the GPU". Using the raspivid command in this situation resulted in: mmal: mmal_vc_component_enable: failed to enable component: ...
larsks's user avatar
  • 653
3 votes
Accepted

ffmpeg video file with v4l2 driver

You need to select the input and output format. The v4l2 driver and the Pi Camera can stream video directly compressed with h264, which is convenient. By not specifying any format, you get some raw ...
Pietro Saccardi's user avatar
3 votes

Adjusting keyframe rate ffmpeg Logitech C920 to YouTube Live

Here is how I pipe my HIK IP camera to youtube. This does NOT include audio, and is NOT a USB camera, but perhaps it helps [NOTE: Youtube requires an audio stream, even with a video only stream]. (...
Eric Kirchner's user avatar
2 votes

Setting up RTSP using v4l2

The correct commands to start an RTSP server on the Raspberry Pi are, for example: uv4l --driver raspicam --auto-video_nr --framerate 30 --extension-presence=0 cvlc v4l2c:///dev/video0:width=640:...
cacachu's user avatar
  • 121
2 votes
Accepted

Trouble using UV4L raspidisp

The raspicam driver is optional. That said, you are missing --auto-video_nr in your command line to create the /dev/video0 node expected by your program: sudo killall uv4l (in case some other ...
cacachu's user avatar
  • 121
2 votes
Accepted

Raspbian Jessie and OpenCV 2.4.9 "get_buffer() failed (-12 (nil))" error

The source lines that are printing the error are here in libav Digging further, you can see that -12 corresponds to ENOMEM, returned here in lavfilters-ffmpeg i.e. it practically does if (!buffer) ...
jdonald's user avatar
  • 2,914
2 votes
Accepted

Adjusting keyframe rate ffmpeg Logitech C920 to YouTube Live

I managed to get it to work on YouTube Live with the following command: ffmpeg -re -ar 44100 -ac 2 -acodec pcm_s16le -f s16le -ac 2 -i /dev/zero \ -f v4l2 -input_format h264 -i /dev/video0 -...
Dan's user avatar
  • 41
2 votes

Raspberry Pi 3 and V4L2 C++ Capture Code for JPEGs

I was getting VIDIOC_STREAMON: Operation not permitted while using cv2.VideoCapture(0). Setting the GPU memory to a higher value, solved the problem.
Pedro Lobito's user avatar
1 vote
Accepted

Raspbian Stretch C920 webcam driver LED control regression?

I managed to get LED control back. I suspect some USB interfaces interferences. I have a Rii wireless keyboard attached to my Pi. I did the following: execute: uvcdynctrl -c. LED control is not in ...
LoneWanderer's user avatar
1 vote

Problems using bcm2835_v4l2 module w/ ffmpeg

As an Update, it looks like this needs 256MB now (got the hint from github)
cvo's user avatar
  • 11
1 vote

v4l2-ctl single frame capture produces image with green ending

Raw image data is rarely standardized. Are you certain that uyvy with 16 bit depth is the correct mapping? Solid green at the bottom half of the image certainly appears to be misinterpretation of raw ...
MooseBoys's user avatar
  • 111
1 vote

v4l2-ctl single frame capture produces image with green ending

Try steaming with jpg, below code i have tried . v4l2-ctl --device /dev/video0 --set-fmt-video=width=1280,height=720,pixelformat=MJPEG --stream-mmap --stream-to=frame.jpg --stream-count=1
Jitesh 's user avatar
1 vote
Accepted

UV4L and v4l2rtspserver

It seems uv4l needs to preload its library (see https://www.linux-projects.org/documentation/uv4l-core/) Something like : export LD_PRELOAD=/usr/lib/uv4l/uv4lext/armv6l/libuv4lext.so An alternative ...
mpromonet's user avatar
  • 1,124
1 vote
Accepted

How to increase usb webcam fps?

Framerate can be limited by either the CPU performance (how fast the RPi can accept the frames), by the stream format (how fast can a webcam produce given frames), or by ambient conditions (low light ...
Dmitry Grigoryev's user avatar
1 vote

Configuring camera with uv4l

On my setup (stretch, pi zero, and pi camera via csi) I needed to say --device=/dev/video1 to get v4l2-ctl to work
Steve Z's user avatar
  • 11
1 vote

Raspberry Pi 3 and V4L2 C++ Capture Code for JPEGs

Adding to Pedro Lobito's response: While I was testing at the command line using v4l2-ctl to perform test captures a lot of the supported pixelformats failed with "Operation not permitted" when ...
axawire's user avatar
  • 21
1 vote

fswebcam: Unable to find a compatible palette format

It was a DV webcam: apt-get install dvgrab dvgrab - | mplayer -j They may be modules to install or load too (e.g modprobe raw1394)
user123456's user avatar
1 vote
Accepted

raspberry camera module feed is slow with Opencv using v4l2

If you are using OpenCV to show the video feed then you are probably following their suggested tutorial in doing so. In which case, usually there is some sort of waitkey() command that gives the ...
Myg0t's user avatar
  • 111
1 vote

Stream video from Raspberry Pi to PC using the Ethernet or USB port

Awesome. Realizing the Pi supports v4l2loopback, I think various tutorials should be updated to use that rather than vivid (disabled in Raspbian by default). I'd to use the ethernet port to connect ...
jdonald's user avatar
  • 2,914
1 vote

Stream video from Raspberry Pi to PC using the Ethernet or USB port

As you are using v4l2 loopback, you can search for general streaming of camera video. ffmpeg and cvlc are keywords you might want to search here. But unless you use HLS (HTTP Live Stream) which is not ...
kwasmich's user avatar
  • 2,702
1 vote
Accepted

How do I install v4l2loopback on raspbian Jessie

Build: to build the kernel module run: $ make this should give you a file named "v4l2loopback.ko", which is the kernel module Install: to install the module run "make install" (you might ...
amit pandya's user avatar
1 vote

How to set the camera sensor mode with V4L2

I ran into this same problem and it was relatively simple to add support for it to the V4L2 API, so I did. v4l2-ctl --set-ctrl=sensor_mode=2 I submitted my patch but it was rejected because it might ...
Malvineous's user avatar
  • 1,884
1 vote
Accepted

How to set the camera sensor mode with V4L2

Official word is that sensor mode selection is not possible through V4L2, because the API does not offer the appropriate control. See this Raspberry PI forum answer.
Pedro Lopes's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible