Webadres already in use & video0 vs video1

Camera model
logitech C525 connected to a usb-hub to a "pi zero w2" on a 2A psu

pi@octopi:~ $ lsusb
Bus 001 Device 004: ID 046d:0826 Logitech, Inc. HD Webcam C525
Bus 001 Device 002: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

What is the problem?
binding adress already in use, and i think that is the reason why webcam keeps forever loading on "octopi.local"...

The second issue is that it cannot decide wether it wants to be at "/dev/video0" or "/dev/video1" so it wont always find it as it is on 1 but still keeps looking for video0?

What did you already try to solve it?
had struggels to get the C525 detected, aparently i have one dead port on the hub but in those struggels i did somethings... i do not quite recall exactly and there should be an easier solution than re installing octo print, if not only for gaining more knowledge of linux. but i think i got a second mjpg server running from what i have googled.

pi@octopi:~ $ ps -ax|grep mjpg
416 ? Sl 0:00 ./mjpg_streamer -o output_http.so -w ./www-octopi -n --listen 127.0.0.1 -i input_uvc.so -d dev/video1 -r 1280x720 -f 30 -d /dev/video0
1377 pts/0 S+ 0:00 grep --color=auto mjpg

the problem being that the second one now pid 1377 will keep increasing with 1 every second, and killing it with "sudo kill -9 pid" only bring it back 1 second later, but ive not been able to locate any install package of it due to either other name than mjpg or my own incompetence while the latter is more likely

for the video0/1 struggle someone sugested adding the -d:

sudo nano boot/octopi.txt
camera="usb"
camera_usb_options="-d dev/video1 -r 1280x720 -f 30"

besides those 2 lines nothing has been enabled, which should be fine?

Logs (/var/log/webcamd.log, syslog, dmesg, ... no logs, no support)

pi@octopi:/ $ root/bin/webcamd
Starting up webcamDaemon...

--- Configuration: ----------------------------
cfg_file: /boot/octopi.txt
camera: usb
usb options: -d dev/video1 -r 1280x720 -f 30
raspi options: -fps 10
http options: -w ./www-octopi -n --listen 127.0.0.1

Explicitly USB device:

Found video devices:
/dev/video1
/dev/video10
/dev/video11
/dev/video12
/dev/video13
/dev/video14
/dev/video15
/dev/video16
/dev/video2
config file='/boot/octopi.txt':USB device was not set in options, start MJPG-streamer with the first found video device: /dev/video1
<13>Feb 1 13:27:19 pi: Starting USB webcam
Checking for VL805 (Raspberry Pi 4)...

  • It seems that you don't have VL805 (Raspberry Pi 4).
    There should be no problems with USB (a.k.a. select() timeout)
    Running ./mjpg_streamer -o output_http.so -w ./www-octopi -n --listen 127.0.0.1 -i input_uvc.so -d dev/video1 -r 1280x720 -f 30 -d /dev/video1
    MJPG Streamer Version: git rev: 5554f42c352ecfa7edaec6fc51e507afce605a34
    i: Using V4L2 device.: /dev/video1
    i: Desired Resolution: 1280 x 720
    i: Frames Per Second.: 30
    i: Format............: JPEG
    i: TV-Norm...........: DEFAULT
    Done bring up all configured video device

Goodbye...

pi@octopi:/ $ UVCIOC_CTRL_ADD - Error at Pan (relative): Inappropriate ioctl for device (25)
UVCIOC_CTRL_ADD - Error at Tilt (relative): Inappropriate ioctl for device (25)
UVCIOC_CTRL_ADD - Error at Pan Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_ADD - Error at Tilt Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_ADD - Error at Pan/tilt Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_ADD - Error at Focus (absolute): Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Pan (relative): Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Tilt (relative): Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Pan Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Tilt Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Pan/tilt Reset: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Focus (absolute): Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at LED1 Mode: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at LED1 Frequency: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Disable video processing: Inappropriate ioctl for device (25)
UVCIOC_CTRL_MAP - Error at Raw bits per pixel: Inappropriate ioctl for device (25)
o: www-folder-path......: ./www-octopi/
o: HTTP TCP port........: 8080
o: HTTP Listen Address..: 127.0.0.1
o: username:password....: disabled
o: commands.............: disabled
bind: Address already in use
o: server_thread(): bind(8080) failed

Additional information about your setup (OctoPrint version, OctoPi version, ...)

octoprint version: Version 1.7.3
octopi: Version 0.18.0, running on Raspberry Pi Zero 2 Rev 1.0

Decided to do a reinstall of octoprint seems to be working now. learning comes anotherday it seems :slight_smile:

1 Like