LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 07-26-2013, 04:38 PM   #1
waddles
Member
 
Registered: Sep 2012
Posts: 373

Rep: Reputation: 0
webcams not working


I had a Microdia PC Camera (0c45:60fc) working back under Slackware 11.0 but since could not get it to work. So I purchased a Logitech c270 the other day. Now this one won't work. I have seen numerous statements that it "works out of the box" with Slack which means it must be using SN9C102. I am running 13.37 with Xfce window manager. I read that this command would find if all was well:
mplayer -v tv:// -tv device=/dev/video0:driver=v4l2
I use mplayer to display DVDs etc. So mplayer is working. In the listing below for this command there are several defaults taken and the codec for -vo (which is not specified) seems none the less to be unable video format.
Code:
MPlayer 20101218-4.5.1 (C) 2000-2010 MPlayer Team
CPU vendor name: AuthenticAMD  max cpuid level: 1
CPU: AMD Athlon(tm) XP 2200+ (Family: 6, Model: 8, Stepping: 0)
extended cpuid-level: 8
extended cache-info: 16810304
Detected cache-line size is 64 bytes
Testing OS support for SSE... yes.
Tests of OS support for SSE passed.
CPUflags:  MMX: 1 MMX2: 1 3DNow: 1 3DNowExt: 1 SSE: 1 SSE2: 0 SSSE3: 0
Compiled with runtime CPU detection.
get_path('codecs.conf') -> '/home/auser/.mplayer/codecs.conf'
Reading /home/auser/.mplayer/codecs.conf: Can't open '/home/auser/.mplayer/codecs.conf': No such file or directory
Reading /etc/mplayer/codecs.conf: Can't open '/etc/mplayer/codecs.conf': No such file or directory
Using built-in default codecs.conf.
init_freetype
Using MMX (with tiny bit MMX2) Optimized OnScreenDisplay
get_path('fonts') -> '/home/auser/.mplayer/fonts'
Configuration: --prefix=/usr --mandir=/usr/man --confdir=/etc/mplayer --enable-gui --enable-menu --enable-largefiles --disable-arts --codecsdir=/usr/lib/codecs --language=en nl fr de es --enable-runtime-cpudetection --disable-libdvdcss-internal --disable-mp3lame --disable-mp3lame-lavc --disable-faac --disable-faac-lavc --disable-libopencore_amrnb --disable-libopencore_amrwb
CommandLine: '-v' 'tv://' '-tv' 'device=/dev/video0:driver=v4l2'
Using nanosleep() timing
get_path('input.conf') -> '/home/auser/.mplayer/input.conf'
Can't open input config file /home/auser/.mplayer/input.conf: No such file or directory
Can't open input config file /etc/mplayer/input.conf: No such file or directory
Falling back on default (hardcoded) input config
get_path('.conf') -> '/home/auser/.mplayer/.conf'

Playing tv://.
get_path('sub/') -> '/home/auser/.mplayer/sub/'
STREAM: [tv] tv://
STREAM: Description: TV Input
STREAM: Author: Benjamin Zores, Albeu
STREAM: Comment: 
TV file format detected.
Selected driver: v4l2
 name: Video 4 Linux 2 input
 author: Martin Olschewski <olschewski@zpr.uni-koeln.de>
 comment: first try, more to come ;-)
v4l2: your device driver does not support VIDIOC_G_STD ioctl, VIDIOC_G_PARM was used instead.
Selected device: SN9C1xx PC Camera
 Capabilities:  video capture  read/write  streaming
 supported norms:
 inputs: 0 = Camera;
 Current input: 0
 Format unknown (0x31384142) ( 0 bits, bayer rgb): Unknown 0x31384142
 Format unknown (0x4745504a) ( 0 bits, JPEG): Unknown 0x4745504a
 Current format: unknown (0x31384142)
v4l2: set format: YVU420
v4l2: set input: 0
tv.c: norm_from_string(pal): Bogus norm parameter, setting default.
Selected norm : pal
v4l2: ioctl enum norm failed: Invalid argument
Error: Cannot set norm!
Selected input hasn't got a tuner!
==> Found video stream: 0
v4l2: get format: unknown (0x31384142)
v4l2: Cannot get fps
v4l2: get width: 640
v4l2: get height: 480
Using a ring buffer for maximum 2 frames, 0 MB total size.
v4l2: ioctl set mute failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
[V] filefmt:9  fourcc:0x31384142  size:640x480  fps:25.000  ftime:=0.0400
get_path('sub/') -> '/home/auser/.mplayer/sub/'
v4l2: going to capture
X11 opening display: :0.0
vo: X11 color mask:  FFFFFF  (R:FF0000 G:FF00 B:FF)
vo: X11 running at 800x600 with depth 24 and 32 bpp (":0.0" => local display)
[x11] Detected wm supports layers.
[x11] Using workaround for Metacity bugs.
[x11] Detected wm supports NetWM.
[x11] Detected wm supports ABOVE state.
[x11] Detected wm supports BELOW state.
[x11] Detected wm supports FULLSCREEN state.
[x11] Current fstype setting honours FULLSCREEN ABOVE BELOW X atoms
[VO_XV] Using Xv Adapter #0 (NV Video Blitter)
[xv common] Drawing no colorkey.
[xv common] Maximum source image dimensions: 2046x2046
==========================================================================
Cannot find codec matching selected -vo and video format 0x31384142.
==========================================================================

v4l2: select timeout
v4l2: ioctl set mute failed: Invalid argument
v4l2: 0 frames successfully processed, 1 frames dropped.
v4l2: up to 0 video frames buffered.
vo: uninit ...

Exiting... (End of file)
Please help! I have spent so much time trying to get any webcam to work.
 
Old 07-26-2013, 06:04 PM   #2
guanx
Senior Member
 
Registered: Dec 2008
Posts: 1,014

Rep: Reputation: 146Reputation: 146
Can you try a more recent MPlayer version ( e.g. MPlayer-1.1.1 )?
 
Old 07-27-2013, 01:59 AM   #3
waddles
Member
 
Registered: Sep 2012
Posts: 373

Original Poster
Rep: Reputation: 0
That is a possibility but since others have made the c270 work "out of the box" I see no justification. I may try using cheese first.

Correction: cheese is not working under xfce as I see when I went to check. Apparently it takes a picture(s) then locks up but not so under Gnome.

Last edited by waddles; 07-27-2013 at 02:12 AM.
 
Old 07-27-2013, 02:43 AM   #4
willysr
Senior Member
 
Registered: Jul 2004
Location: Jogja, Indonesia
Distribution: Slackware-Current
Posts: 2,577

Rep: Reputation: 431Reputation: 431Reputation: 431Reputation: 431Reputation: 431
try using guvcview to test out your webcam under linux
 
1 members found this post helpful.
Old 07-27-2013, 03:11 AM   #5
waddles
Member
 
Registered: Sep 2012
Posts: 373

Original Poster
Rep: Reputation: 0
Thnx willysr. I had seen guvcview referenced and will do.
I had considered uvc driver as it specifically supports the c270 but appears to be a pain to install and fiddle with. Will let U know how it goes.
 
Old 07-27-2013, 03:46 AM   #6
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
The Microdia camera is supported by the:
http://mxhaard.free.fr/spca5xx.html
drivers.
The Logitech by the:
http://www.ideasonboard.org/uvc/
drivers.

The uvc driver is by far the easiest to install and use. I use it for all my webcams and it works perfectly. I don't use the gspca drivers, because I don't have old webcams.
 
Old 07-27-2013, 05:12 AM   #7
waddles
Member
 
Registered: Sep 2012
Posts: 373

Original Poster
Rep: Reputation: 0
Good info!! for Microdia. Please explain if U can why I had been told the driver was sn9c105 but was included in sn9c102 but the former is a bridge (what does that mean?) and the latter is a driver pulled down via modprobe. Where does one get a driver like spca5xx/LE?
U say the uvc driver is easy to download and install. Can U elaborate more (what/where) or point me to where that is described? My reading (UR uvc reference) of it made it seem way convoluted, maybe its too much info. Also I noted that it does not support single pictures.
Is the uvc driver needed for the guvcview program? It would seem so.
I am having a H... of a time trying to download guvcview cuz it always finishes with a low byte count. The action of getting the download (SourceForge) is also questionable as it repeatedly asks for a download, sometimes after I OK the confirmation response. That causes multiple images too, all short.

Last edited by waddles; 07-27-2013 at 05:19 AM.
 
Old 07-27-2013, 05:43 AM   #8
willysr
Senior Member
 
Registered: Jul 2004
Location: Jogja, Indonesia
Distribution: Slackware-Current
Posts: 2,577

Rep: Reputation: 431Reputation: 431Reputation: 431Reputation: 431Reputation: 431
probably you are using a slow mirror. You might change to another mirror
 
Old 07-27-2013, 06:34 AM   #9
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
You can build uvc within the kernel itself. guvcview does require uvc.
 
1 members found this post helpful.
Old 07-27-2013, 07:10 AM   #10
kkady32
Member
 
Registered: Dec 2010
Distribution: Slackware64
Posts: 86

Rep: Reputation: 14
i have a uvc webcam and mplayer (in current) work for me with this command:
Code:
mplayer tv:// -tv driver=v4l2 :width=352:height=288:device=/dev/video0
 
1 members found this post helpful.
Old 07-28-2013, 04:13 PM   #11
waddles
Member
 
Registered: Sep 2012
Posts: 373

Original Poster
Rep: Reputation: 0
For Willysr: tried US, Canadian, and direct with much the same result.
Will try again later.
The mplayer command cannot have a space after v4l2 but with that removed I got this:
Code:
Playing tv://.
TV file format detected.
Selected driver: v4l2
 name: Video 4 Linux 2 input
 author: Martin Olschewski <olschewski@zpr.uni-koeln.de>
 comment: first try, more to come ;-)
v4l2: your device driver does not support VIDIOC_G_STD ioctl, VIDIOC_G_PARM was used instead.
Selected device: SN9C1xx PC Camera
 Capabilities:  video capture  read/write  streaming
 supported norms:
 inputs: 0 = Camera;
 Current input: 0
 Current format: unknown (0x31384142)
tv.c: norm_from_string(pal): Bogus norm parameter, setting default.
v4l2: ioctl enum norm failed: Invalid argument
Error: Cannot set norm!
Selected input hasn't got a tuner!
v4l2: Cannot get fps
v4l2: ioctl set mute failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
==========================================================================
Cannot find codec matching selected -vo and video format 0x31384142.
==========================================================================

v4l2: select timeout
v4l2: ioctl set mute failed: Invalid argument
v4l2: 0 frames successfully processed, 1 frames dropped.

Exiting... (End of file)
Does anyone see what is wrong on my system then?
 
Old 07-29-2013, 01:54 AM   #12
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
Try using the v4l driver instead of v4l2. You can also try Alien Bob's gspca package:
http://www.slackware.com/~alien/slackbuilds/gspcav1/
 
1 members found this post helpful.
Old 07-29-2013, 10:55 AM   #13
number22
Member
 
Registered: Sep 2006
Location: Earth
Distribution: Slackware 14.1 Slackware64-current multilib
Posts: 189
Blog Entries: 1

Rep: Reputation: Disabled
check your files: go to your /usr/lib/libv4l directory (32 bit) or /usr/lib64/libv4l/ looking for v4l2convert.so (part of v4l-utils package).

add LD_PRELOAD before your mplayer command, example:
Code:
LD_PRELOAD=/usr/lib64/libv4l/v4l2convert.so mplayer tv:// -tv driver=v4l2:device=/dev/video0

Last edited by number22; 07-29-2013 at 11:35 AM.
 
Old 07-30-2013, 12:47 AM   #14
waddles
Member
 
Registered: Sep 2012
Posts: 373

Original Poster
Rep: Reputation: 0
Number 22 tried the command U suggested. Still nothing affirmative. Output follows:
Code:
Playing tv://.
TV file format detected.
Selected driver: v4l2
 name: Video 4 Linux 2 input
 author: Martin Olschewski <olschewski@zpr.uni-koeln.de>
 comment: first try, more to come ;-)
v4l2: your device driver does not support VIDIOC_G_STD ioctl, VIDIOC_G_PARM was used instead.
Selected device: SN9C1xx PC Camera
 Capabilities:  video capture  read/write  streaming
 supported norms:
 inputs: 0 = Camera;
 Current input: 0
 Current format: unknown (0x31384142)
tv.c: norm_from_string(pal): Bogus norm parameter, setting default.
v4l2: ioctl enum norm failed: Invalid argument
Error: Cannot set norm!
Selected input hasn't got a tuner!
v4l2: Cannot get fps
v4l2: ioctl set mute failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
v4l2: ioctl query control failed: Invalid argument
==========================================================================
Cannot find codec matching selected -vo and video format 0x31384142.
==========================================================================

v4l2: select timeout
v4l2: ioctl set mute failed: Invalid argument
v4l2: 0 frames successfully processed, 1 frames dropped.

Exiting... (End of file)
I have found that "Cannot find...video format 0x31384142." in almost every command I have tried. Any idea what it is telling me? I have forgotten where the codecs are stored I vaguely remember tracing codecs thinking I had somehow omitted them an the install but by recall I think I always found them.
H_TeXMeX_H, have tried the v4l before with no better/worse results. I believe the Microdia requires v4l2.
I have the following:/usr/src/linux-2.6.37.6/drivers/media/video/gspca
/usr/src/linux-2.6.37.6/include/config/usb/gspca
/lib/modules/2.6.37.6-smp/kernel/drivers/media/video/gspca
/lib/modules/2.6.37.6/kernel/drivers/media/video/gspca
I recall downloading them awhile back. Again, recall, but think that what I did to test was to remove the sn9c102 (at least) then mod-probed in the gspca and one other module which escapes me at the moment. Those tests were equally dismal.
From version 11.0 and/or 12.0 I had a horrible time until I discovered a way to force a change in device assignments. The BTTV stuff would grab the wrong device and the camera would fail. I cannot find in /proc where the devices are shown and maybe with 13.37 this is unnecessary. I thought I had found it once but cannot find my notes on it.
Have I messed up a dependency by not including the TeX in the install 2 yrs ago? I never use it and have not had a problem (that I knew of) by omitting it that I could not resolve that was attributable to it.
Is there a way to validate dependency omissions within Slackware? That would be a great little script. Or is there a list of dependencies?
When I tried tracking down the Microdia problem last time, my last thinking that there was a problem in the device assignments between it and bttv with video devices 1 & 2 being somehow switched but was not able to confirm it. FWIW
 
Old 07-30-2013, 01:13 AM   #15
textillis
Member
 
Registered: May 2013
Location: Northern Rivers, NSW, Australia
Distribution: Slackware64-current, Mint Nadya
Posts: 299

Rep: Reputation: 2
Quote:
Originally Posted by kkady32 View Post
i have a uvc webcam and mplayer (in current) work for me with this command:
Code:
mplayer tv:// -tv driver=v4l2 :width=352:height=288:device=/dev/video0
Would this code work if I were to try it with vlc rather than mplayer?
You see, I have the same problem as original poster but I have vlc installed with all codes, not so with mplayer.

Edit: I have a microsoft LifeCam3000. Your code works for me, just as it is; though it wasn't intended for me: i thank you anyway.
But i will still need a program with which to run it for skype and for taking snaps or for piping the video output to a recipient or to a recording file, no? I mean, as it is, the code you shared will get a basic screen with the cam running, but that is it: no menus, no options etc

Last edited by textillis; 07-30-2013 at 01:27 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
What else, webcams crazyx4 Linux - Hardware 8 10-15-2010 04:35 PM
Are your webcams working? (slackware 13.0) kris108 Slackware 9 09-14-2009 04:12 PM
Webcams? SlowCoder Linux - Hardware 5 09-05-2007 02:29 PM
Running two USB webcams/Linux compatible IR sensitive webcams doctorelectron Linux - Hardware 1 06-07-2006 08:30 AM
Firewire webcams not working on FC3 etothex Linux - General 1 09-08-2004 06:06 PM


All times are GMT -5. The time now is 10:45 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration