A quick question , BF548 EPPI, in GP mode with frame and line syncs, does the frame sync on FS1 cause the buffer pointer to jump back to the start when asserted ? as on other BF PPIs
The assertion of frame sync signal FS1 or FS2 does not control buffer pointer. The buffer pointer depends only on the configuration of DMA. The FS1 and FS2 are only used by the PPI controller to stream in/out data from/to external devices. The DMA controller determines where in the memory the data is to be stored to or read from. Setup the DMA to be autobuffer mode and data size to be the length of data between two adjacent FS1, you can have the buffer pointer to point to "jump back to the start" on FS1.
I have a video streaming program working well currently in a chained loopback paradigm, but very occassionaly I lose some pixels, it is the 'auto reset ' of the buffer pointer on a new frame sync that I am querying. I think this happens in BF53X processor PPIs
Can you provide more details of the problem? Is it Tx or Rx? Are both FS used? External or internal FS? What do you mean by "lose some pixels"?
I use FS1, FS2 in GP RX mode, externally triggered by the image device. The reason I lose pixels is the data is coming in throughvia a deserialier over a long transmission distance and through low cost cabling. For a few different 'non' dsp reasons I lose lock on the deserialiser and this results in loss of clock recovery. This means that I do not get to fully fill the buffer before the actual end of the frame. A new frame starts and data seems to be written to end of the old buffer. I wish to recover the start of the image frame on each new image frame by auto resetting the buffer pointer on the assertion ( or deassertion) of the frame sync signal.
Now I understand the problem. You are actually losing clocks. PPI is not capable of recovering from lost clocks by itself. But it can detect this situation. The bits LINE_TRACKING_ERROR and FRAME_TRACKING_ERROR of the PPI status will be set if such problem happens. An interrupt can be triggered as a result. Then you may use the ISR to disable the PPI and re-sync the stream.
I had already thought of doing this ( EPPI restart), via polling the EPPI status register for line count errors. I was hoping that I would find a means of enabling a buffer pointer auto reset as the other BF53x devices do. I guess you are confirming that the EPPI DMA cant do this? If this is the only way of doing it it means a risk of dropped frames but we will have to live with that.
You are correct. PPI can not do it automatically or by itself. Extra software is needed to handle it. There could be dropped frame.
Retrieving data ...