Good day fine 3D printer folk!
I am successfully utilizing Octoprint with my printer for a couple days now but am yet to figure out how to get the webcam stream up and running.
Webcam is a Microsoft Lifecam Cinema.
Board is an Orange Pi PC
I have tried these commands and get:
09: USB 00.2: 0000 Unclassified device
[Created at usb.122]
Unique ID: O0wn.aiI5bDIMpID
Parent ID: 2XnU.CpYmifTkid6
SysFS ID: /devices/platform/soc/1c1d000.usb/usb5/5-1/5-1:1.2
SysFS BusID: 5-1:1.2
Hardware Class: unknown
Model: "Microsoft LifeCam Cinema"
Vendor: usb 0x045e "Microsoft Corp."
Device: usb 0x075d "LifeCam Cinema"
Driver Modules: "snd_usb_audio"
Speed: 480 Mbps
Module Alias: "usb:v045Ep075Dd0100dcEFdsc02dp01ic01isc01ip00in02"
Driver Info #0:
Driver Status: snd_usb_audio is active
Driver Activation Cmd: "modprobe snd_usb_audio"
Config Status: cfg=new, avail=yes, need=no, active=unknown
Attached to: #22 (Hub)
pi@citrico-opipc:~$ sudo modprobe uvcvideo
pi@citrico-opipc:~$ ls -ltrh /dev/video*
crw-rw---- 1 root video 81, 1 Oct 5 07:17 /dev/video1
crw-rw---- 1 root video 81, 0 Oct 5 07:17 /dev/video0
crw-rw---- 1 root video 81, 2 Oct 5 07:17 /dev/video2
crw-rw---- 1 root video 81, 3 Oct 5 07:17 /dev/video3
pi@citrico-opipc:~$ mjpg_streamer -i "input_uvc.so -r 640x480 -f 30" -o "output_http.so"
MJPG Streamer Version.: 2.0
i: Using V4L2 device.: /dev/video0
i: Desired Resolution: 640 x 480
i: Frames Per Second.: 30
i: Format............: JPEG
i: TV-Norm...........: DEFAULT
Error opening device /dev/video0: video capture not supported.
Init v4L2 failed !! exit fatal
i: init_VideoIn failed
Not the most astute linux user, hope anyone reading this can help!
All the best
I'm running to the same issue with a Rock64 after installing Armbian and a fresh Octoprint install. Everything is working but the camera.
I found the place where the problem lies.
Oprange PI PC has an HDMI port and I think it uses / dev / video0
you can see 3 devices after connecting the camera
/ dev / video0
/ dev / video1
/ dev / video2
I was able to do a working test using the parameter
sudo ./mjpg_streamer -i "./input_uvc.so -d /dev/video1" -o "./output_http.so"
but i'm stuck on a script to enable streaming
Try the script form this guide
This is a wiki node that every user of this forum at trust level 1 or higher can edit. Find problems, typos, or incorrect information? Please contribute.
This node is starting to show its age and needs some help in being brought up to date with current versions of Raspbian
If you want to get OctoPrint up and running as fast as possible, it is highly recommended to take a look at OctoPi, which is an SD card image based on Raspbian already prepared wit…
change the camera line from
usb and add the
-d /dev/video1 to the usb cam line
Ok. I have it.
add these three commands in /etc/rc.local before the script to auto start camera
sudo rm /dev/video0
sudo chmod -R 777 /dev
mv /dev/video1 /dev/video0
The first removes the device, the second grants permissions, and the third converts video1 to video0.
It works for me.
lol that's a really dirty hack
but hey if it works
I would at least limit the chmod to the devices you're using
i didin't read your message. if change ot this parameter works that is better solution then mine
ok. i don't really good in linux, I base on tutorials on the net. please provide me a better chmod parameter.
I changed the settings for camera as you described. It works. So I deleted this line's in rc.local
tbh I never changed anything in the /dev directory so this is just an idea ^^
I would only chmod
/dev/video1 and I don't even know if that's necessary at all.
sudo mv /dev/video1 /dev/video0 would also work
I had the same issue with the rock64 I'm trying to get setup with Octoprint (using the citrico-rock64 image).
this worked perfectly for me.