Strange problem with video format

Support and queries relating to all previous versions of ZoneMinder
Locked
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Strange problem with video format

Post by securstore »

Its strange...in xawtv all ok, but when i change to zoneminder, all black screen...and when i back to xawtv, same thing, black screen..

I must stay changing between pal/ntsc/auto and rgb's YUV's types of video, to try made it works...sometimes works...somes no...

When i finded out the correct settings, i reboot the computer and then when i access the zoneminder...its just back to black screen!

Its 4 ntsc cdd cameras on a bttv card...

By the way, one of them stayed black and white...is that because de capture card?

I have two errors during boot about world writable /etc/mysql/debian.cnf and world writable /etc/mysql/my.cnf beying ignored!


zmwatch log:

26-04-2009 00:03:48.535786 zmwatch[3362].INF [Watchdog starting]
26-04-2009 00:03:48.535949 zmwatch[3362].INF [Watchdog pausing for 30 seconds]
26-04-2009 00:13:08.889586 zmwatch[3362].INF [Restarting capture daemon for frente, time since last capture 10 seconds (1240704788-1240704778)]
26-04-2009 00:13:08.989932 zmwatch[3362].INF ['zmc -d /dev/video0' starting at 09/04/26 00:13:08, pid = 3895]

I really need help about it, because i dont know how fix this thing issue
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

its strange...if i uninstall zoneminder, cams back to work in xawtv....

otherwise, it does not work in xawtv or zoneminder...

Cams just work when i make a fresh install in zoneminder....if i reboot, nothing works...
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

Nobody can help me out?

:shock:
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

OK! I find the problem....

Is this one:

zmu -d /dev/video0 -q -v
Video Capabilities
Name: BT878 video (GrandTec Multi Cap
Type: 171
Can capture
Can tune
Overlay onto frame buffer
Can clip
Scalable
Video Channels: 4
Audio Channels: 0
Maximum Width: 924
Maximum Height: 576
Minimum Width: 48
Minimum Height: 32
Window Attributes
X Offset: 0
Y Offset: 0
Width: 640
Height: 480
Picture Attributes
Palette: 4 - 24bit RGB
Colour Depth: 24
Brightness: 32768
Hue: 32768
Colour :32768
Contrast: 32768
Whiteness: 0
Channel 0 Attributes
Name: Composite0
Channel: 0
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 1 Attributes
Name: Composite1
Channel: 1
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 2 Attributes
Name: Composite2
Channel: 2
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
Channel 3 Attributes
Name: Composite3
Channel: 3
Flags: 2
Channel has audio
Type: 2 - Camera
Format: 0 - PAL
supercharger:/home/supercharger#

See?? This is recognizing the video card like PAL.... ITS NTSC!

If i change to PAL in zoneminder, it works, but black-white and bad image...

If i change to NTSC, no deal!

How i fix it?

PS: i did this commands:

echo "kernel.shmmax = 268435456" >> /etc/sysctl.conf
echo "kernel.shmall = 268435456" >> /etc/sysctl.conf
echo 268435456 >/proc/sys/kernel/shmall
echo 268435456 >/proc/sys/kernel/shmmax

and after i did again the ./configure, but now with the --enable-mmap=yes option...

The camera works...until i reboot the system...

after reboot, no deal again...

supercharger:/home/supercharger# sysctl -p
kernel.shmall = 134217728
kernel.shmmax = 134217728
kernel.shmmax = 268435456
kernel.shmall = 268435456
kernel.shmmax = 35468950
kernel.shmall = 35468950
kernel.shmmax = 268435456
kernel.shmall = 268435456
kernel.shmall = 134217728
kernel.shmmax = 134217728
supercharger:/home/supercharger#

Please, i think now someone can help me!
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

Well...my final tip for someone help me:

1) I turn off zoneminder:

# /etc/init.d/zoneminder stop

2) i open xawtv:

# xawtv

3) i change PAL to NTSC in xawtv

4) I close xawtv and turn on again zoneminder:

#/etc/init.d/zoneminder start

5) And then THIS WORKS!

For Christ sake, someone can explain me whats going on?? How fix it to zoneminder works fine, without patchworks?
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

One of two things likely happening here.

Possibly you are using the wrong driver for the card.
It would display similar symptoms. ZM uses the image grab portion of the driver where xawtv just passes video to an overlay on the screen. You can simulate ZM in xawtv by trying to get a snapshot which does an image grab.

The other issue is that the recent kernels now uses V4L2 for the video driver and ZoneMinder has to use the V4L1 compatibility layer which don't seem to work right in certain kernels.
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

Kernel: 2.6.21-2-amd64
Really, Im using v4l2...
User avatar
cordel
Posts: 5210
Joined: Fri Mar 05, 2004 4:47 pm
Location: /USA/Washington/Seattle

Post by cordel »

I have no idea as I don't remember what version they made the change. What does the software say?
securstore
Posts: 9
Joined: Sun Apr 26, 2009 3:36 am

Post by securstore »

"You can simulate ZM in xawtv by trying to get a snapshot which does an image grab":

Works flawlessly! It doesnt matter if is in ntsc or pal...the snapshot works normal...

Hint: if i sart xawtv and close it, when i open it again, i must make the change from pal to NTSC again...

If i stop zone, start xawtv, set to ntsc and close it and start zone, zone works...and then if i stop zone and open xawtv, have to make the pal/ntsc stuff all again..

Conclusion:

1) it doesnt matter if the xawtv change are done after or before zone works...i allways have to set it again.

2) If changing pal/ntsc in xawtv works, why in zone dont?


zmdc.log:

04-05-2009 18:18:00.330394 zmdc[3337].INF [Server starting at 09/05/04 18:18:00]
04-05-2009 18:18:03.452091 zmdc[3337].INF ['zmc -d /dev/video0' starting at 09/05/04 18:18:03, pid = 3360]
04-05-2009 18:18:03.556282 zmdc[3337].INF ['zma -m 1' starting at 09/05/04 18:18:03, pid = 3364]
04-05-2009 18:18:03.658279 zmdc[3337].INF ['zmc -d /dev/video0' already running at 09/05/04 18:18:03, pid = 3360]
04-05-2009 18:18:03.762710 zmdc[3337].INF ['zma -m 7' starting at 09/05/04 18:18:03, pid = 3370]
04-05-2009 18:18:03.865067 zmdc[3337].INF ['zmc -d /dev/video0' already running at 09/05/04 18:18:03, pid = 3360]
04-05-2009 18:18:03.969672 zmdc[3337].INF ['zma -m 6' starting at 09/05/04 18:18:03, pid = 3376]
04-05-2009 18:18:04.075971 zmdc[3337].INF ['zmc -d /dev/video0' already running at 09/05/04 18:18:03, pid = 3360]
04-05-2009 18:18:04.180480 zmdc[3337].INF ['zma -m 5' starting at 09/05/04 18:18:04, pid = 3382]
04-05-2009 18:18:04.287444 zmdc[3337].INF ['zmfilter.pl' starting at 09/05/04 18:18:04, pid = 3386]
04-05-2009 18:18:04.392439 zmdc[3337].INF ['zmaudit.pl -c' starting at 09/05/04 18:18:04, pid = 3389]
04-05-2009 18:18:04.510319 zmdc[3337].INF ['zmwatch.pl' starting at 09/05/04 18:18:04, pid = 3392]
04-05-2009 18:18:04.620018 zmdc[3337].INF ['zmupdate.pl -c' starting at 09/05/04 18:18:04, pid = 3395]
04-05-2009 18:18:42.586012 zmdc[3337].INF ['zmaudit.pl -c' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.587006 zmdc[3337].INF ['zmaudit.pl -c' crashed, signal 14]
04-05-2009 18:18:42.587145 zmdc[3337].INF ['zma -m 5' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.588246 zmdc[3337].INF ['zma -m 5' exited normally]
04-05-2009 18:18:42.588394 zmdc[3337].INF ['zma -m 6' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.589361 zmdc[3337].INF ['zma -m 6' exited normally]
04-05-2009 18:18:42.589504 zmdc[3337].INF ['zma -m 7' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.590477 zmdc[3337].INF ['zma -m 7' exited normally]
04-05-2009 18:18:42.590609 zmdc[3337].INF ['zmfilter.pl ' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.591594 zmdc[3337].INF ['zmfilter.pl ' crashed, signal 14]
04-05-2009 18:18:42.591704 zmdc[3337].INF ['zmupdate.pl -c' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.592482 zmdc[3337].INF ['zmupdate.pl -c' crashed, signal 14]
04-05-2009 18:18:42.592595 zmdc[3337].INF ['zmc -d /dev/video0' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.599539 zmdc[3337].ERR ['zmc -d /dev/video0' exited abnormally, exit status 255]
04-05-2009 18:18:42.599671 zmdc[3337].INF ['zmwatch.pl ' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.600508 zmdc[3337].INF ['zmwatch.pl ' crashed, signal 14]
04-05-2009 18:18:42.600628 zmdc[3337].INF ['zma -m 1' stopping at 09/05/04 18:18:42]
04-05-2009 18:18:42.602654 zmdc[3337].INF ['zma -m 1' exited normally]
04-05-2009 18:18:52.688848 zmdc[3337].INF [Server shutdown at 09/05/04 18:18:52]


zmpkglog:

05/04/09 18:17:58.598342 zmpkg[3320].INF [Command: start]
04-05-2009 18:18:42.173015 zmpkg[3746].INF [Command: status]
04-05-2009 18:18:42.374310 zmpkg[3755].INF [Command: stop]


>> this is why i have to stop this to make xawtv works and set tho NTSC, then, restart zoneminder...

zwwatch.log:

04-05-2009 18:18:04.603109 zmwatch[3392].INF [Watchdog starting]
04-05-2009 18:18:04.603276 zmwatch[3392].INF [Watchdog pausing for 30 seconds]

zmfilter.log:

04-05-2009 18:18:04.915874 zmfilter[3386].INF [Scanning for events]

zmaudit and zmupdate are empty!
Locked