Page 1 of 1

2.56 fps <-- Why? (semi solved)

Posted: Tue Oct 06, 2009 5:25 pm
by quietas
Hardware:
Dell Studio Minitower
Intel Quad 8200
8gb RAM
2x 1 TB hard drives
PV-981 PCI-E card
Ubuntu 9.04 server (headless)

I have four identical systems set up with one of them having 2 cards for 16 cameras (the other 3 with 8 cams). The load is minimal, the computer, Ubuntu, and Zoneminder work great.

My only problem currently seems to be that they will only record at 2.56 fps. Any idea why?

I set up the first one about two months ago, and I just set up the other 3 this morning. I see the same 2.56 fps on all 4. The PV-981 is 120 fps, 4 chips, 2 channels per chip.

120 / 4 / 2 = 15 fps if I understand correctly. Am I wrong? If not, what should I look for and how should I configure ZM or Ubuntu?

Posted: Tue Oct 06, 2009 6:27 pm
by kingofkya
weird what do the logs say

also did you set the shared memory because that is a lot of cameras for the default

Posted: Tue Oct 06, 2009 6:34 pm
by DREMA
Also, do you have the correct settings for your cards?

Posted: Tue Oct 06, 2009 8:44 pm
by quietas
I configured it with the --enable-mmap=yes settings rather than the shared memory settings. Could this be throwing things for a loop?

It's odd though, because it effects the systems with 1 card and 8 cameras, or the 1 other with 2 cards and 16 cameras. All 4 systems are 2.56 fps, I assume I have the wrong settings for the card, but where should I look?

Posted: Tue Oct 06, 2009 9:07 pm
by quietas
OK, I found part of it. The CAPTURES_PER_FRAME was at 2. I changed it to 1 and now I am getting double the framerate at 5.12 fps

Posted: Tue Oct 06, 2009 9:07 pm
by timcraig
It's a common misconception people have that they will get
"camera fps" = "capture chip fps" / "# of cameras on chip". To make matters worse, some manufactures and some vendors advertise this.

The truth is there is a lag when a capture chip on a card changes ports. This lag cuts down on the fps you can get when you have more than one camera on a capture chip.

~2.5 fps is the frame rate I get on my pv-155 with 2 cameras on each chip. If I change "CAPTURES_PER_FRAME" from 2 to 1, I'll get 5 fps per frame but with visual artifacts.

Posted: Tue Oct 06, 2009 9:20 pm
by quietas
That's the same thing I ran into and the reason I had adjusted it to 2 captures per frame. I guess this is just a limitation of the hardware, but so freaking poorly advertised. If I had known this I would have bought 8 chip cards.

So it seems a card with two cams per chip will instead of reducing the fps by 1/2, it will actually be reduced to 1/6th with captures at 1, and 1/12 at 2.

I guess I'll live with 2.5fps or 5 if it does not artifact on me.

Posted: Tue Oct 06, 2009 9:33 pm
by quietas
DREMA wrote:Also, do you have the correct settings for your cards?
I had forgot to mention that I did not bother setting the modprobe.d/options since the card was being detected correctly. At least I think it is.

Code: Select all

quietas@zone:~$ dmesg |grep bttv
[    7.005717] bttv: driver version 0.9.17 loaded
[    7.005719] bttv: using 8 buffers with 2080k (520 pages) each for capture
[    7.005763] bttv: Bt8xx card found (0).
[    7.005779] bttv 0000:02:00.0: PCI INT A -> GSI 16 (level, low) -> IRQ 16
[    7.005792] bttv0: Bt878 (rev 17) at 0000:02:00.0, irq: 16, latency: 64, mmio: 0xfdeff000
[    7.006343] bttv0: detected: Provideo PV150A-1 [card=98], PCI subsystem ID is aa00:1460
[    7.006346] bttv0: using: ProVideo PV150 [card=98,autodetected]
[    7.006380] bttv0: gpio: en=00000000, out=00000000 in=00ffffff [init]
[    7.006440] bttv0: tuner absent
[    7.006480] bttv0: registered device video0
[    7.006497] bttv0: registered device vbi0
[    7.006524] bttv0: PLL: 28636363 => 35468950 .. ok
[    7.050053] bttv: Bt8xx card found (1).
[    7.050068] bttv 0000:02:01.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
[    7.050080] bttv1: Bt878 (rev 17) at 0000:02:01.0, irq: 17, latency: 64, mmio: 0xfdefd000
[    7.050120] bttv1: detected: Provideo PV150A-2 [card=98], PCI subsystem ID is aa01:1461
[    7.050123] bttv1: using: ProVideo PV150 [card=98,autodetected]
[    7.050157] bttv1: gpio: en=00000000, out=00000000 in=00ffffff [init]
[    7.050207] bttv1: tuner absent
[    7.050250] bttv1: registered device video1
[    7.050270] bttv1: registered device vbi1
[    7.050296] bttv1: PLL: 28636363 => 35468950 .. ok
[    7.090038] bttv: Bt8xx card found (2).
[    7.090053] bttv 0000:02:02.0: PCI INT A -> GSI 18 (level, low) -> IRQ 18
[    7.090065] bttv2: Bt878 (rev 17) at 0000:02:02.0, irq: 18, latency: 64, mmio: 0xfdefb000
[    7.090089] bttv2: detected: Provideo PV150A-3 [card=98], PCI subsystem ID is aa02:1462
[    7.090091] bttv2: using: ProVideo PV150 [card=98,autodetected]
[    7.090116] bttv2: gpio: en=00000000, out=00000000 in=00ffffff [init]
[    7.090163] bttv2: tuner absent
[    7.090214] bttv2: registered device video2
[    7.090234] bttv2: registered device vbi2
[    7.090262] bttv2: PLL: 28636363 => 35468950 .. ok
[    7.130044] bttv: Bt8xx card found (3).
[    7.130059] bttv 0000:02:03.0: PCI INT A -> GSI 19 (level, low) -> IRQ 19
[    7.130071] bttv3: Bt878 (rev 17) at 0000:02:03.0, irq: 19, latency: 64, mmio: 0xfdef9000
[    7.130095] bttv3: detected: Provideo PV150A-4 [card=98], PCI subsystem ID is aa03:1463
[    7.130098] bttv3: using: ProVideo PV150 [card=98,autodetected]
[    7.130133] bttv3: gpio: en=00000000, out=00000000 in=00ffffff [init]
[    7.130181] bttv3: tuner absent
[    7.130235] bttv3: registered device video3
[    7.130252] bttv3: registered device vbi3
[    7.130278] bttv3: PLL: 28636363 => 35468950 .. ok
[64453.822661] bttv0: PLL can sleep, using XTAL (28636363).
[64491.245636] bttv1: PLL can sleep, using XTAL (28636363).
[64530.801578] bttv2: PLL can sleep, using XTAL (28636363).
[64569.909602] bttv3: PLL can sleep, using XTAL (28636363).

Posted: Wed Oct 07, 2009 3:27 am
by whatboy
Image

Posted: Wed Oct 07, 2009 7:40 am
by cordel
There is a loss between switching ports on the chip as after the switch, the video signal has to resync, so figure loss of frame for each switch and another lost frame or two for it to sync.