Re: ohci DMA code.
Brought to you by:
aeb,
bencollins
From: Sebastien R. <Seb...@sy...> - 2000-06-08 22:50:00
|
>>>>> "Bart" == Bart Nabbe <ba...@cs...> writes: Bart> For those of you who are using the Ohci DMA code. Is there a way to Bart> determine if the frame in the dma buffer is valid? The DMA has a counter Bart> right, so if we have the number of bytes in one frame before a frame Bart> start we have a valid frame. I have some chopped frames one in a while, Bart> say 1/3 of the new frame and 2/3 the last frame that was on that Bart> position in the dma buffer. Bart> Are there also ideas about how multiple cameras should be handled is Bart> they are to be used with different applications? Bart> Any suggestions how to do any of this in a nice way? Currently, using /dev/ohci1394 for dma mapping, the frame interrupt is generated when the video buffer is full, and then the next video buffer starts filling up when an iso packet with the sync tag set is received. So your video frame buffer will always be full, wether or not data are lost. The way to see if a frame is good or not would be to check wether or not you discarded packets while waiting for the sync bit... I don't know if this is possible. Or maybe using timestamps of some kind. Or check wether two packets with the sync bits were inserted in the same frame... It is not on my priority list for the moment... but patch/suggestions are always welcome. -- Sebastien Rougeaux RSISE, The Australian National University |