資源簡介
將OC_I2C_Master文件夾拷貝到安裝目錄\altera\kits\nios2\components目錄下。
之后重新打開SOPC Builder,在可用元件列表的DeviceSOPC組中將出現OC_I2C_Master元件,即可像其它Altera外設元件一樣添加和使用。
代碼片段和文件信息
#include?“system.h“
#include?“oc_i2c_regs.h“
#include?“alt_types.h“
void?I2CWaitTIP(alt_u32?base);
/*********************************************************************************************************
**?Function?name: InitI2C
**
**?Descriptions: Initialize?the?I2C?Open?Core.?The?frequency?of?SCL?is?set?as?freq
**????????????????????Interrupt?will?be?or?not?be?enabled?by?the?IEN??
**
**?input?parameters: base:?The?base?address?of?I2C?Core;
**????????????????????freq:?The?frequency?of?SCL?we?want
**????????????????????IEN?:?When?the?IEN?is?1?interrupt?will?be?enabled;
**??????????????????????????When?the?IEN?is?NOT?1?interrupt?will?be?disabled.???????????????????????
**
**?Returned?value: None?
**?????????
**?Used?global?variables: None
**?Calling?mod
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件??????31277??2007-01-22?20:55??oc_i2c_master\cb_generator.pl
?????文件???????7781??2007-01-22?20:55??oc_i2c_master\class.ptf
?????文件????????567??2007-01-22?20:55??oc_i2c_master\使用說明.txt
?????文件????????324??2007-01-22?20:55??oc_i2c_master\HAL\inc\oc_i2c.h
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\HAL\inc
?????文件????????130??2007-01-22?20:55??oc_i2c_master\HAL\src\component.mk
?????文件???????6717??2007-03-15?17:08??oc_i2c_master\HAL\src\oc_i2c.c
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\HAL\src
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\HAL
?????文件??????14480??2007-01-22?20:55??oc_i2c_master\hdl\i2c_master_bit_ctrl.vhd
?????文件??????11845??2007-01-22?20:55??oc_i2c_master\hdl\i2c_master_byte_ctrl.vhd
?????文件??????12010??2007-01-22?20:55??oc_i2c_master\hdl\i2c_master_top.vhd
?????文件???????3253??2007-01-22?20:55??oc_i2c_master\hdl\oc_i2c_master.vhd
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\hdl
?????文件?????193668??2007-01-22?20:55??oc_i2c_master\I2C_doc\i2c_specs.pdf
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\I2C_doc
?????文件???????1302??2007-03-15?17:16??oc_i2c_master\inc\oc_i2c_regs.h
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master\inc
?????目錄??????????0??2009-04-01?10:46??oc_i2c_master
-----------?---------??----------?-----??----
???????????????283354????????????????????19
- 上一篇:keil軟件中的STC芯片補丁包
- 下一篇:單相橋式全控整流電路設計
評論
共有 條評論