日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Xilinx Xio控制sdr sdram

發布時間:2023/12/18 编程问答 44 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Xilinx Xio控制sdr sdram 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

在嵌入式系統中,sdr sdram控制器對于用戶來講是透明的,即用戶在功能使用上沒有初始化、刷新等操作,直接IO讀寫函數讀寫相應的地址即可。基本的IO讀寫函數在文件io.h中定義,其本質就是簡單的指針賦值語句,32bit位寬的讀寫函數如下所示:

? ? ? ? ? #define XIo_In32(InputPtr)(*(volatile Xunit32*)(InputPtr))

? ? #define XIo_Out32(OutputPtr,Value) (*(volatile Xuint32*)((OutputPtr))=(Value))

因此在操作sdram時,只需添加下列兩個頭文件,其中,xio.h定義了端口操作函數,xparameters.h文件則給出了sdram存儲器的基地址

? ? ? ? #include "xio.h"

? ? ? ? #include "xparameters.h"

/*****************************************************************************/
/**
*
* Performs an input operation for a 32-bit memory location by reading from the
* specified address and returning the value read from that address.
*
* @param InputPtr contains the address to perform the input operation at.
*
* @return The value read from the specified input address.
*
* @note None.
*
******************************************************************************/
#define XIo_In32(InputPtr) ?(*(volatile u32 *)(InputPtr))


/*****************************************************************************/
/**
*
* Performs an output operation for a 32-bit memory location by writing the
* specified value to the the specified address.
*
* @param OutputPtr contains the address to perform the output operation
* at.
* @param Value contains the value to be output at the specified address.
*
* @return None
*
* @note None.
*
******************************************************************************/
#define XIo_Out32(OutputPtr, Value) \
(*(volatile u32 *)((OutputPtr)) = (Value))


總結

以上是生活随笔為你收集整理的Xilinx Xio控制sdr sdram的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。