--- Quote Start ---
originally posted by dms2002711@Aug 17 2006, 10:47 PM
hi,hippo
do you know the possible reasons of the following phenomenon:
(a uclinux system had trasplanted into the board de2 successful,and the usb camera can work)
i was programming for grabbling picture via video4liux api which was used for usb camer.
i can obtain the camera and the picture information using ioctl() function:
fd=open("dev/v4l/video0",o_rdwr);
...........
int cap=ioctl(fd,vidiocgcap,& capability);
..........
int pic=ioctl(fd,vidiocgpict,& picture);
return value:
fd=3;
cap=0;
pic=0;
above code could work ,and the correct information was obtained.
but when used the following code ,a problem was generated
struct video_mbuf mbuf;
...........
struct video_mmap grab_buf;
grab_buf.frame=0;
grab_buf.height=240;
grab_buf.width=320;
grab_buf.format=video_palette_rgb24;
char *data;
data=mmap(0,mbuf.size,prot_read|prot_write,map_shared,fd,0);
..................
int grab=ioctl(fd,vidiocmcapture,&grab_buf);
.................
int sync=ioctl(fd,vidiocsync,& grab_buf.frame);
.............
the return value:
data=-1
grab=-1;
sync=-1
that's to say ,the process of grabbing a frame_picture work failed!
do you know the possible reasons!
the isp1362 driver did not suppot the isochronous ,i have modified the parameter of the isp1362 driver,now, there wasn't the note:isochronous transfer not supportec.
look forward to you reply! thank you !
<div align='right'><{post_snapback}> (index.php?act=findpost&pid=17693)
--- quote end ---
--- Quote End ---
What is errno for each of your errors? Knowing this will, at least, tell you what's failing in each of your commands, which is a pretty good place to start.
Cheers,
- slacker