Fedora 11 - bt878 generic capture card setup problem

Forum for questions and support relating to the 1.24.x releases only.
Locked
kocur2k4
Posts: 3
Joined: Sun Aug 02, 2009 5:17 pm

Fedora 11 - bt878 generic capture card setup problem

Post by kocur2k4 »

Hi zoneminders ;)

I'm pulling my hair out.
I'm running ZM 1.24 installed via yum on FC11, followed these instructions:
http://linuxsoftwareblog.com/blog/?p=208

I have a Brooktree Corporation Bt878 Video Capture card that i can't get working.

I purchased the card on ebay:
http://cgi.ebay.ca/ws/eBayISAPI.dll?Vie ... 0344094185

I chose it as I am new to zoneminder and it seemed as a cheap 'will do' card as mentioned in the wiki here:
http://www.zoneminder.com/wiki/index.php/Pico2000

I can get it working in xawtv (i mean i get a picture)
(i don't understand how it runs on composite3 when it's loaded as video0)

Image

Here is my xawtv -hwscan

This is xawtv-3.95, running on Linux/i686 (2.6.29.6-213.fc11.i586)
looking for available devices
/dev/video0: OK [ -device /dev/video0 ]
type : v4l2
name : BT878 video (GrandTec Multi Cap
flags: overlay capture

/dev/video1: OK [ -device /dev/video1 ]
type : v4l2
name : USB Camera (046d:08da)
flags: capture

Here is my lspci:

00:00.0 Host bridge: Silicon Integrated Systems [SiS] 740 Host (rev 01)
00:01.0 PCI bridge: Silicon Integrated Systems [SiS] Virtual PCI-to-PCI bridge (AGP)
00:02.0 ISA bridge: Silicon Integrated Systems [SiS] SiS962 [MuTIOL Media IO] (rev 25)
00:02.1 SMBus: Silicon Integrated Systems [SiS] SiS961/2 SMBus Controller
00:02.5 IDE interface: Silicon Integrated Systems [SiS] 5513 [IDE]
00:02.7 Multimedia audio controller: Silicon Integrated Systems [SiS] AC'97 Sound Controller (rev a0)
00:03.0 USB Controller: Silicon Integrated Systems [SiS] USB 1.1 Controller (rev 0f)
00:03.1 USB Controller: Silicon Integrated Systems [SiS] USB 1.1 Controller (rev 0f)
00:03.3 USB Controller: Silicon Integrated Systems [SiS] USB 2.0 Controller
00:04.0 Ethernet controller: Silicon Integrated Systems [SiS] SiS900 PCI Fast Ethernet (rev 90)
00:09.0 Multimedia video controller: Brooktree Corporation Bt878 Video Capture (rev 11)
00:09.1 Multimedia controller: Brooktree Corporation Bt878 Audio Capture (rev 11)
01:00.0 VGA compatible controller: Silicon Integrated Systems [SiS] 65x/M650/740 PCI/AGP VGA Display Adapter

Here is my dmesg:

bttv: driver version 0.9.17 loaded
bttv: using 8 buffers with 2080k (520 pages) each for capture
intel8x0_measure_ac97_clock: measured 50775 usecs
intel8x0: clocking to 48000
bttv: Bt8xx card found (0).
ACPI: PCI Interrupt Link [LNKB] enabled at IRQ 11
bttv 0000:00:09.0: PCI INT A -> Link[LNKB] -> GSI 11 (level, low) -> IRQ 11
bttv0: Bt878 (rev 17) at 0000:00:09.0, irq: 11, latency: 64, mmio: 0xcfcfe000
bttv0: using: GrandTec Multi Capture Card (Bt878) [card=77,insmod option]
IRQ 11/bttv0: IRQF_DISABLED is not guaranteed on shared IRQs
bttv0: gpio: en=00000000, out=00000000 in=00f360ff [init]
bttv0: tuner absent
bttv0: the autoload option is obsolete.
bttv0: use option msp3400, tda7432 or tvaudio to
bttv0: override which audio module should be used.
bttv0: registered device video0
bttv0: registered device vbi0
bttv0: PLL: 28636363 => 35468950 .. ok

I added this in the modprobe.conf as other posts on the board suggested:
options bttv card=77 tuner=4 radio=0 triton1=0 vsfx=0 autoload=0 pll=1

Running modprobe bttv card=77 gives me this error:
WARNING: Deprecated config file /etc/modprobe.conf, all config files belong into /etc/modprobe.d/.

Running zmu -d /dev/video0 -q -v gives:

Video Capabilities
Name: BT878 video (GrandTec Multi Cap
Type: 45
Can capture
Does teletext
Overlay onto frame buffer
Can clip
Video Channels: 4
Audio Channels: 0
Maximum Width: 768
Maximum Height: 480
Minimum Width: 48
Minimum Height: 32
Window Attributes
X Offset: 0
Y Offset: 0
Width: 320
Height: 240
Picture Attributes
Palette: 1 - Linear greyscale
Colour Depth: 8
Brightness: 32768
Hue: 32768
Colour :32768
Contrast: 32768
Whiteness: 0
Channel 0 Attributes
Name: Composite0
Channel: 0
Flags: 0
Type: 2 - Camera
Format: 1 - NTSC
Channel 1 Attributes
Name: Composite1
Channel: 1
Flags: 0
Type: 2 - Camera
Format: 1 - NTSC
Channel 2 Attributes
Name: Composite2
Channel: 2
Flags: 0
Type: 2 - Camera
Format: 1 - NTSC
Channel 3 Attributes
Name: Composite3
Channel: 3
Flags: 0
Type: 2 - Camera
Format: 1 - NTSC


ZM screenshot:

Image


I don't know what else to do.
I'm sure lots of you have this card, please help.
Thanks in advance,
Kocur
User avatar
kingofkya
Posts: 1110
Joined: Mon Mar 26, 2007 6:07 am
Location: Las Vegas, Nevada

Post by kingofkya »

have you set shared memory yet see documentation in wiki

also check /var/logs/zm
kocur2k4
Posts: 3
Joined: Sun Aug 02, 2009 5:17 pm

Post by kocur2k4 »

Thanks for the tips kingofkya.
I fixed the shared memory issue and checked the logs.
I may need some help as I'm not sure what this means.
Thanks again for looking everyone!

ipcs -l

------ Shared Memory Limits --------
max number of segments = 4096
max seg size (kbytes) = 32768
max total shared memory (kbytes) = 134217728
min seg size (bytes) = 1

------ Semaphore Limits --------
max number of arrays = 128
max semaphores per array = 250
max semaphores system wide = 32000
max ops per semop call = 32
semaphore max value = 32767

------ Messages: Limits --------
max queues system wide = 933
max size of message (bytes) = 8192
default max size of queue (bytes) = 16384


/var/log/messages/

Aug 3 09:44:41 localhost zmc_dvideo0[4536]: INF [Debug Level = 0, Debug Log = <none>]
Aug 3 09:44:41 localhost zmc_dvideo0[4536]: INF [Starting Capture]
Aug 3 09:44:41 localhost zmc_dvideo0[4536]: ERR [Capture failure for frame 0: Device or resource busy]
Aug 3 09:44:41 localhost zmc_dvideo0[4536]: ERR [Failed to prime capture of initial monitor]
Aug 3 09:44:41 localhost zmdc[4510]: ERR ['zmc -d /dev/video0' exited abnormally, exit status 255]
Aug 3 09:44:42 localhost zmdc[4539]: INF ['zmfilter.pl' started at 09/08/03 09:44:42]
Aug 3 09:44:42 localhost zmdc[4510]: INF ['zmfilter.pl' starting at 09/08/03 09:44:42, pid = 4539]
Aug 3 09:44:43 localhost zmdc[4543]: INF ['zmaudit.pl -c' started at 09/08/03 09:44:43]
Aug 3 09:44:43 localhost zmdc[4510]: INF ['zmaudit.pl -c' starting at 09/08/03 09:44:43, pid = 4543]
Aug 3 09:44:44 localhost zmfilter[4539]: INF [Scanning for events]
Aug 3 09:44:45 localhost zmdc[4548]: INF ['zmwatch.pl' started at 09/08/03 09:44:45]
Aug 3 09:44:45 localhost zmdc[4510]: INF ['zmwatch.pl' starting at 09/08/03 09:44:45, pid = 4548]
Aug 3 09:44:46 localhost zmdc[4510]: INF [Starting pending process, zmc -d /dev/video0]
Aug 3 09:44:46 localhost zmdc[4551]: INF ['zmc -d /dev/video0' started at 09/08/03 09:44:46]
Aug 3 09:44:46 localhost zmc_dvideo0[4551]: INF [Debug Level = 0, Debug Log = <none>]
Aug 3 09:44:46 localhost zmdc[4510]: INF ['zmc -d /dev/video0' starting at 09/08/03 09:44:46, pid = 4551]
Aug 3 09:44:46 localhost zmc_dvideo0[4551]: INF [Starting Capture]
Aug 3 09:44:46 localhost zmc_dvideo0[4551]: ERR [Capture failure for frame 0: Device or resource busy]
Aug 3 09:44:46 localhost zmc_dvideo0[4551]: ERR [Failed to prime capture of initial monitor]
Aug 3 09:44:46 localhost zmdc[4510]: ERR ['zmc -d /dev/video0' exited abnormally, exit status 255]
Aug 3 09:44:47 localhost zmwatch[4548]: INF [Watchdog starting]
Aug 3 09:44:47 localhost zmwatch[4548]: INF [Watchdog pausing for 30 seconds]
Aug 3 09:44:47 localhost zmdc[4555]: INF ['zmupdate.pl -c' started at 09/08/03 09:44:47]
Aug 3 09:44:47 localhost zmdc[4510]: INF ['zmupdate.pl -c' starting at 09/08/03 09:44:47, pid = 4555]
Aug 3 09:44:56 localhost zmdc[4510]: INF [Starting pending process, zmc -d /dev/video0]
Aug 3 09:44:56 localhost zmdc[4566]: INF ['zmc -d /dev/video0' started at 09/08/03 09:44:56]
Aug 3 09:44:56 localhost zmc_dvideo0[4566]: INF [Debug Level = 0, Debug Log = <none>]
Aug 3 09:44:56 localhost zmdc[4510]: INF ['zmc -d /dev/video0' starting at 09/08/03 09:44:56, pid = 4566]
Aug 3 09:44:56 localhost zmc_dvideo0[4566]: INF [Starting Capture]
Aug 3 09:44:56 localhost zmc_dvideo0[4566]: ERR [Capture failure for frame 0: Device or resource busy]
Aug 3 09:44:56 localhost zmc_dvideo0[4566]: ERR [Failed to prime capture of initial monitor]
Aug 3 09:44:56 localhost zmdc[4510]: ERR ['zmc -d /dev/video0' exited abnormally, exit status 255]
bhamilton
Posts: 8
Joined: Wed Feb 06, 2008 12:54 am

Post by bhamilton »

Hello Kocur,

I am of no help to your issue, but looks like you are close. I'd like to point out to anyone else reading this thread that adding:

options bttv card=77 tuner=4 radio=0 triton1=0 vsfx=0 autoload=0 pll=1

to my /etc/modprob.d/modprobe.conf fixed an issue on one of my zoneminder boxes that was driving me crazy. It has an old bt848 and a newer bt878 card in it. Sometimes things would work, sometimes they would not, adding that line to the modprobe.conf file has fixed my issues.

Kocur, I'm guessing you already tried your PCI cards in different slots and updated your BIOS, as this has helped resolve issues in the past for me.
Good luck.
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

kocur2k4 wrote: Aug 3 09:44:46 localhost zmc_dvideo0[4551]: ERR [Capture failure for frame 0: Device or resource busy]
Aug 3 09:44:46 localhost zmc_dvideo0[4551]: ERR [Failed to prime capture of initial monitor]
Aug 3 09:44:46 localhost zmdc[4510]: ERR ['zmc -d /dev/video0' exited abnormally, exit status 255]
This means that either another program is using the device or that ZM does not have permission to access it.
chenko
Posts: 25
Joined: Mon Jan 15, 2007 6:24 pm

Post by chenko »

Your dmesg is also showing "tuner absent", as there is no tuners on this board. set tuner=-1

Just card=77 tuner=-1 should suffice for this card.



Adding to the modprobe.conf is _Depricated_, it means your distro no longer uses this method.

Instead create a new file in /etc/modprobe.d/ called "bttv" and then add your options in there.

modprobe.conf will automatically load everything from /etc/modprobe.d/


Assuming you are using it as a module of course (check in lsmod), if not it is compiled in the kernel and requires what I recently found out http://www.zoneminder.com/forums/viewtopic.php?t=14204
gola10
Posts: 150
Joined: Wed Nov 01, 2006 3:16 pm
Location: Panama

Post by gola10 »

It looks like your card is a Pico2000. I have a few of them working with zoneminder under mandriva.
Take a look at this address where you will find how to set it
http://www.zoneminder.com/wiki/index.php/Pico2000
It has seen it coexist thit others cards too.
jjleprikon
Posts: 13
Joined: Sat Sep 02, 2006 8:54 pm
Location: CA, USA

Post by jjleprikon »

Was there ever a resolution to this? I'm in the same situation. I have a generic 8 channel card that is working great under Cordel's Fedora distribution. I wanted to upgrade the box to Fedora 11 and zm 1.24.x.
The installation was a snap -gotta love that yum install command!- It seems the card is not being detected/installed/initialized/whatever when the OS boots.

lspci says in part:

Code: Select all

IEEE-1394a-2000 Controller (PHY/Link) (rev 01)
04:06.0 Non-VGA unclassified device: Hint Corp HiNT HB4 PCI-PCI Bridge (PCI6150) (rev 04)
05:08.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:08.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:09.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:09.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0a.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0a.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0b.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0b.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0c.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0c.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0d.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0d.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0e.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0e.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
05:0f.0 Non-VGA unclassified device: Brooktree Corporation Bt878 Video Capture (rev 11)
05:0f.1 Unclassified device [0080]: Brooktree Corporation Bt878 Audio Capture (rev 11)
dmesg says in part:

Code: Select all

i2c-adapter i2c-0: nForce2 SMBus adapter at 0x1c00
i2c-adapter i2c-1: nForce2 SMBus adapter at 0x1c40
Linux video capture interface: v2.00
bttv: driver version 0.9.18 loaded
bttv: using 8 buffers with 2080k (520 pages) each for capture
bttv: Bt8xx card found (0).
bttv 0000:05:08.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:08.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:09.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:09.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0a.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0a.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0b.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0b.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0c.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0c.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0d.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0d.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0e.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0e.0 failed with error -5
bttv: Bt8xx card found (0).
bttv 0000:05:0f.0: device not available because of BAR 0 [0x000000-0x000fff] collisions
bttv0: Can't enable device.
bttv: probe of 0000:05:0f.0 failed with error -5
firewire_core: created device fw0: GUID 0000000000000001, S400
ata3: SATA link down (SStatus 0 SControl 300)
ata4: SATA link down (SStatus 0 SControl 300)
ACPI: PCI Interrupt Link [APCJ] enabled at IRQ 23
Intel ICH 0000:00:10.2: PCI INT C -> Link[APCJ] -> GSI 23 (level, low) -> IRQ 23
Intel ICH 0000:00:10.2: setting latency timer to 64
intel8x0_measure_ac97_clock: measured 50697 usecs (2496 samples)
intel8x0: clocking to 46797
end_request: I/O error, dev fd0, sector 0
end_request: I/O error, dev fd0, sector 0

I remember adding options to a file, I'm guessing it was the modprobe.conf file. I'll try this advice
Instead create a new file in /etc/modprobe.d/ called "bttv" and then add your options in there.
lsmod has an entry that says bttv

Code: Select all

ac97_bus               1416  1 snd_ac97_codec
bttv                 106592  0 
ir_common             41312  1 bttv
v4l2_common           12312  1 bttv
videodev           29620  2 bttv,v4l2_common
v4l1_compat           12056  1 videodev
snd_pcm               63236  2 snd_intel8x0,snd_ac97_codec
videobuf_dma_sg       10340  1 bttv
videobuf_core         13944 2 bttv,videobuf_dma_sg
btcx_risc              3908  1 bttv
tveeprom              10732  1 bttv
snd_timer             17760  1 snd_pcm
snd                   50292  8
So I guess that means its loaded as a module?
Locked