|
| 1 | +# *************************************************************************** |
| 2 | +# *************************************************************************** |
| 3 | +# Copyright 2024 (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 responsibilities 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 | +source ../../scripts/adi_env.tcl |
| 37 | + |
| 38 | +# system level parameters |
| 39 | + |
| 40 | +global ad_project_params |
| 41 | + |
| 42 | +# |
| 43 | +# Block design under test |
| 44 | +# |
| 45 | + |
| 46 | +source ../../projects/ad738x_fmc/common/ad738x_bd.tcl |
| 47 | + |
| 48 | + create_bd_port -dir O ad738x_spi_clk |
| 49 | + create_bd_port -dir O ad738x_irq |
| 50 | + |
| 51 | + ad_connect ad738x_spi_clk spi_clkgen/clk_0 |
| 52 | + ad_connect ad738x_irq spi_ad738x_adc/irq |
| 53 | + |
| 54 | +set BA_SPI_REGMAP 0x44A00000 |
| 55 | +set_property offset $BA_SPI_REGMAP [get_bd_addr_segs {mng_axi_vip/Master_AXI/spi_ad738x_adc_axi_regmap}] |
| 56 | +adi_sim_add_define "SPI_AD738x_REGMAP_BA=[format "%d" ${BA_SPI_REGMAP}]" |
| 57 | + |
| 58 | +set BA_DMA 0x44A30000 |
| 59 | +set_property offset $BA_DMA [get_bd_addr_segs {mng_axi_vip/Master_AXI/SEG_data_axi_ad738x_dma}] |
| 60 | +adi_sim_add_define "AD738x_DMA_BA=[format "%d" ${BA_DMA}]" |
| 61 | + |
| 62 | +set BA_PWM 0x44B00000 |
| 63 | +set_property offset $BA_PWM [get_bd_addr_segs {mng_axi_vip/Master_AXI/SEG_data_spi_trigger_gen}] |
| 64 | +adi_sim_add_define "AD738x_PWM_GEN_BA=[format "%d" ${BA_PWM}]" |
| 65 | + |
| 66 | +set BA_CLKGEN 0x44A70000 |
| 67 | +set_property offset $BA_CLKGEN [get_bd_addr_segs {mng_axi_vip/Master_AXI/SEG_data_spi_clkgen}] |
| 68 | +adi_sim_add_define "AD738x_AXI_CLKGEN_BA=[format "%d" ${BA_CLKGEN}]" |
0 commit comments