0
  • 聊天消息
  • 系統(tǒng)消息
  • 評論與回復(fù)
登錄后你可以
  • 下載海量資料
  • 學(xué)習(xí)在線課程
  • 觀看技術(shù)視頻
  • 寫文章/發(fā)帖/加入社區(qū)
會員中心
創(chuàng)作中心

完善資料讓更多小伙伴認識你,還能領(lǐng)取20積分哦,立即完善>

3天內(nèi)不再提示

利用zedboard添加自定義IP核完成簡易計算器功能

Hx ? 來源:網(wǎng)絡(luò)整理 ? 作者:工程師陳翠 ? 2018-07-12 03:45 ? 次閱讀

認識zedboard板子也有半個多月了,期間有不少雜事,學(xué)的也不是很認真,最近幾天在學(xué)習(xí)如何利用AXI總線進行PS和PL部分的相互通信,利用自定義的IP核實現(xiàn)了簡易的計算功能(只有加減),下面對實驗的過程和自己的理解進行一下記錄。

首先本次試驗的目的是做一個建議的計算器,通過zedboard上的sw1,sw2標識操作(01表示加法操作,10表示剪發(fā)操作),另外通過led燈進行結(jié)果的顯示,通過串口進行操作數(shù)的輸入,而后利用FPGA進行運算,串口輸出結(jié)果。

實驗步驟:

首先在xps中進行工程的建立,導(dǎo)入配置文件(.xml);

而后進行自定義IP核的生成,這部分在下面進行詳細記錄;

將由xps完成的工程導(dǎo)出,進行ps端應(yīng)用程序的編寫

XPS工程的建立,這部分較為簡單,只用簡單圖示進行記錄

首先建立工程,在這里聽師兄講的,我理解為建立工程時用Base System Builder的好處是不需要對基礎(chǔ)的一些信息進行配置,這樣就能省去很多開發(fā)的麻煩,更深層次的就不能體會了。

利用zedboard添加自定義IP核完成簡易計算器功能

建立工程后選擇Avnet,在Base System Builder界面將右側(cè)不用的外設(shè)進行remove掉,而后完成對工程的建立

利用Hardware下的Create or import Peripheral建立自定義的IP核(在此我理解為這一步僅為對IP核的一些基礎(chǔ)信息的配置,至于IP核具體實現(xiàn)的功能和引出的端口還需要對用戶邏輯等信息進行配置),在選擇寄存器的個數(shù)時,由于本工程中涉及到SW,LED和進行計算時對操作數(shù)和結(jié)果的存儲,因此共需要五個寄存器

利用zedboard添加自定義IP核完成簡易計算器功能

在完成此IP的基本配置信息之后,進行用戶邏輯和端口號的配置

首先找到工程目錄下的pcores\my_calc_v1_v1_00_a\hdl\verilog的user_logic.v文件對用戶邏輯進行修改,本工程中設(shè)計到的用戶邏輯很簡單,根據(jù)sw前兩位的值判斷運算方式,而后利用運算數(shù)進行運算結(jié)果在led燈上進行顯示,代碼如下,對加入的代碼部分進行解釋,并加入我的理解

代碼:

//----------------------------------------------------------------------------

// user_logic.v - module

//----------------------------------------------------------------------------

//

// ***************************************************************************

// ** Copyright (c) 1995-2012 Xilinx, Inc. All rights reserved. **

// ** **

// ** Xilinx, Inc. **

// ** XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION “AS IS” **

// ** AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND **

// ** SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE, **

// ** OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE, **

// ** APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION **

// ** THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT, **

// ** AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE **

// ** FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY **

// ** WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE **

// ** IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR **

// ** REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF **

// ** INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS **

// ** FOR A PARTICULAR PURPOSE. **

// ** **

// ***************************************************************************

//

//----------------------------------------------------------------------------

// Filename: user_logic.v

// Version: 1.00.a

// Description: User logic module.

// Date: Fri Jul 19 15:24:36 2013 (by Create and Import Peripheral Wizard)

// Verilog Standard: Verilog-2001

//----------------------------------------------------------------------------

// Naming Conventions:

// active low signals: “*_n”

// clock signals: “clk”, “clk_div#”, “clk_#x”

// reset signals: “rst”, “rst_n”

// generics: “C_*”

// user defined types: “*_TYPE”

// state machine next state: “*_ns”

// state machine current state: “*_cs”

// combinatorial signals: “*_com”

// pipelined or register delay signals: “*_d#”

// counter signals: “*cnt*”

// clock enable signals: “*_ce”

// internal version of output port: “*_i”

// device pins: “*_pin”

// ports: “- Names begin with Uppercase”

// processes: “*_PROCESS”

// component instantiations: “I_《#|FUNC》”

//----------------------------------------------------------------------------

`uselib lib=unisims_ver

`uselib lib=proc_common_v3_00_a

module user_logic

// -- ADD USER PORTS BELOW THIS LINE ---------------

// --USER ports added here

SW_In, //The operator

LED_Out, //Show some information

// -- ADD USER PORTS ABOVE THIS LINE ---------------

// -- DO NOT EDIT BELOW THIS LINE ------------------

// -- Bus protocol ports, do not add to or delete

Bus2IP_Clk, // Bus to IP clock

Bus2IP_Resetn, // Bus to IP reset

Bus2IP_Data, // Bus to IP data bus

Bus2IP_BE, // Bus to IP byte enables

Bus2IP_RdCE, // Bus to IP read chip enable

Bus2IP_WrCE, // Bus to IP write chip enable

IP2Bus_Data, // IP to Bus data bus

IP2Bus_RdAck, // IP to Bus read transfer acknowledgement

IP2Bus_WrAck, // IP to Bus write transfer acknowledgement

IP2Bus_Error // IP to Bus error response

// -- DO NOT EDIT ABOVE THIS LINE ------------------

); // user_logic

// -- ADD USER PARAMETERS BELOW THIS LINE ------------

// --USER parameters added here

// -- ADD USER PARAMETERS ABOVE THIS LINE ------------

// -- DO NOT EDIT BELOW THIS LINE --------------------

// -- Bus protocol parameters, do not add to or delete

parameter C_NUM_REG = 5;

parameter C_SLV_DWIDTH = 32;

// -- DO NOT EDIT ABOVE THIS LINE --------------------

// -- ADD USER PORTS BELOW THIS LINE -----------------

// --USER ports added here

input [7 : 0] SW_In;

output [7 : 0] LED_Out;

// -- ADD USER PORTS ABOVE THIS LINE -----------------

// -- DO NOT EDIT BELOW THIS LINE --------------------

// -- Bus protocol ports, do not add to or delete

input Bus2IP_Clk;

input Bus2IP_Resetn;

input [C_SLV_DWIDTH-1 : 0] Bus2IP_Data;

input [C_SLV_DWIDTH/8-1 : 0] Bus2IP_BE;

input [C_NUM_REG-1 : 0] Bus2IP_RdCE;

input [C_NUM_REG-1 : 0] Bus2IP_WrCE;

output [C_SLV_DWIDTH-1 : 0] IP2Bus_Data;

output IP2Bus_RdAck;

output IP2Bus_WrAck;

output IP2Bus_Error;

// -- DO NOT EDIT ABOVE THIS LINE --------------------

//----------------------------------------------------------------------------

// Implementation

//----------------------------------------------------------------------------

// --USER nets declarations added here, as needed for user logic \

reg [7 : 0] LED_reg;

// Nets for user logic slave model s/w accessible register example

reg [C_SLV_DWIDTH-1 : 0] slv_reg0;

reg [C_SLV_DWIDTH-1 : 0] slv_reg1;

reg [C_SLV_DWIDTH-1 : 0] slv_reg2;

reg [C_SLV_DWIDTH-1 : 0] slv_reg3;

reg [C_SLV_DWIDTH-1 : 0] slv_reg4;

wire [4 : 0] slv_reg_write_sel;

wire [4 : 0] slv_reg_read_sel;

reg [C_SLV_DWIDTH-1 : 0] slv_ip2bus_data;

wire slv_read_ack;

wire slv_write_ack;

integer byte_index, bit_index;

// USER logic implementation added here

// ------------------------------------------------------

// Example code to read/write user logic slave model s/w accessible registers

//

// Note:

// The example code presented here is to show you one way of reading/writing

// software accessible registers implemented in the user logic slave model.

// Each bit of the Bus2IP_WrCE/Bus2IP_RdCE signals is configured to correspond

// to one software accessible register by the top level template. For example,

// if you have four 32 bit software accessible registers in the user logic,

// you are basically operating on the following memory mapped registers:

//

// Bus2IP_WrCE/Bus2IP_RdCE Memory Mapped Register

// “1000” C_BASEADDR + 0x0

// “0100” C_BASEADDR + 0x4

// “0010” C_BASEADDR + 0x8

// “0001” C_BASEADDR + 0xC

//

// ------------------------------------------------------

assign

slv_reg_write_sel = Bus2IP_WrCE[4:0],

slv_reg_read_sel = Bus2IP_RdCE[4:0],

slv_write_ack = Bus2IP_WrCE[0] || Bus2IP_WrCE[1] || Bus2IP_WrCE[2] || Bus2IP_WrCE[3] || Bus2IP_WrCE[4],

slv_read_ack = Bus2IP_RdCE[0] || Bus2IP_RdCE[1] || Bus2IP_RdCE[2] || Bus2IP_RdCE[3] || Bus2IP_RdCE[4];

// implement slave model register(s)

always @( posedge Bus2IP_Clk )

begin

if ( Bus2IP_Resetn == 1‘b0 )

begin

//slv_reg0 《= 0;

//slv_reg1 《= 0;

slv_reg2 《= 0;

slv_reg3 《= 0;

// slv_reg4 《= 0;

end

else

case ( slv_reg_write_sel )

/* 5’b10000 :

for ( byte_index = 0; byte_index 《= (C_SLV_DWIDTH/8)-1; byte_index = byte_index+1 )

if ( Bus2IP_BE[byte_index] == 1 )

slv_reg0[(byte_index*8) +: 8] 《= Bus2IP_Data[(byte_index*8) +: 8]; */

5‘b01000 :

for ( byte_index = 0; byte_index 《= (C_SLV_DWIDTH/8)-1; byte_index = byte_index+1 )

if ( Bus2IP_BE[byte_index] == 1 )

slv_reg1[(byte_index*8) +: 8] 《= Bus2IP_Data[(byte_index*8) +: 8];

5’b00100 :

for ( byte_index = 0; byte_index 《= (C_SLV_DWIDTH/8)-1; byte_index = byte_index+1 )

if ( Bus2IP_BE[byte_index] == 1 )

slv_reg2[(byte_index*8) +: 8] 《= Bus2IP_Data[(byte_index*8) +: 8];

5‘b00010 :

for ( byte_index = 0; byte_index 《= (C_SLV_DWIDTH/8)-1; byte_index = byte_index+1 )

if ( Bus2IP_BE[byte_index] == 1 )

slv_reg3[(byte_index*8) +: 8] 《= Bus2IP_Data[(byte_index*8) +: 8];

/* 5’b00001 :

for ( byte_index = 0; byte_index 《= (C_SLV_DWIDTH/8)-1; byte_index = byte_index+1 )

if ( Bus2IP_BE[byte_index] == 1 )

slv_reg4[(byte_index*8) +: 8] 《= Bus2IP_Data[(byte_index*8) +: 8]; */

default : begin

slv_reg0 《= slv_reg0;

slv_reg1 《= slv_reg1;

slv_reg2 《= slv_reg2;

slv_reg3 《= slv_reg3;

slv_reg4 《= slv_reg4;

end

endcase

end // SLAVE_REG_WRITE_PROC

// implement slave model register read mux

always @( slv_reg_read_sel or slv_reg0 or slv_reg1 or slv_reg2 or slv_reg3 or slv_reg4 )

begin

case ( slv_reg_read_sel )

5‘b10000 : slv_ip2bus_data 《= slv_reg0;

5’b01000 : slv_ip2bus_data 《= slv_reg1;

5‘b00100 : slv_ip2bus_data 《= slv_reg2;

5’b00010 : slv_ip2bus_data 《= slv_reg3;

5‘b00001 : slv_ip2bus_data 《= slv_reg4;

default : slv_ip2bus_data 《= 0;

endcase

end // SLAVE_REG_READ_PROC

// ------------------------------------------------------------

// Example code to drive IP to Bus signals

// ------------------------------------------------------------

always @(posedge Bus2IP_Clk)

begin

slv_reg0[7 : 0] 《= SW_In[7 : 0];

LED_reg 《= slv_reg1[7 : 0];

end

always @(posedge Bus2IP_Clk)

begin

case(slv_reg0[1 : 0])

2’b01 : slv_reg4 《= slv_reg2 + slv_reg3;

2‘b10 : slv_reg4 《= slv_reg2 - slv_reg3;

default : slv_reg4 《= 0;

endcase

end

assign IP2Bus_Data = (slv_read_ack == 1’b1) ? slv_ip2bus_data : 0 ;

assign IP2Bus_WrAck = slv_write_ack;

assign IP2Bus_RdAck = slv_read_ack;

assign IP2Bus_Error = 0;

assign LED_Out = LED_reg;

endmodule

其中代碼slv_reg0~slv_reg4為IP核中申請的5個寄存器,在這里可以根據(jù)自己的需要對這個5個寄存器的作用進行分配,在這里完全是按照自己的意愿分配,本程序中,我將slv_reg0用來存儲sw的值,slv_reg1用來表示led的信息,slv_reg2和slv_reg3用來進行操作數(shù)的存儲,slv_reg4用來存儲運算結(jié)果。

注意,由于在模塊中sw為input故他的值不是從總線上進行讀取的,slv_reg4存儲運算結(jié)果,其值也不需要進行存儲,故需要對源程序中的一些信息進行注釋,即對case下的第一和最后一個選項進行注釋,這個地方需要進行自己的判斷

另外用戶邏輯的加入在代碼:

always @(posedge Bus2IP_Clk)

begin

slv_reg0[7 : 0] 《= SW_In[7 : 0];

LED_reg 《= slv_reg1[7 : 0];

end

always @(posedge Bus2IP_Clk)

begin

case(slv_reg0[1 : 0])

2‘b01 : slv_reg4 《= slv_reg2 + slv_reg3;

2’b10 : slv_reg4 《= slv_reg2 - slv_reg3;

default : slv_reg4 《= 0;

endcase

end

可以看出本工程中的邏輯比較簡單,就是根據(jù)sw的值進行操作數(shù)的加減運算。

在完成用戶邏輯后,還需要對IP核的端口進行配置,與IPIF相連接(我是這么理解的,可能會不對)

在目錄pcores\my_calc_v1_v1_00_a\hdl\vhdl下對文件my_calc_v1.vhd進行更改,代碼如下:

------------------------------------------------------------------------------

-- my_calc_v1.vhd - entity/architecture pair

------------------------------------------------------------------------------

-- IMPORTANT:

-- DO NOT MODIFY THIS FILE EXCEPT IN THE DESIGNATED SECTIONS.

--

-- SEARCH FOR --USER TO DETERMINE WHERE CHANGES ARE ALLOWED.

--

-- TYPICALLY, THE ONLY ACCEPTABLE CHANGES INVOLVE ADDING NEW

-- PORTS AND GENERICS THAT GET PASSED THROUGH TO THE INSTANTIATION

-- OF THE USER_LOGIC ENTITY.

------------------------------------------------------------------------------

--

-- ***************************************************************************

-- ** Copyright (c) 1995-2012 Xilinx, Inc. All rights reserved. **

-- ** **

-- ** Xilinx, Inc. **

-- ** XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION “AS IS” **

-- ** AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND **

-- ** SOLUTIONS FOR XILINX DEVICES. BY PROVIDING THIS DESIGN, CODE, **

-- ** OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE, **

-- ** APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION **

-- ** THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT, **

-- ** AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE **

-- ** FOR YOUR IMPLEMENTATION. XILINX EXPRESSLY DISCLAIMS ANY **

-- ** WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE **

-- ** IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR **

-- ** REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF **

-- ** INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS **

-- ** FOR A PARTICULAR PURPOSE. **

-- ** **

-- ***************************************************************************

--

------------------------------------------------------------------------------

-- Filename: my_calc_v1.vhd

-- Version: 1.00.a

-- Description: Top level design, instantiates library components and user logic.

-- Date: Fri Jul 19 15:24:36 2013 (by Create and Import Peripheral Wizard)

-- VHDL Standard: VHDL‘93

------------------------------------------------------------------------------

-- Naming Conventions:

-- active low signals: “*_n”

-- clock signals: “clk”, “clk_div#”, “clk_#x”

-- reset signals: “rst”, “rst_n”

-- generics: “C_*”

-- user defined types: “*_TYPE”

-- state machine next state: “*_ns”

-- state machine current state: “*_cs”

-- combinatorial signals: “*_com”

-- pipelined or register delay signals: “*_d#”

-- counter signals: “*cnt*”

-- clock enable signals: “*_ce”

-- internal version of output port: “*_i”

-- device pins: “*_pin”

-- ports: “- Names begin with Uppercase”

-- processes: “*_PROCESS”

-- component instantiations: “I_《#|FUNC》”

------------------------------------------------------------------------------

library ieee;

use ieee.std_logic_1164.all;

use ieee.std_logic_arith.all;

use ieee.std_logic_unsigned.all;

library proc_common_v3_00_a;

use proc_common_v3_00_a.proc_common_pkg.all;

use proc_common_v3_00_a.ipif_pkg.all;

library axi_lite_ipif_v1_01_a;

use axi_lite_ipif_v1_01_a.axi_lite_ipif;

------------------------------------------------------------------------------

-- Entity section

------------------------------------------------------------------------------

-- Definition of Generics:

-- C_S_AXI_DATA_WIDTH -- AXI4LITE slave: Data width

-- C_S_AXI_ADDR_WIDTH -- AXI4LITE slave: Address Width

-- C_S_AXI_MIN_SIZE -- AXI4LITE slave: Min Size

-- C_USE_WSTRB -- AXI4LITE slave: Write Strobe

-- C_DPHASE_TIMEOUT -- AXI4LITE slave: Data Phase Timeout

-- C_BASEADDR -- AXI4LITE slave: base address

-- C_HIGHADDR -- AXI4LITE slave: high address

-- C_FAMILY -- FPGA Family

-- C_NUM_REG -- Number of software accessible registers

-- C_NUM_MEM -- Number of address-ranges

-- C_SLV_AWIDTH -- Slave interface address bus width

-- C_SLV_DWIDTH -- Slave interface data bus width

--

-- Definition of Ports:

-- S_AXI_ACLK -- AXI4LITE slave: Clock

-- S_AXI_ARESETN -- AXI4LITE slave: Reset

-- S_AXI_AWADDR -- AXI4LITE slave: Write address

-- S_AXI_AWVALID -- AXI4LITE slave: Write address valid

-- S_AXI_WDATA -- AXI4LITE slave: Write data

-- S_AXI_WSTRB -- AXI4LITE slave: Write strobe

-- S_AXI_WVALID -- AXI4LITE slave: Write data valid

-- S_AXI_BREADY -- AXI4LITE slave: Response ready

-- S_AXI_ARADDR -- AXI4LITE slave: Read address

-- S_AXI_ARVALID -- AXI4LITE slave: Read address valid

-- S_AXI_RREADY -- AXI4LITE slave: Read data ready

-- S_AXI_ARREADY -- AXI4LITE slave: read addres ready

-- S_AXI_RDATA -- AXI4LITE slave: Read data

-- S_AXI_RRESP -- AXI4LITE slave: Read data response

-- S_AXI_RVALID -- AXI4LITE slave: Read data valid

-- S_AXI_WREADY -- AXI4LITE slave: Write data ready

-- S_AXI_BRESP -- AXI4LITE slave: Response

-- S_AXI_BVALID -- AXI4LITE slave: Resonse valid

-- S_AXI_AWREADY -- AXI4LITE slave: Wrte address ready

------------------------------------------------------------------------------

entity my_calc_v1 is

generic

-- ADD USER GENERICS BELOW THIS LINE ---------------

--USER generics added here

-- ADD USER GENERICS ABOVE THIS LINE ---------------

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol parameters, do not add to or delete

C_S_AXI_DATA_WIDTH : integer := 32;

C_S_AXI_ADDR_WIDTH : integer := 32;

C_S_AXI_MIN_SIZE : std_logic_vector := X“000001FF”;

C_USE_WSTRB : integer := 0;

C_DPHASE_TIMEOUT : integer := 8;

C_BASEADDR : std_logic_vector := X“FFFFFFFF”;

C_HIGHADDR : std_logic_vector := X“00000000”;

C_FAMILY : string := “virtex6”;

C_NUM_REG : integer := 1;

C_NUM_MEM : integer := 1;

C_SLV_AWIDTH : integer := 32;

C_SLV_DWIDTH : integer := 32

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

port

-- ADD USER PORTS BELOW THIS LINE ------------------

--USER ports added here

-- ADD USER PORTS ABOVE THIS LINE ------------------

GPIO_LED_Out : out std_logic_vector(7 downto 0);

GPIO_SW_In : in std_logic_vector(7 downto 0);

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol ports, do not add to or delete

S_AXI_ACLK : in std_logic;

S_AXI_ARESETN : in std_logic;

S_AXI_AWADDR : in std_logic_vector(C_S_AXI_ADDR_WIDTH-1 downto 0);

S_AXI_AWVALID : in std_logic;

S_AXI_WDATA : in std_logic_vector(C_S_AXI_DATA_WIDTH-1 downto 0);

S_AXI_WSTRB : in std_logic_vector((C_S_AXI_DATA_WIDTH/8)-1 downto 0);

S_AXI_WVALID : in std_logic;

S_AXI_BREADY : in std_logic;

S_AXI_ARADDR : in std_logic_vector(C_S_AXI_ADDR_WIDTH-1 downto 0);

S_AXI_ARVALID : in std_logic;

S_AXI_RREADY : in std_logic;

S_AXI_ARREADY : out std_logic;

S_AXI_RDATA : out std_logic_vector(C_S_AXI_DATA_WIDTH-1 downto 0);

S_AXI_RRESP : out std_logic_vector(1 downto 0);

S_AXI_RVALID : out std_logic;

S_AXI_WREADY : out std_logic;

S_AXI_BRESP : out std_logic_vector(1 downto 0);

S_AXI_BVALID : out std_logic;

S_AXI_AWREADY : out std_logic

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

attribute MAX_FANOUT : string;

attribute SIGIS : string;

attribute MAX_FANOUT of S_AXI_ACLK : signal is “10000”;

attribute MAX_FANOUT of S_AXI_ARESETN : signal is “10000”;

attribute SIGIS of S_AXI_ACLK : signal is “Clk”;

attribute SIGIS of S_AXI_ARESETN : signal is “Rst”;

end entity my_calc_v1;

------------------------------------------------------------------------------

-- Architecture section

------------------------------------------------------------------------------

architecture IMP of my_calc_v1 is

constant USER_SLV_DWIDTH : integer := C_S_AXI_DATA_WIDTH;

constant IPIF_SLV_DWIDTH : integer := C_S_AXI_DATA_WIDTH;

constant ZERO_ADDR_PAD : std_logic_vector(0 to 31) := (others =》 ’0‘);

constant USER_SLV_BASEADDR : std_logic_vector := C_BASEADDR;

constant USER_SLV_HIGHADDR : std_logic_vector := C_HIGHADDR;

constant IPIF_ARD_ADDR_RANGE_ARRAY : SLV64_ARRAY_TYPE :=

ZERO_ADDR_PAD & USER_SLV_BASEADDR, -- user logic slave space base address

ZERO_ADDR_PAD & USER_SLV_HIGHADDR -- user logic slave space high address

);

constant USER_SLV_NUM_REG : integer := 5;

constant USER_NUM_REG : integer := USER_SLV_NUM_REG;

constant TOTAL_IPIF_CE : integer := USER_NUM_REG;

constant IPIF_ARD_NUM_CE_ARRAY : INTEGER_ARRAY_TYPE :=

0 =》 (USER_SLV_NUM_REG) -- number of ce for user logic slave space

);

------------------------------------------

-- Index for CS/CE

------------------------------------------

constant USER_SLV_CS_INDEX : integer := 0;

constant USER_SLV_CE_INDEX : integer := calc_start_ce_index(IPIF_ARD_NUM_CE_ARRAY, USER_SLV_CS_INDEX);

constant USER_CE_INDEX : integer := USER_SLV_CE_INDEX;

------------------------------------------

-- IP Interconnect (IPIC) signal declarations

------------------------------------------

signal ipif_Bus2IP_Clk : std_logic;

signal ipif_Bus2IP_Resetn : std_logic;

signal ipif_Bus2IP_Addr : std_logic_vector(C_S_AXI_ADDR_WIDTH-1 downto 0);

signal ipif_Bus2IP_RNW : std_logic;

signal ipif_Bus2IP_BE : std_logic_vector(IPIF_SLV_DWIDTH/8-1 downto 0);

signal ipif_Bus2IP_CS : std_logic_vector((IPIF_ARD_ADDR_RANGE_ARRAY’LENGTH)/2-1 downto 0);

signal ipif_Bus2IP_RdCE : std_logic_vector(calc_num_ce(IPIF_ARD_NUM_CE_ARRAY)-1 downto 0);

signal ipif_Bus2IP_WrCE : std_logic_vector(calc_num_ce(IPIF_ARD_NUM_CE_ARRAY)-1 downto 0);

signal ipif_Bus2IP_Data : std_logic_vector(IPIF_SLV_DWIDTH-1 downto 0);

signal ipif_IP2Bus_WrAck : std_logic;

signal ipif_IP2Bus_RdAck : std_logic;

signal ipif_IP2Bus_Error : std_logic;

signal ipif_IP2Bus_Data : std_logic_vector(IPIF_SLV_DWIDTH-1 downto 0);

signal user_Bus2IP_RdCE : std_logic_vector(USER_NUM_REG-1 downto 0);

signal user_Bus2IP_WrCE : std_logic_vector(USER_NUM_REG-1 downto 0);

signal user_IP2Bus_Data : std_logic_vector(USER_SLV_DWIDTH-1 downto 0);

signal user_IP2Bus_RdAck : std_logic;

signal user_IP2Bus_WrAck : std_logic;

signal user_IP2Bus_Error : std_logic;

------------------------------------------

-- Component declaration for verilog user logic

------------------------------------------

component user_logic is

generic

-- ADD USER GENERICS BELOW THIS LINE ---------------

--USER generics added here

-- ADD USER GENERICS ABOVE THIS LINE ---------------

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol parameters, do not add to or delete

C_NUM_REG : integer := 5;

C_SLV_DWIDTH : integer := 32

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

port

-- ADD USER PORTS BELOW THIS LINE ------------------

--USER ports added here

-- ADD USER PORTS ABOVE THIS LINE ------------------

LED_Out :out std_logic_vector(7 downto 0);

SW_In :in std_logic_vector(7 downto 0);

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol ports, do not add to or delete

Bus2IP_Clk : in std_logic;

Bus2IP_Resetn : in std_logic;

Bus2IP_Data : in std_logic_vector(C_SLV_DWIDTH-1 downto 0);

Bus2IP_BE : in std_logic_vector(C_SLV_DWIDTH/8-1 downto 0);

Bus2IP_RdCE : in std_logic_vector(C_NUM_REG-1 downto 0);

Bus2IP_WrCE : in std_logic_vector(C_NUM_REG-1 downto 0);

IP2Bus_Data : out std_logic_vector(C_SLV_DWIDTH-1 downto 0);

IP2Bus_RdAck : out std_logic;

IP2Bus_WrAck : out std_logic;

IP2Bus_Error : out std_logic

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

end component user_logic;

begin

------------------------------------------

-- instantiate axi_lite_ipif

------------------------------------------

AXI_LITE_IPIF_I : entity axi_lite_ipif_v1_01_a.axi_lite_ipif

generic map

C_S_AXI_DATA_WIDTH =》 IPIF_SLV_DWIDTH,

C_S_AXI_ADDR_WIDTH =》 C_S_AXI_ADDR_WIDTH,

C_S_AXI_MIN_SIZE =》 C_S_AXI_MIN_SIZE,

C_USE_WSTRB =》 C_USE_WSTRB,

C_DPHASE_TIMEOUT =》 C_DPHASE_TIMEOUT,

C_ARD_ADDR_RANGE_ARRAY =》 IPIF_ARD_ADDR_RANGE_ARRAY,

C_ARD_NUM_CE_ARRAY =》 IPIF_ARD_NUM_CE_ARRAY,

C_FAMILY =》 C_FAMILY

port map

S_AXI_ACLK =》 S_AXI_ACLK,

S_AXI_ARESETN =》 S_AXI_ARESETN,

S_AXI_AWADDR =》 S_AXI_AWADDR,

S_AXI_AWVALID =》 S_AXI_AWVALID,

S_AXI_WDATA =》 S_AXI_WDATA,

S_AXI_WSTRB =》 S_AXI_WSTRB,

S_AXI_WVALID =》 S_AXI_WVALID,

S_AXI_BREADY =》 S_AXI_BREADY,

S_AXI_ARADDR =》 S_AXI_ARADDR,

S_AXI_ARVALID =》 S_AXI_ARVALID,

S_AXI_RREADY =》 S_AXI_RREADY,

S_AXI_ARREADY =》 S_AXI_ARREADY,

S_AXI_RDATA =》 S_AXI_RDATA,

S_AXI_RRESP =》 S_AXI_RRESP,

S_AXI_RVALID =》 S_AXI_RVALID,

S_AXI_WREADY =》 S_AXI_WREADY,

S_AXI_BRESP =》 S_AXI_BRESP,

S_AXI_BVALID =》 S_AXI_BVALID,

S_AXI_AWREADY =》 S_AXI_AWREADY,

Bus2IP_Clk =》 ipif_Bus2IP_Clk,

Bus2IP_Resetn =》 ipif_Bus2IP_Resetn,

Bus2IP_Addr =》 ipif_Bus2IP_Addr,

Bus2IP_RNW =》 ipif_Bus2IP_RNW,

Bus2IP_BE =》 ipif_Bus2IP_BE,

Bus2IP_CS =》 ipif_Bus2IP_CS,

Bus2IP_RdCE =》 ipif_Bus2IP_RdCE,

Bus2IP_WrCE =》 ipif_Bus2IP_WrCE,

Bus2IP_Data =》 ipif_Bus2IP_Data,

IP2Bus_WrAck =》 ipif_IP2Bus_WrAck,

IP2Bus_RdAck =》 ipif_IP2Bus_RdAck,

IP2Bus_Error =》 ipif_IP2Bus_Error,

