Jump to content

Godfabber

Validating
  • Posts

    2
  • Joined

  • Last visited

Everything posted by Godfabber

  1. Hi @MacBreaker, Yes, it helped a lot! Everything works fine! I'm just wondering why we need to write sun8i_di - with low dash - if the platform name is sun8i-di, with regular hyphen...¯\_(ツ)_/¯ All my seven cameras appears correctly now: # v4l2-ctl --list-devices USB 2.0 Camera: USB Camera (usb-1c1b000.usb-1.1.1): /dev/video2 /dev/video3 SMI: SMI (usb-1c1b000.usb-1.1.2): /dev/video8 /dev/video9 HBV camera: HBV camera (usb-1c1b000.usb-1.1.3): /dev/video6 /dev/video7 SMI: SMI (usb-1c1b000.usb-1.1.4): /dev/video12 /dev/video13 USB 2.0 Camera: USB Camera (usb-1c1b000.usb-1.2): /dev/video0 /dev/video1 SMI: SMI (usb-1c1b000.usb-1.3): /dev/video10 /dev/video11 HD Webcam: HD Webcam (usb-1c1b000.usb-1.4): /dev/video4 /dev/video5 The problem now is that fswebcam can't filter the metadata device (the second /dev/video* for each camera) and try to open it, outputing an error message: # ./capture.sh --- Opening /dev/video0... Trying source module v4l2... /dev/video0 opened. No input was specified, using the first. Delaying 2 seconds. --- Capturing frame... Captured frame in 0.00 seconds. --- Processing captured image... Setting output format to JPEG, quality -1 Disabling banner. Clearing timestamp. Clearing info text. Writing JPEG image to '/opt/images/video0'. --- Opening /dev/video1... Trying source module v4l2... /dev/video1 opened. No input was specified, using the first. Unable to query input 0. VIDIOC_ENUMINPUT: Inappropriate ioctl for device . . . . and so on... I found info about this bug (or feature, depending the side you are...): https://bugzilla.kernel.org/show_bug.cgi?id=199575 Now I'll try to figure out how to filter it on fswebcam or maybe I'll need to choose another webcam app. Thanks for your help!
  2. Hi! I recently upgraded the OS of my OpiZeroLTS, from the Debian Stretch Server 5.3.5 (available distro on Sunxi website) to Debian Buster 5.8.5 (downloaded from armbian webpage). Everything went well, except when I plug my USB webcam several video devices are assigned. I made a script with fswebcam to acquire still pictures from all /dev/video* and these "ghost" cameras are causing errors when the software try to open them as regular webcams. My script: for vid in /dev/video*; do output=$(basename $vid) fswebcam -d $vid -r 1920x1080 -D 10 -S 5 -F 1 --jpeg -1 --no-banner --no-timestamp --no-info /opt/images/$output mv /opt/images/$output /opt/images/$output.jpg done ____ This is the error message I get running the script: # ./capture.sh --- Opening /dev/video0... Trying source module v4l2... /dev/video0 opened. No input was specified, using the first. Unable to query input 0. VIDIOC_ENUMINPUT: Inappropriate ioctl for device mv: cannot stat '/opt/images/video0': No such file or directory --- Opening /dev/video1... Trying source module v4l2... /dev/video1 opened. No input was specified, using the first. Unable to query input 0. VIDIOC_ENUMINPUT: Inappropriate ioctl for device mv: cannot stat '/opt/images/video1': No such file or directory --- Opening /dev/video2... Trying source module v4l2... /dev/video2 opened. No input was specified, using the first. Adjusting resolution from 1920x1080 to 1280x800. Delaying 10 seconds. --- Capturing frame... Skipping 5 frames... Capturing 1 frames... Captured 6 frames in 0.17 seconds. (35 fps) --- Processing captured image... Setting output format to JPEG, quality -1 Disabling banner. Clearing timestamp. Clearing info text. Writing JPEG image to '/opt/images/video2'. --- Opening /dev/video3... Trying source module v4l2... /dev/video3 opened. No input was specified, using the first. Unable to query input 0. VIDIOC_ENUMINPUT: Inappropriate ioctl for device mv: cannot stat '/opt/images/video3': No such file or directory ____ Here is my lsusb output: Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 003 Device 004: ID 04f2:b351 Chicony Electronics Co., Ltd Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub _____ typing v4l2-ctl --list-devices I get: cedrus (platform:cedrus): /dev/video1 sun8i-di (platform:sun8i-di): /dev/video0 HD Webcam: HD Webcam (usb-1c1b000.usb-1): /dev/video2 /dev/video3 The only physical device is the /dev/video2 I got some clue reading this post: https://unix.stackexchange.com/questions/512759/multiple-dev-video-for-one-physical-device but I don´t know much (i.e. nothing) about kernel compiling, drivers and etc. Does anyone know what to stop assigning video nodes to these memory-to-memory devices? Is there a way to filter the virtual devices on my fswebcam script? Thank you!
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines