Skip to content

Commit

Permalink
add buttons test
Browse files Browse the repository at this point in the history
  • Loading branch information
liibin authored and yangke committed Apr 21, 2022
1 parent abe0e73 commit 62460f8
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
10 changes: 10 additions & 0 deletions xc/xc7/tests/buttons/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -159,3 +159,13 @@ add_vivado_target(
# NAME buttons_marszx3_vivado
# PARENT_NAME buttons_marszx3
# )
add_file_target(FILE buttons_ax7050.xdc)
add_file_target(FILE buttons_ax7050.v SCANNER_TYPE verilog)
add_fpga_target(
NAME buttons_ax7050
BOARD ax7050
SOURCES buttons_ax7050.v
INPUT_XDC_FILES buttons_ax7050.xdc
EXPLICIT_ADD_FILE_TARGET
)

8 changes: 8 additions & 0 deletions xc/xc7/tests/buttons/buttons_ax7050.v
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
`timescale 1ns/1ps
module top (

input wire [1:0] sw,
output wire [1:0] led,
);
assign led = sw;
endmodule
21 changes: 21 additions & 0 deletions xc/xc7/tests/buttons/buttons_ax7050.xdc
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@

############## NET - IOSTANDARD ##################
set_property CFGBVS VCCO [current_design]
set_property CONFIG_VOLTAGE 3.3 [current_design]
#############SPI Configurate Setting##################
set_property BITSTREAM.CONFIG.SPI_BUSWIDTH 4 [current_design]
set_property CONFIG_MODE SPIx4 [current_design]
set_property BITSTREAM.CONFIG.CONFIGRATE 50 [current_design]
set_property BITSTREAM.GENERAL.CRC Disable [current_design]
#############LED Setting###########################
set_property PACKAGE_PIN H16 [get_ports {led[0]}]
set_property IOSTANDARD LVCMOS33 [get_ports {led[0]}]

set_property PACKAGE_PIN G16 [get_ports {led[1]}]
set_property IOSTANDARD LVCMOS33 [get_ports {led[1]}]

set_property PACKAGE_PIN M15 [get_ports {sw[0]}]
set_property IOSTANDARD LVCMOS33 [get_ports {sw[0]}]

set_property PACKAGE_PIN L15 [get_ports {sw[1]}]
set_property IOSTANDARD LVCMOS33 [get_ports {sw[1]}]

0 comments on commit 62460f8

Please sign in to comment.