IP2Bus_Data =》 ipif_IP2Bus_Data

);

------------------------------------------

-- instantiate User Logic

------------------------------------------

USER_LOGIC_I : component user_logic

generic map

-- MAP USER GENERICS BELOW THIS LINE ---------------

--USER generics mapped here

-- MAP USER GENERICS ABOVE THIS LINE ---------------

C_NUM_REG =》 USER_NUM_REG,

C_SLV_DWIDTH =》 USER_SLV_DWIDTH

port map

-- MAP USER PORTS BELOW THIS LINE ------------------

--USER ports mapped here

LED_Out =》 GPIO_LED_Out,

SW_In =》 GPIO_SW_In,

-- MAP USER PORTS ABOVE THIS LINE ------------------

Bus2IP_Clk =》 ipif_Bus2IP_Clk,

Bus2IP_Resetn =》 ipif_Bus2IP_Resetn,

Bus2IP_Data =》 ipif_Bus2IP_Data,

Bus2IP_BE =》 ipif_Bus2IP_BE,

Bus2IP_RdCE =》 user_Bus2IP_RdCE,

Bus2IP_WrCE =》 user_Bus2IP_WrCE,

IP2Bus_Data =》 user_IP2Bus_Data,

IP2Bus_RdAck =》 user_IP2Bus_RdAck,

IP2Bus_WrAck =》 user_IP2Bus_WrAck,

IP2Bus_Error =》 user_IP2Bus_Error

);

------------------------------------------

-- connect internal signals

------------------------------------------

ipif_IP2Bus_Data 《= user_IP2Bus_Data;

ipif_IP2Bus_WrAck 《= user_IP2Bus_WrAck;

ipif_IP2Bus_RdAck 《= user_IP2Bus_RdAck;

ipif_IP2Bus_Error 《= user_IP2Bus_Error;

user_Bus2IP_RdCE 《= ipif_Bus2IP_RdCE(USER_NUM_REG-1 downto 0);

user_Bus2IP_WrCE 《= ipif_Bus2IP_WrCE(USER_NUM_REG-1 downto 0);

end IMP;

這個里面的一些部分比較難理解,我只是按照我的想法進行解釋,不一定正確

我理解的這個文件是對IP核這個實體進行的配置,其中包括的部分分別是,實體的信息,包括實體包含的寄存器,寄存器位寬,實體的對外端口等,其代碼為:

entity my_calc_v1 is

generic

-- ADD USER GENERICS BELOW THIS LINE ---------------

--USER generics added here

-- ADD USER GENERICS ABOVE THIS LINE ---------------

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol parameters, do not add to or delete

C_S_AXI_DATA_WIDTH : integer := 32;

C_S_AXI_ADDR_WIDTH : integer := 32;

C_S_AXI_MIN_SIZE : std_logic_vector := X“000001FF”;

C_USE_WSTRB : integer := 0;

C_DPHASE_TIMEOUT : integer := 8;

C_BASEADDR : std_logic_vector := X“FFFFFFFF”;

C_HIGHADDR : std_logic_vector := X“00000000”;

C_FAMILY : string := “virtex6”;

C_NUM_REG : integer := 1;

C_NUM_MEM : integer := 1;

C_SLV_AWIDTH : integer := 32;

C_SLV_DWIDTH : integer := 32

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

port

-- ADD USER PORTS BELOW THIS LINE ------------------

--USER ports added here

-- ADD USER PORTS ABOVE THIS LINE ------------------

GPIO_LED_Out : out std_logic_vector(7 downto 0);

GPIO_SW_In : in std_logic_vector(7 downto 0);

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol ports, do not add to or delete

S_AXI_ACLK : in std_logic;

S_AXI_ARESETN : in std_logic;

S_AXI_AWADDR : in std_logic_vector(C_S_AXI_ADDR_WIDTH-1 downto 0);

S_AXI_AWVALID : in std_logic;

S_AXI_WDATA : in std_logic_vector(C_S_AXI_DATA_WIDTH-1 downto 0);

S_AXI_WSTRB : in std_logic_vector((C_S_AXI_DATA_WIDTH/8)-1 downto 0);

S_AXI_WVALID : in std_logic;

S_AXI_BREADY : in std_logic;

S_AXI_ARADDR : in std_logic_vector(C_S_AXI_ADDR_WIDTH-1 downto 0);

S_AXI_ARVALID : in std_logic;

S_AXI_RREADY : in std_logic;

S_AXI_ARREADY : out std_logic;

S_AXI_RDATA : out std_logic_vector(C_S_AXI_DATA_WIDTH-1 downto 0);

S_AXI_RRESP : out std_logic_vector(1 downto 0);

S_AXI_RVALID : out std_logic;

S_AXI_WREADY : out std_logic;

S_AXI_BRESP : out std_logic_vector(1 downto 0);

S_AXI_BVALID : out std_logic;

S_AXI_AWREADY : out std_logic

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

在這里需要對實體添加自定義的對外接口,SW和LED

下面就是對IP核的實現(xiàn)進行描述,包括IP核的架構(gòu)(也是圖形界面配置的一部分)包含的用戶邏輯和用戶邏輯到對外端口的映射關(guān)系

component user_logic is

generic

-- ADD USER GENERICS BELOW THIS LINE ---------------

--USER generics added here

-- ADD USER GENERICS ABOVE THIS LINE ---------------

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol parameters, do not add to or delete

C_NUM_REG : integer := 5;

C_SLV_DWIDTH : integer := 32

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

port

-- ADD USER PORTS BELOW THIS LINE ------------------

--USER ports added here

-- ADD USER PORTS ABOVE THIS LINE ------------------

LED_Out :out std_logic_vector(7 downto 0);

SW_In :in std_logic_vector(7 downto 0);

-- DO NOT EDIT BELOW THIS LINE ---------------------

-- Bus protocol ports, do not add to or delete

Bus2IP_Clk : in std_logic;

Bus2IP_Resetn : in std_logic;

Bus2IP_Data : in std_logic_vector(C_SLV_DWIDTH-1 downto 0);

Bus2IP_BE : in std_logic_vector(C_SLV_DWIDTH/8-1 downto 0);

Bus2IP_RdCE : in std_logic_vector(C_NUM_REG-1 downto 0);

Bus2IP_WrCE : in std_logic_vector(C_NUM_REG-1 downto 0);

IP2Bus_Data : out std_logic_vector(C_SLV_DWIDTH-1 downto 0);

IP2Bus_RdAck : out std_logic;

IP2Bus_WrAck : out std_logic;

IP2Bus_Error : out std_logic

-- DO NOT EDIT ABOVE THIS LINE ---------------------

);

end component user_logic;

這部分用戶邏輯的描述,需要再其中加入自己添加的部分,由于在用戶邏輯中添加了SW和LED的輸入輸出,因此在這部分中需要進行添加

最后是用戶邏輯中的端口到IP核對外端口的映射,在map中進行了體現(xiàn),代碼如下

USER_LOGIC_I : component user_logic

generic map

-- MAP USER GENERICS BELOW THIS LINE ---------------

--USER generics mapped here

-- MAP USER GENERICS ABOVE THIS LINE ---------------

C_NUM_REG =》 USER_NUM_REG,

C_SLV_DWIDTH =》 USER_SLV_DWIDTH

port map

-- MAP USER PORTS BELOW THIS LINE ------------------

--USER ports mapped here

LED_Out =》 GPIO_LED_Out,

SW_In =》 GPIO_SW_In,

-- MAP USER PORTS ABOVE THIS LINE ------------------

Bus2IP_Clk =》 ipif_Bus2IP_Clk,

Bus2IP_Resetn =》 ipif_Bus2IP_Resetn,

Bus2IP_Data =》 ipif_Bus2IP_Data,

Bus2IP_BE =》 ipif_Bus2IP_BE,

Bus2IP_RdCE =》 user_Bus2IP_RdCE,

Bus2IP_WrCE =》 user_Bus2IP_WrCE,

IP2Bus_Data =》 user_IP2Bus_Data,

IP2Bus_RdAck =》 user_IP2Bus_RdAck,

IP2Bus_WrAck =》 user_IP2Bus_WrAck,

IP2Bus_Error =》 user_IP2Bus_Error

);

在完成以上代碼的書寫后,就基本完成了IP的控制,下面就是將IP核添加到工程中去,在此雙擊用戶的IP核即可添加,在添加完成后,會在Bus Interface中發(fā)現(xiàn)此IP核,而后在port中進行配置,在port的配置過程中我理解為,此部分為經(jīng)過IPIF包裝后IP核的對外端口,通過這些對外端口可以進行一些外設(shè)的連接,而后此IP核映射到PS端,當作一個外設(shè)進行同意編址,PS端可以直接對地址進行操作,就可以控制外設(shè)(如sw和led)

利用zedboard添加自定義IP核完成簡易計算器功能

將GPIO_LED_Out和GPIO_SW_In配置為External Ports,這樣我理解是利用External Ports就可以對外設(shè)進行連接,外設(shè)看到的端口名稱為my_calc_v1_0_GPIO_LED_Out_pin,和my_calc_v1_0_GPIO_SW_In_pin。

進行完端口的配置后,就可以進行約束文件的建立,將端口映射到FPGA的具體引腳上,約束文件如下:

#

# pin constraints

#

#

NET “my_calc_v1_0_GPIO_LED_Out_pin[0]” LOC = T22;

NET “my_calc_v1_0_GPIO_LED_Out_pin[1]” LOC = T21;

NET “my_calc_v1_0_GPIO_LED_Out_pin[2]” LOC = U22;

NET “my_calc_v1_0_GPIO_LED_Out_pin[3]” LOC = U21;

NET “my_calc_v1_0_GPIO_LED_Out_pin[4]” LOC = V22;

NET “my_calc_v1_0_GPIO_LED_Out_pin[5]” LOC = W22;

NET “my_calc_v1_0_GPIO_LED_Out_pin[6]” LOC = U19;

NET “my_calc_v1_0_GPIO_LED_Out_pin[7]” LOC = U14;

NET “my_calc_v1_0_GPIO_LED_Out_pin[0]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[1]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[2]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[3]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[4]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[5]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[6]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_LED_Out_pin[7]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[0]” LOC = F22;

NET “my_calc_v1_0_GPIO_SW_In_pin[1]” LOC = G22;

NET “my_calc_v1_0_GPIO_SW_In_pin[2]” LOC = H22;

NET “my_calc_v1_0_GPIO_SW_In_pin[3]” LOC = F21;

NET “my_calc_v1_0_GPIO_SW_In_pin[4]” LOC = H19;

NET “my_calc_v1_0_GPIO_SW_In_pin[5]” LOC = H18;

NET “my_calc_v1_0_GPIO_SW_In_pin[6]” LOC = H17;

NET “my_calc_v1_0_GPIO_SW_In_pin[7]” LOC = M15;

NET “my_calc_v1_0_GPIO_SW_In_pin[0]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[1]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[2]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[3]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[4]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[5]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[6]” IOSTANDARD = LVCMOS33;

NET “my_calc_v1_0_GPIO_SW_In_pin[7]” IOSTANDARD = LVCMOS33;

# additional constraints

#

完成后,XPS端的配置就完成,點擊Generate BitStream生成bit文件,成功后導(dǎo)出的SDK

在進入SDK后,我們可以在system.xml文件中可以看到建立的IP核搭建的PL部分被當作外設(shè)映射到PS端,映射地址為0x78c00000

利用zedboard添加自定義IP核完成簡易計算器功能

在此后我們只需要根據(jù)C語言的知識,對此地址端進行編程即可,下面邏輯就不再展開敘述,具體代碼如下,寫的比較亂

/*

* Copyright (c) 2009 Xilinx, Inc. All rights reserved.

*

* Xilinx, Inc.

* XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION “AS IS” AS A

* COURTESY TO YOU. BY PROVIDING THIS DESIGN, CODE, OR INFORMATION AS

* ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE, APPLICATION OR

* STANDARD, XILINX IS MAKING NO REPRESENTATION THAT THIS IMPLEMENTATION

* IS FREE FROM ANY CLAIMS OF INFRINGEMENT, AND YOU ARE RESPONSIBLE

* FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE FOR YOUR IMPLEMENTATION.

* XILINX EXPRESSLY DISCLAIMS ANY WARRANTY WHATSOEVER WITH RESPECT TO

* THE ADEQUACY OF THE IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO

* ANY WARRANTIES OR REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE

* FROM CLAIMS OF INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY

* AND FITNESS FOR A PARTICULAR PURPOSE.

*

*/

/*

* helloworld.c: simple test application

*/

#include

#include “platform.h”

#define SW (* (volatile unsigned int *) 0x78C00000) //

#define LED (* (volatile unsigned int *) 0x78C00004) //

#define ADD1 (* (volatile unsigned int *) 0x78C00008) // 第一個寄存器地址---加數(shù)一

#define ADD2 (* (volatile unsigned int *) 0x78C0000C) // 第二個寄存器地址---加數(shù)二

#define SUM (* (volatile unsigned int *) 0x78C00010) // 第三個寄存器地址---和

//void print(char *str);

int main()

{

init_platform();

printf(“Hello World\n\r”);

printf(“Please input the first operator:\n\r”);

scanf(“%d”, &ADD1);

printf(“Please second the first operator:\n\r”);

scanf(“%d”, &ADD2);

if(SW == 0x01)

{

printf(“The result of ADD1 + ADD2 = %d\n\r”, SUM);

}

else if(SW == 0x02)

{

printf(“The result of ADD1 - ADD2 = %d\n\r”, SUM);

}

LED = SUM;

聲明:本文內(nèi)容及配圖由入駐作者撰寫或者入駐合作網(wǎng)站授權(quán)轉(zhuǎn)載。文章觀點僅代表作者本人,不代表電子發(fā)燒友網(wǎng)立場。文章及其配圖僅供工程師學(xué)習(xí)之用,如有內(nèi)容侵權(quán)或者其他違規(guī)問題,請聯(lián)系本站處理。 舉報投訴
  • IP核
    +關(guān)注

    關(guān)注

    4

    文章

    329

    瀏覽量

    49529
  • Zedboard
    +關(guān)注

    關(guān)注

    45

    文章

    70

    瀏覽量

    49234
收藏 人收藏

    評論

    相關(guān)推薦

    nios 自定義ip問題求助

    sopc builder中添加自定義ip,編寫自定義ip的時候, avalon接口信號:clk
    發(fā)表于 11-26 11:11

    【Z-turn Board試用體驗】+ 【第六貼】:為ZYNQ的SOC添加自定義IP實現(xiàn)嵌入式系統(tǒng)

    ;Re-Package IP完成IP的定制并自動關(guān)閉編輯IP的工程1.6同理添加LM75的IP
    發(fā)表于 06-11 23:52

    xilinx vivado 怎么封裝包含一個ip自定義ip?

    我寫了一個緩存模塊,里面包含有一個BlockRAM的IP,現(xiàn)在想把這個緩存模塊封裝成我的一個自定義ip,但是封裝完成之后仿真的時候會報錯
    發(fā)表于 12-11 10:25

    玩轉(zhuǎn)Zynq連載24——用戶自定義IP的移植

    `玩轉(zhuǎn)Zynq連載24——用戶自定義IP的移植更多資料共享騰訊微云鏈接:https://share.weiyun.com/5s6bA0s百度網(wǎng)盤鏈接:https://pan.baidu.com/s
    發(fā)表于 09-15 09:55

    玩轉(zhuǎn)Zynq連載25——[ex04] 基于Zynq PL的自定義IP集成

    ,添加到Vivado的IP Catalog中,然后和標準IP一樣,在Vivado工程中配置添加這個IP
    發(fā)表于 09-20 11:35

    如何在Libero的開發(fā)環(huán)境下封裝通用的自定義IP?請各位大俠指點!

    如何在Libero的開發(fā)環(huán)境下封裝通用的自定義IP?請各位大俠指點!
    發(fā)表于 11-13 23:09

    基于Avalon總線SHT11溫濕度傳感自定義IP的開發(fā)流程

    本文介紹了基于Avalon總線SHT11溫濕度傳感自定義IP的開發(fā)流程,利用有限狀態(tài)機設(shè)計了驅(qū)動硬件邏輯,并且基于NiosII嵌入式處理
    發(fā)表于 01-28 18:41 ?4177次閱讀
    基于Avalon總線SHT11溫濕度傳感<b class='flag-5'>器</b><b class='flag-5'>自定義</b><b class='flag-5'>IP</b><b class='flag-5'>核</b>的開發(fā)流程

    c51簡易計算器

    c51簡易計算器 c51簡易計算器c51簡易計算器c51
    發(fā)表于 11-12 17:04 ?105次下載

    添加自定義IP基本步驟

    FPGA的IP設(shè)計技術(shù)的系列資料,大家可以收集看下,這些都是我看過過濾后留下的,感覺不錯,希望對大家有幫助
    發(fā)表于 11-30 17:47 ?5次下載

    EDK中PS2自定義IP

    Xilinx FPGA工程例子源碼:EDK中PS2自定義IP
    發(fā)表于 06-07 11:44 ?4次下載

    自定義sobel濾波IPIP接口遵守AXI Stream協(xié)議

    自定義sobel濾波IP IP接口遵守AXI Stream協(xié)議
    的頭像 發(fā)表于 08-06 06:04 ?3930次閱讀

    自定義視圖組件教程案例

    自定義組件 1.自定義組件-particles(粒子效果) 2.自定義組件- pulse(脈沖button效果) 3.自定義組件-progress(progress效果) 4.
    發(fā)表于 04-08 10:48 ?14次下載

    教程 2:添加特征-自定義配置文件創(chuàng)建

    教程 2:添加特征 - 自定義配置文件創(chuàng)建
    發(fā)表于 03-15 19:39 ?0次下載
    教程 2:<b class='flag-5'>添加</b>特征-<b class='flag-5'>自定義</b>配置文件創(chuàng)建

    教程 2:添加特征-自定義配置文件創(chuàng)建

    教程 2:添加特征 - 自定義配置文件創(chuàng)建
    發(fā)表于 07-06 18:50 ?0次下載
    教程 2:<b class='flag-5'>添加</b>特征-<b class='flag-5'>自定義</b>配置文件創(chuàng)建

    添加自定義屬性控制fridaserver啟動和停止

    添加自定義屬性控制fridaserver啟動和停止
    的頭像 發(fā)表于 08-09 10:08 ?1750次閱讀
    <b class='flag-5'>添加</b><b class='flag-5'>自定義</b>屬性控制fridaserver啟動和停止