capturing video with Avermedia a827 usb hybrid TV

hello.
I just got one Avermedia AverTV Hybrid Volar HX A827 Usb card
http://www.avermedia.com/avertv/Product-…-spx?Id=293
with great official linux drivers
http://www.avermedia.com/avertv/Product-…-b=APDriver
so I install it and work perfectly, I can see the tv using Kaffeine for example.
I am using ubuntu 9.04 by the way.
I have the device listed in /dev/video1
and the dmesg when I plug it is:
[ 4232.850911] usb 1-3: USB disconnect, address 2
[ 4372.424079] usb 1-3: new high speed USB device using ehci_hcd and address 4
[ 4373.109674] usb 1-3: configuration #1 chosen from 1 choice
[ 4373.455420] A827 registered V4L2 device video1[video]
[ 4373.455456] A827 registered V4L2 device vbi2[vbi]
[ 4373.455486] A827 registered V4L2 device radio3[radio]
[ 4373.455835] A827 registered ALSA sound card 1
[ 4373.455844] DVB: registering new adapter (A827[0] DVB-T)
[ 4373.455847] A827[0] DVB-T registered DVB adapter 0
[ 4373.457303] DVB: registering adapter 0 frontend 0 (A827[0] DVB-T)…

When I run the movieGrabberexample with 720x576 and ofSetLogLevel(OF_LOG_VERBOSE) activate I got this output:
enumerate: 8000000
Total count method 1: 1
Total count method 2: 0
OF_NOTICE: ofUCUtils: Using device /dev/video1
OF_NOTICE: ofUCUtils: Using module v4l2
OF_NOTICE: choosing device 0: AVerMedia A827 USB (USB)
OF_NOTICE: ofUCUtils : Available formats for this device:
OF_NOTICE: ofUCUtils : 0: 4:2:2, packed, YUYV ( YUYV ), min size: 720x576, max size:720x576, default size: 640x480
OF_VERBOSE: ofUCUtils: available sizes for this format:
OF_VERBOSE: 720x576
OF_NOTICE: ofUCUtils : 1: 4:2:2, packed, UYVY ( UYVY ), min size: 720x576, max size:720x576, default size: 640x480
OF_VERBOSE: ofUCUtils: available sizes for this format:
OF_VERBOSE: 720x576
OF_NOTICE: ofUCUtils : Selected format: 4:2:2, packed, YUYV ( YUYV ), with size 720x576

OF_NOTICE: ofUCUtils: Converting to RGB24 (720,576)

the problem is that I can only see a back screen… not image.

I would like to see a tv channel inside my OF application and also the video from the analogue input. Do anyone have an idea of how to configure it?

regards
diego diaz

hey diego

can you try if it works in ucview?

hi arturo
yes it works now!!! thanks

what I did is install the ucview and select adjustments/source/compotite. so I can see inside ucview my rca video input image. I close the ucview and the configuration is been saved because I open the OF and I can see the video imagen inside my programme.

the direct tv is still black I think because I have to select the tv channel to get the image…
I will look later how I can do it.

thanks again diego

hi all

i just know how to control the input source of the avermedia USB stick.

I have to include
#include <sys/ioctl.h>
#include <linux/videodev.h>

and I add this lines in
void testApp::setup(){
v4l2_std_id VDOStd[]={V4L2_STD_PAL_B, V4L2_STD_NTSC_M, V4L2_STD_PAL_D, V4L2_STD_PAL_I};
char Std[][10]={{“PAL B”},{“NTSC M”},{“PAL D”},{“PAL I”}};

int fd=0,i;
int input=1;
printf(“Please wait about 10 seconds for device init.\n\n”);
fd = open("/dev/video0", O_RDWR);
if(fd < 0) {
printf(“Fatal Error!! There is no /dev/video0 exists.\n”);
}
printf(“Set Input\t: Composite\n”);
ioctl(fd, VIDIOC_S_INPUT, &input); // set input
printf(“Set Standard\t: %s\n”,Std[0]);
ioctl(fd, VIDIOC_S_STD, &VDOStd[0]); // set standard

but now I have a rare linux problem…
the Ucview doesnt detect my usb card if it is name with /dev/video0
it only works if I plug another camera before and avermedia got /dev/video1
does anybody now way? any suggestion?

thanks
diego

I have an idea about the problem
I think is a file permission:
here was not working
crw-rw---- 1 root video 81, 1 2009-06-22 18:31 /dev/video0
and here is working
crw-rw----+ 1 root video 81, 0 2009-06-22 18:31 /dev/video0

but how to change it automatically?

hi
I found the solution
I add permission to the user for run web cam
administration/Users Settings->user privileges
I select the
Capture video from TV or Webcams, and use 3d acceleration

just in case somebody have the same problem