This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Problems about DM365 VPFE process 5M pixel raw from ISIF(MT9P031)

Genius 3400 points

Hi All,

 Using the param "dm365_imp.oper_mode",  The Davinci Previewer module  can be configured to continue or single shot mode.

I also see the follow commentation in head file "dm365_ipipe.h".
 * VPFE hardware setup
 *
 * case 2: Capture to SDRAM with IPIPE Preview modules in Continuous  (On the Fly mode)
 *
 * Image sensor/       ________    ____________________
 * Yuv decoder    ---->| CCDC |--> | Previewer modules |--> SDRAM
 *                               |______|    |___________________|
 *
 * case 3: Capture to SDRAM with IPIPE Preview modules  & Resizer  in continuous (On the Fly mode)
 *
 * Image sensor/       ________    _____________   ___________
 * Yuv decoder    ---->| CCDC |--> | Previewer  |->| Resizer  |-> SDRAM
 *                               |______|    |____________|  |__________|
 *
 * case 4: Capture to SDRAM with IPIPE Resizer  in continuous (On the Fly mode)
 *
 * Image sensor/       ________    ___________
 * Yuv decoder    ---->| CCDC |--> | Resizer  |-> SDRAM
 *                               |______|    |__________|
 *
 * case 5: Read from SDRAM and do preview and/or Resize in Single shot mode
 *
 *                   _____________   ___________
 *    SDRAM   ----> | Previewer  |->| Resizer  |-> SDRAM
 *                           |____________|  |__________|
 *

     Now I'm working on a 5M pixel camera project, because of the limited of 2176 pixels per horizontal line in the DM365 VPFE. I had to  divide the raw data into 2 parts and pass them to the vpfe individually. 

     And using boot args "dm365_imp.oper_mode=0",  I modified the demo of "do_preview_resize.c" and have realized the conversion from 5M(2592x1944)  RAW to 5M YUV in Single shot mode.  At same time , using boot args "dm365_imp.oper_mode=1", I can capture 5M(2592x1944) RAW to SDRAM from sensor MT9P031 of LI-5M02 in continuous mode.

    I want to realize the working flow is: Caputre 5M RAW image data, split to 2 parts and convert to YUV format data  separately through Previewer, then  unite to 5M YUV on DDR2, and at last to encode to JPEG.

So I design the following flow:

 * case 6: Capture to SDRAM , Read from SDRAM and do preview and/or Resize in continuous mode
 *
 * Image sensor/      _________                   _____________   ___________
 * Yuv decoder    ---->| CCDC |-> SDRAM-> | Previewer  |->| Resizer  |-> SDRAM
 *                                  |_________|                 |____________|  |_____________|

 Is it can realize?  Can you give me more better advice?

What is the difference between the signal shot and continuous mode? 

Thanks!

Best regards; 

  • one-shot mode only processes one frame and it stops until driver restarts process so that next frame can be captured.  As you can imagine, you can only do this if frames are buffered in SDRAM since when data comes from ISIF, if you stop after one frame, you will start dropping data.  Therefore, one-shot vs continous mode only applies when data input is from SDRAM.

    That said, if you have your video frame in SDRAM but you have to split it into two parts (due to size) prior to processing, then you will need to use one-shot mode as you want to stop frame processing to change the memory pointer to the second half of the frame.  So long as moving the pointer and managing the enabling/disabling penalties invloved with one-shot mode do not exceed the vertical blanking time, you should be ok; otherwise, you may need to start buffering video frames...