Skip to content

Commit 880f375

Browse files
ad719x_asdz/coraz7s: Initial commit
* Added interrupt on RDYn on GPIO 32 Signed-off-by: Iulia Moldovan <[email protected]>
1 parent 19c76d1 commit 880f375

File tree

7 files changed

+226
-0
lines changed

7 files changed

+226
-0
lines changed

projects/ad719x_asdz/Makefile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
####################################################################################
2+
## Copyright (c) 2018 - 2021 Analog Devices, Inc.
3+
### SPDX short identifier: BSD-1-Clause
4+
## Auto-generated, do not modify!
5+
####################################################################################
6+
7+
include ../scripts/project-toplevel.mk

projects/ad719x_asdz/README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# EVAL-AD719X-ASDZ HDL Project
2+
3+
This project supports EVAL-AD7190, EVAL-AD7193 and EVAL-AD7195.
4+
5+
Here are some pointers to help you:
6+
* [EVAL-AD7190 Board Product Page](https://www.analog.com/eval-ad7190)
7+
* [EVAL-AD7193 Board Product Page](https://www.analog.com/eval-ad7193)
8+
* [EVAL-AD7195 Board Product Page](https://www.analog.com/eval-ad7195)
9+
* Parts: AD7190 [Sigma-Delta ADC, SPI interface, 24-bit resolution, Data rate between 4.7Hz - 4.8kHz](https://www.analog.com/ad7190)
10+
* Parts: AD7193 [4-channel Sigma-Delta ADC, SPI interface, 24-bit resolution, Data rate between 4.7Hz - 4.8kHz](https://www.analog.com/ad7193)
11+
* Parts: AD7195 [Sigma-Delta ADC, SPI interface, 24-bit resolution, Data rate between 4.7Hz - 4.8kHz](https://www.analog.com/ad7195)
12+
* Project Doc: https://wiki.analog.com/resources/eval/adc/ad719x_asdz
13+
* HDL Doc: https://wiki.analog.com/resources/eval/adc/ad719x_asdz
14+
* Linux Drivers: https://wiki.analog.com/resources/tools-software/linux-drivers-all
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
####################################################################################
2+
## Copyright (c) 2018 - 2021 Analog Devices, Inc.
3+
### SPDX short identifier: BSD-1-Clause
4+
## Auto-generated, do not modify!
5+
####################################################################################
6+
7+
PROJECT_NAME := ad719x_asdz_coraz7s
8+
9+
M_DEPS += ../../scripts/adi_pd.tcl
10+
M_DEPS += ../../common/coraz7s/coraz7s_system_ps7.tcl
11+
M_DEPS += ../../common/coraz7s/coraz7s_system_constr.xdc
12+
M_DEPS += ../../common/coraz7s/coraz7s_system_bd.tcl
13+
M_DEPS += ../../../library/common/ad_iobuf.v
14+
15+
LIB_DEPS += axi_sysid
16+
LIB_DEPS += sysid_rom
17+
18+
include ../../scripts/project-xilinx.mk
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
source $ad_hdl_dir/projects/common/coraz7s/coraz7s_system_bd.tcl
2+
source $ad_hdl_dir/projects/scripts/adi_pd.tcl
3+
4+
# system ID
5+
ad_ip_parameter axi_sysid_0 CONFIG.ROM_ADDR_BITS 9
6+
ad_ip_parameter rom_sys_0 CONFIG.PATH_TO_FILE "[pwd]/mem_init_sys.txt"
7+
ad_ip_parameter rom_sys_0 CONFIG.ROM_ADDR_BITS 9
8+
set sys_cstring "sys rom custom string placeholder"
9+
10+
sysid_gen_sys_init_file
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# coraz7s
2+
3+
# ad719x spi connections
4+
5+
set_property -dict {PACKAGE_PIN Y17 IOSTANDARD LVCMOS33} [get_ports {adc_spi_sclk}]; # IO_L7N_T1_34 Sch=ja_n[2]
6+
set_property -dict {PACKAGE_PIN Y16 IOSTANDARD LVCMOS33} [get_ports {adc_spi_miso_rdyn}]; # IO_L7P_T1_34 Sch=ja_p[2]; AD719X sch=DOUT/RDY_N
7+
set_property -dict {PACKAGE_PIN Y19 IOSTANDARD LVCMOS33} [get_ports {adc_spi_mosi}]; # IO_L17N_T2_34 Sch=ja_n[1]; AD719X sch=DIN
8+
set_property -dict {PACKAGE_PIN Y18 IOSTANDARD LVCMOS33} [get_ports {adc_spi_csn}]; # IO_L17P_T2_34 Sch=ja_p[1]
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
source ../../../scripts/adi_env.tcl
2+
source $ad_hdl_dir/projects/scripts/adi_project_xilinx.tcl
3+
source $ad_hdl_dir/projects/scripts/adi_board.tcl
4+
5+
adi_project ad719x_asdz_coraz7s
6+
7+
adi_project_files ad719x_asdz_coraz7s [list \
8+
"$ad_hdl_dir/library/common/ad_iobuf.v" \
9+
"$ad_hdl_dir/projects/common/coraz7s/coraz7s_system_constr.xdc" \
10+
"system_constr.xdc" \
11+
"system_top.v"
12+
]
13+
14+
adi_project_run ad719x_asdz_coraz7s
Lines changed: 155 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
// ***************************************************************************
2+
// ***************************************************************************
3+
// Copyright 2022 (c) Analog Devices, Inc. All rights reserved.
4+
//
5+
// In this HDL repository, there are many different and unique modules, consisting
6+
// of various HDL (Verilog or VHDL) components. The individual modules are
7+
// developed independently, and may be accompanied by separate and unique license
8+
// terms.
9+
//
10+
// The user should read each of these license terms, and understand the
11+
// freedoms and responsabilities that he or she has by using this source/core.
12+
//
13+
// This core is distributed in the hope that it will be useful, but WITHOUT ANY
14+
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
15+
// A PARTICULAR PURPOSE.
16+
//
17+
// Redistribution and use of source or resulting binaries, with or without modification
18+
// of this file, are permitted under one of the following two license terms:
19+
//
20+
// 1. The GNU General Public License version 2 as published by the
21+
// Free Software Foundation, which can be found in the top level directory
22+
// of this repository (LICENSE_GPL2), and also online at:
23+
// <https://www.gnu.org/licenses/old-licenses/gpl-2.0.html>
24+
//
25+
// OR
26+
//
27+
// 2. An ADI specific BSD license, which can be found in the top level directory
28+
// of this repository (LICENSE_ADIBSD), and also on-line at:
29+
// https://github.com/analogdevicesinc/hdl/blob/master/LICENSE_ADIBSD
30+
// This will allow to generate bit files and not release the source code,
31+
// as long as it attaches to an ADI device.
32+
//
33+
// ***************************************************************************
34+
// ***************************************************************************
35+
36+
`timescale 1ns/100ps
37+
38+
module system_top (
39+
40+
inout [14:0] ddr_addr,
41+
inout [ 2:0] ddr_ba,
42+
inout ddr_cas_n,
43+
inout ddr_ck_n,
44+
inout ddr_ck_p,
45+
inout ddr_cke,
46+
inout ddr_cs_n,
47+
inout [ 3:0] ddr_dm,
48+
inout [31:0] ddr_dq,
49+
inout [ 3:0] ddr_dqs_n,
50+
inout [ 3:0] ddr_dqs_p,
51+
inout ddr_odt,
52+
inout ddr_ras_n,
53+
inout ddr_reset_n,
54+
inout ddr_we_n,
55+
56+
inout fixed_io_ddr_vrn,
57+
inout fixed_io_ddr_vrp,
58+
inout [53:0] fixed_io_mio,
59+
inout fixed_io_ps_clk,
60+
inout fixed_io_ps_porb,
61+
inout fixed_io_ps_srstb,
62+
63+
inout [ 1:0] btn,
64+
inout [ 5:0] led,
65+
66+
// ad7190 spi pins
67+
68+
output adc_spi_sclk,
69+
input adc_spi_miso_rdyn,
70+
output adc_spi_mosi,
71+
output adc_spi_csn
72+
);
73+
74+
// internal signals
75+
76+
wire [63:0] gpio_i;
77+
wire [63:0] gpio_o;
78+
wire [63:0] gpio_t;
79+
80+
// instantiations
81+
82+
ad_iobuf #(
83+
.DATA_WIDTH (2)
84+
) i_iobuf_buttons (
85+
.dio_t (gpio_t[1:0]),
86+
.dio_i (gpio_o[1:0]),
87+
.dio_o (gpio_i[1:0]),
88+
.dio_p (btn));
89+
90+
ad_iobuf #(
91+
.DATA_WIDTH (6)
92+
) i_iobuf_leds (
93+
.dio_t (gpio_t[7:2]),
94+
.dio_i (gpio_o[7:2]),
95+
.dio_o (gpio_i[7:2]),
96+
.dio_p (led));
97+
98+
// project specific gpios
99+
100+
assign gpio_i[63:33] = gpio_o[63:33];
101+
assign gpio_i[32] = adc_spi_miso_rdyn;
102+
103+
// board specific gpios
104+
105+
assign gpio_i[31:8] = gpio_o[31:8];
106+
107+
system_wrapper i_system_wrapper (
108+
.ddr_addr (ddr_addr),
109+
.ddr_ba (ddr_ba),
110+
.ddr_cas_n (ddr_cas_n),
111+
.ddr_ck_n (ddr_ck_n),
112+
.ddr_ck_p (ddr_ck_p),
113+
.ddr_cke (ddr_cke),
114+
.ddr_cs_n (ddr_cs_n),
115+
.ddr_dm (ddr_dm),
116+
.ddr_dq (ddr_dq),
117+
.ddr_dqs_n (ddr_dqs_n),
118+
.ddr_dqs_p (ddr_dqs_p),
119+
.ddr_odt (ddr_odt),
120+
.ddr_ras_n (ddr_ras_n),
121+
.ddr_reset_n (ddr_reset_n),
122+
.ddr_we_n (ddr_we_n),
123+
124+
.fixed_io_ddr_vrn (fixed_io_ddr_vrn),
125+
.fixed_io_ddr_vrp (fixed_io_ddr_vrp),
126+
.fixed_io_mio (fixed_io_mio),
127+
.fixed_io_ps_clk (fixed_io_ps_clk),
128+
.fixed_io_ps_porb (fixed_io_ps_porb),
129+
.fixed_io_ps_srstb (fixed_io_ps_srstb),
130+
131+
.gpio_i (gpio_i),
132+
.gpio_o (gpio_o),
133+
.gpio_t (gpio_t),
134+
135+
.spi0_clk_i (1'b0),
136+
.spi0_clk_o (adc_spi_sclk),
137+
.spi0_csn_0_o (adc_spi_csn),
138+
.spi0_csn_1_o (),
139+
.spi0_csn_2_o (),
140+
.spi0_csn_i (1'b0),
141+
.spi0_sdi_i (adc_spi_miso_rdyn),
142+
.spi0_sdo_i (1'b0),
143+
.spi0_sdo_o (adc_spi_mosi),
144+
145+
.spi1_clk_i (1'b0),
146+
.spi1_clk_o (),
147+
.spi1_csn_0_o (),
148+
.spi1_csn_1_o (),
149+
.spi1_csn_2_o (),
150+
.spi1_csn_i (1'b1),
151+
.spi1_sdi_i (1'b0),
152+
.spi1_sdo_i (1'b0),
153+
.spi1_sdo_o ());
154+
155+
endmodule

0 commit comments

Comments
 (0)