Re: Driver development with V4L2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Hello Manousaridis,

I want to develop drivers for a custom video board for a strongARM-linux based platform. This board has an MPEG2 decoder and a graphics processor. The incoming data stream will come from the network interface. This board uses LSI 64105 and Teralogic 751 (there is no PCI bus). I have found no drivers for them, so I have to develop the drivers myself.

Video4linux is probably the appropriate framework for such drivers.

It depends. If you have some sort of "video output" inside your computer (ie. your mpeg decoder stores the decoded frames in your system memory or the framebuffer of your system), then you could use the capture interface of Video4Linux-2 to get these frames to your application for further processing (for example: a motion detection algorithm)

But if your decoded mpeg2 data is going directly to an analog composite/s-video output (and there is no way for your processor to access the decoded mpeg data), probably the Linux DVB API is more suitable.

While searching for API info, I found the following sites:
Why are there 2 variants of v4l2?

http://www.video4linux.net/

This is completly outdated. Don't use that.

> http://www.thedirks.org/v4l2/

Bill Dirks developed the first draft of Video4Linux-2. The version that finally made it into the kernel differs in many ways. (This is noted on the top page)

Is the API described in 'http://bytesex.org/v4l/spec/' the one I am looking for?

Yes.

http://bytesex.org/v4l/

This is the latest resource for the Video4Linux-2 documentation (and includes a Driver-Writing-Guide, btw...)

I want to target linux 2.4.18, but also be able to port the drivers to more recent kernels (2.6), with minor modifications.

> If this is the case, can I use it in 2.4.18?

Kernels >= 2.4.20 include a new registration mechanism for Video4Linux devices. There, it's possible to painlessly mix Video4Linux-1 and Video4Linux-2 device drivers. (This wasn't able before, because Video4Linux-2 use the standard fops mechanism for registration, while the "old" Video4Linux-1 used a proprietary solution...)

> I found patches for more
> recent versions, but a kernel upgrade is not a trivial in my case,
> because of the arm-linux patches and the custom modifications for my
> platform.

It should be possible to backport the "videodev.c" module to 2.4.18 IMHO, if you really need 2.4.18.

But first think about if Video4Linux-2 is really the right choice for you.

Manousaridis Angelos

CU
Michael.




[Index of Archives]     [Linux DVB]     [Video Disk Recorder]     [Asterisk]     [Photo]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Free Photo Albums]     [Fedora Users]     [Fedora Women]     [ALSA Users]     [ALSA Devel]     [Linux USB]

Powered by Linux