xilinx VDMA IP核使用


                        VDMA實用配置說明

VDMA是通過AXI Stream協議對視頻數據在PSPL端進行搬運,開發者無需關注AXI Stream協議,在BlockDesign設計中只需要把相應信號進行連接即可。

VDMA配置有兩個選項

1   Basic

選擇地址位寬32bit 或者64bit

FrameBuffer 1~32可選,通常選擇3幀緩存;可避免圖像割裂;

 

2   Adanced

寫通道配置:

maxi_S2MM 是將stream流數據通過axi總線寫進memory

Fsync Options幀同步有三個選項nones2mm fsyncs2mm tuser

none被選擇后AXI VDMA處於free run模式,VDMA會盡可能快速的搬運數據,不受外部觸發信號所控制;

s2mm fsync被選擇VDMA檢測到s2mm fsync下降沿信號后開始搬運數據;

s2mm tuser被選擇VDMA檢測視頻幀起始信號(SOF)即AXI4-Stream下的s2mm tuser信號,檢測到信號拉高后開始搬運視頻數據;

GenLockMode有四個選項MasterSlaveDynamicMasterDynamicSlave

        MasterVDMAs2mm_frame_ptr_out端口輸出當前幀號;

        SlaveWhen selected, Slave follows the Master by the frames set in the Frame Delay registereither by skipping or repeating frames. The GenlockEn (S2MM_VDMACR[3]=1) registershould be set to enable genlock synchronization between the Master and Slave. Itoutputs the current frame number on the mm2s_frame_ptr_out port.

        DynamicMasterWhen selected, AXI VDMA skips the frame buffers that the Dynamic Slave is working on.
It outputs the completed frame number on the s2mm_frame_ptr_out port. GenlockEn (S2MM_VDMACR[3]=1) register should be set to enable genlock
synchronization between Dynamic Master and Dynamic Slave.

        DynamicSlaveWhen selected, AXI VDMA follows the Dynamic Master either by skipping or repeating frames. It outputs the current frame number on the s2mm_frame_ptr_out port. GenlockEn (S2MM_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

 

讀通道配置:

maxi_mm2s通道是將視頻數據通過axi總線從memory讀出;

maxis_mm2s 是將視頻數據轉成axis stream數據流形式;

Fsync Options幀同步有兩個選項nonemm2s fsync

none被選擇后AXI VDMA處於free run模式,VDMA會盡可能快速的搬運數據,不受外部觸發信號所控制;

注意在選擇none后通道會提供一個幀起始脈沖m_axis_mm2s_tuser(0)可用於下一級模塊downstream

mm2s fsync被選擇VDMA檢測到mm2s fsync下降沿信號后開始搬運數據;

GenLockMode有四個選項MasterSlaveDynamicMasterDynamicSlave

        MasterVDMAmm2s_frame_ptr_out端口輸出當前幀號;

        SlaveWhen selected, Slave follows the Master by the frames set in the Frame Delay registereither by skipping or repeating frames. The GenlockEn (MM2S_VDMACR[3]=1 registershould be set to enable genlock synchronization between the Master and Slave. Itoutputs the current frame number on the s2mm_frame_ptr_out.

        DynamicMasterWhen selected, AXI VDMA skips the frame buffers that the Dynamic Slave is working on.
It outputs the completed frame number on the mm2s_frame_ptr_out. GenlockEn (MM2S_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

        DynamicSlaveWhen selected, AXI VDMA follows the Dynamic Master either by skipping or repeating frames. It outputs the current frame number on the mm2s_frame_ptr_out . GenlockEn (MM2S_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

VDMA工作簡單時序理解

  VDMA內部linebuffer通過HP接口從DDR中搬運數據,通常VDMA之后直接連接axis_stream to video out IP模塊,該IP模塊內部通過異步FIFO來緩存數據實現跨時鍾域的問題,整體時序描述為VDMA tready信號給到PSVDMA會預讀一部分數據到linebuffer中,檢測到video_out模塊給出的tready信號將數據給到video_out 模塊的fifo中,如果fifo存滿則video_out不再給VDMA tready信號,此時VDMA仍舊一直從DDR中讀數據,直到video_out模塊中的FIFO變空再次給出tready信號,數據才會從VDMAlinebuffer流向video_out模塊;

VDMA 同步機制理解

         MasterSlave同步機制相當於古代的夫妻,講究的是夫唱婦隨,master是老公,slave是老婆,master不去理會slave當前在操作哪幀數據,自己只顧干自己的事情;slave則需要跟隨master,因此slave需要實時監測masterptr幀指針。

         Dynamic master/Dynamic slave同步機制則像現代社會的夫妻制度,講究的是謙讓和諧,master還是老公,slave還是老婆,但是兩者在工作時會通過ptr指針互相監督彼此。假如master看到slave在操作某一幀即1時,而此時自己也想對1進行操作,他會考慮這樣不行會起沖突,進而轉向對2進行操作。同理slave也是一樣;設計者在BlockDesign中需要將ptr_inptr_out用線連接起來;

VDMA 在設計中通常配置如下

         VDMA讀、寫通道通常配置3幀緩存,這樣能避免圖像顯示有割裂現象。

VDMA寫通道通常配置s2mm tuserdynamic master,至於位寬什么根據自己設計而定;

VDMA讀通道通常配置none dynamic slave

VDMA SDK驅動

         未附上有需要可郵件聯系

 

 

 

 

VDMA是通過AXI Stream協議對視頻數據在PSPL端進行搬運,開發者無需關注AXI Stream協議,在BlockDesign設計中只需要把相應信號進行連接即可。

VDMA配置有兩個選項

1   Basic

選擇地址位寬32bit 或者64bit

FrameBuffer 1~32可選,通常選擇3幀緩存;可避免圖像割裂;

 

2   Adanced

寫通道配置:

maxi_S2MM 是將stream流數據通過axi總線寫進memory

Fsync Options幀同步有三個選項nones2mm fsyncs2mm tuser

none被選擇后AXI VDMA處於free run模式,VDMA會盡可能快速的搬運數據,不受外部觸發信號所控制;

s2mm fsync被選擇VDMA檢測到s2mm fsync下降沿信號后開始搬運數據;

s2mm tuser被選擇VDMA檢測視頻幀起始信號(SOF)即AXI4-Stream下的s2mm tuser信號,檢測到信號拉高后開始搬運視頻數據;

GenLockMode有四個選項MasterSlaveDynamicMasterDynamicSlave

        MasterVDMAs2mm_frame_ptr_out端口輸出當前幀號;

        SlaveWhen selected, Slave follows the Master by the frames set in the Frame Delay registereither by skipping or repeating frames. The GenlockEn (S2MM_VDMACR[3]=1) registershould be set to enable genlock synchronization between the Master and Slave. Itoutputs the current frame number on the mm2s_frame_ptr_out port.

        DynamicMasterWhen selected, AXI VDMA skips the frame buffers that the Dynamic Slave is working on.
It outputs the completed frame number on the s2mm_frame_ptr_out port. GenlockEn (S2MM_VDMACR[3]=1) register should be set to enable genlock
synchronization between Dynamic Master and Dynamic Slave.

        DynamicSlaveWhen selected, AXI VDMA follows the Dynamic Master either by skipping or repeating frames. It outputs the current frame number on the s2mm_frame_ptr_out port. GenlockEn (S2MM_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

 

讀通道配置:

maxi_mm2s通道是將視頻數據通過axi總線從memory讀出;

maxis_mm2s 是將視頻數據轉成axis stream數據流形式;

Fsync Options幀同步有兩個選項nonemm2s fsync

none被選擇后AXI VDMA處於free run模式,VDMA會盡可能快速的搬運數據,不受外部觸發信號所控制;

注意在選擇none后通道會提供一個幀起始脈沖m_axis_mm2s_tuser(0)可用於下一級模塊downstream

mm2s fsync被選擇VDMA檢測到mm2s fsync下降沿信號后開始搬運數據;

GenLockMode有四個選項MasterSlaveDynamicMasterDynamicSlave

        MasterVDMAmm2s_frame_ptr_out端口輸出當前幀號;

        SlaveWhen selected, Slave follows the Master by the frames set in the Frame Delay registereither by skipping or repeating frames. The GenlockEn (MM2S_VDMACR[3]=1 registershould be set to enable genlock synchronization between the Master and Slave. Itoutputs the current frame number on the s2mm_frame_ptr_out.

        DynamicMasterWhen selected, AXI VDMA skips the frame buffers that the Dynamic Slave is working on.
It outputs the completed frame number on the mm2s_frame_ptr_out. GenlockEn (MM2S_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

        DynamicSlaveWhen selected, AXI VDMA follows the Dynamic Master either by skipping or repeating frames. It outputs the current frame number on the mm2s_frame_ptr_out . GenlockEn (MM2S_VDMACR[3]=1) register should be set to enable gunlock synchronization between Dynamic Master and Dynamic Slave.

VDMA工作簡單時序理解

  VDMA內部linebuffer通過HP接口從DDR中搬運數據,通常VDMA之后直接連接axis_stream to video out IP模塊,該IP模塊內部通過異步FIFO來緩存數據實現跨時鍾域的問題,整體時序描述為VDMA tready信號給到PSVDMA會預讀一部分數據到linebuffer中,檢測到video_out模塊給出的tready信號將數據給到video_out 模塊的fifo中,如果fifo存滿則video_out不再給VDMA tready信號,此時VDMA仍舊一直從DDR中讀數據,直到video_out模塊中的FIFO變空再次給出tready信號,數據才會從VDMAlinebuffer流向video_out模塊;

VDMA 同步機制理解

         MasterSlave同步機制相當於古代的夫妻,講究的是夫唱婦隨,master是老公,slave是老婆,master不去理會slave當前在操作哪幀數據,自己只顧干自己的事情;slave則需要跟隨master,因此slave需要實時監測masterptr幀指針。

         Dynamic master/Dynamic slave同步機制則像現代社會的夫妻制度,講究的是謙讓和諧,master還是老公,slave還是老婆,但是兩者在工作時會通過ptr指針互相監督彼此。假如master看到slave在操作某一幀即1時,而此時自己也想對1進行操作,他會考慮這樣不行會起沖突,進而轉向對2進行操作。同理slave也是一樣;設計者在BlockDesign中需要將ptr_inptr_out用線連接起來;

VDMA 在設計中通常配置如下

         VDMA讀、寫通道通常配置3幀緩存,這樣能避免圖像顯示有割裂現象。

VDMA寫通道通常配置s2mm tuserdynamic master,至於位寬什么根據自己設計而定;

VDMA讀通道通常配置none dynamic slave

VDMA SDK驅動

         未附上

 

 

 

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM