BLIP2 Artifact Issue
Hello,
I have been working with the BLIP2 board in CCES, working my way through the FrameCapture_ClassDriver_ASX340 example, and I have encountered an issue when trying to write data to the sdram while the ASX340 sensor data stream is open. While attempting a memcpy of data from the captured frame buffer to another block of memory I have set aside in my sdram, I find that artifacts are appearing on the images in the new location. Attached is the example in which the image is memcpy-ed twice from the frame buffer, to a working buffer, then to a 2nd working buffer. In this particular example, the artifacts seem to only appear in the second data transfer, however in other instances I have tried, it has appeared in the first memcpy.
A few notes:
- The artifacts are somewhat inconsistent, they don't appear in every frame, however, they seem to appear in the same specific frames every time it's run.
- The artifacts appear when using other functions, such as the threshold function from the image processing toolbox.
- I tried writing an array of constants to one of the memory locations, the artifacts still appeared.
- There were no artifacts if I stopped the sensor data stream.
- Both the ASX340 and the OV7692 examples have this issue.
- No artifacts appear if the data is being copied/written to internal memory.
- I have taken out the file write operations out of the example to speed things up.
- Have attached both the .c and .h files I am using, plus the output images from the frame buffer, the first working buffer, and the second working buffer.
- Perhaps this could have something to do with timing misalignments in the DMA operations in the sensor driver?
Thanks,
Sean
sdram
bf70x
blip2
artifacts
asx340
blackfin
Show More
Hi vk3cwy,
I tried replacing your codes in the FrameCapture_ClassDriver_ASX340 project and could not seem to replicate the issue. You did mention that the artifacts occur in specific frames, did you notice any particular frame numbers where it occurs everytime?. That might be helpful. I ran the project adding your files and didn't spot this over the 27 frames it ran. It could be something related to caching so could you maybe zip your entire project and attach it and I ll try running that. Also which version of CCES are you running this on?
Thanks,
Neeraj
Thanks for taking the time to take a look at it.
I've uploaded a zip file of the whole project. I definitely get the artifacts in frames 23 to 27, and I also get them in frames 1 to 3 (In fact, in frame 1, I'm getting the noise in both of the destination buffers from the memcpy). I haven't gone through every single other frame, but in this version of the code, every time I've run it I've had the artifacts appear.
I also have access to a second BLIP2 board which I have tested it on, and got the same issue, so I'm fairly sure it isn't a faulty board.
I'm running CCES 2.1.0.0.
Thanks,
Sean
Hi Sean,
(a) It could also be that your buffers are in cacheable memory, and the SDRAM buffers to which the driver is writing is in non-cacheable memory and DMA is writing data into the buffer from the sensor. Hence, there is a cache synchronization issue. Hence, a cache flush/invalidate may solve the problem.
Hence you do not see the issue, when the copy happens to buffers in L1.
(b) The PPI peripheral is dropping pixels, because there is arbitration happening on the DDR bus, since the same bus is moving data from the sensor to the buffer and core is also moving data from the buffer to another buffer. The problem becomes more when another threshold function is running which also has core accessing the buffer through the DDR bus.
Hence, the symptoms are there but randomly happening.
Thanks,
Raka
This question has been assumed as answered either offline via email or with a multi-part answer. This question has now been closed out. If you have an inquiry related to this topic please post a new question in the applicable product forum.
Thank you,
EZ Admin
Please log in to reply.



