-
Notifications
You must be signed in to change notification settings - Fork 1.7k
projects/admx100x_evb: Add RX part to the project #2013
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| ############################################################################### | ||
| ## Copyright (C) 2026 Analog Devices, Inc. All rights reserved. | ||
| ### SPDX short identifier: ADIBSD | ||
| ############################################################################### | ||
|
|
||
| create_bd_intf_port -mode Master -vlnv analog.com:interface:spi_engine_rtl:1.0 adc_spi | ||
|
|
||
| create_bd_port -dir I adc_data_ready | ||
| create_bd_port -dir O mclk_clk | ||
|
|
||
| # create a SPI Engine architecture for ADC | ||
|
|
||
| source $ad_hdl_dir/library/spi_engine/scripts/spi_engine.tcl | ||
|
|
||
| set data_width 32 | ||
| set async_spi_clk 1 | ||
| set num_cs 1 | ||
| set num_sdi 1 | ||
| set num_sdo 1 | ||
| set sdi_delay 1 | ||
| set echo_sclk 0 | ||
|
|
||
| set hier_spi_engine spi_adaq77681 | ||
|
|
||
| spi_engine_create $hier_spi_engine $data_width $async_spi_clk $num_cs $num_sdi $num_sdo $sdi_delay $echo_sclk | ||
|
|
||
| ad_ip_parameter $hier_spi_engine/${hier_spi_engine}_offload CONFIG.ASYNC_TRIG 1 | ||
|
|
||
| ad_ip_instance axi_clkgen spi_clkgen | ||
| ad_ip_parameter spi_clkgen CONFIG.CLK0_DIV 5 | ||
| ad_ip_parameter spi_clkgen CONFIG.VCO_DIV 1 | ||
| ad_ip_parameter spi_clkgen CONFIG.VCO_MUL 8 | ||
|
|
||
| ad_ip_instance clk_wiz mclk_clk_wiz | ||
| ad_ip_parameter mclk_clk_wiz CONFIG.PRIMITIVE MMCM | ||
| ad_ip_parameter mclk_clk_wiz CONFIG.RESET_TYPE ACTIVE_LOW | ||
| ad_ip_parameter mclk_clk_wiz CONFIG.USE_LOCKED false | ||
| ad_ip_parameter mclk_clk_wiz CONFIG.CLKOUT1_REQUESTED_OUT_FREQ 16.384 | ||
| ad_ip_parameter mclk_clk_wiz CONFIG.PRIM_SOURCE No_buffer | ||
|
|
||
| # dma for the ADC | ||
|
|
||
| ad_ip_instance axi_dmac axi_adaq77681_dma | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.DMA_TYPE_SRC 1 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.DMA_TYPE_DEST 0 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.CYCLIC 0 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.SYNC_TRANSFER_START 0 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.AXI_SLICE_SRC 0 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.AXI_SLICE_DEST 1 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.DMA_2D_TRANSFER 0 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.DMA_DATA_WIDTH_SRC 32 | ||
| ad_ip_parameter axi_adaq77681_dma CONFIG.DMA_DATA_WIDTH_DEST 64 | ||
|
|
||
| ad_connect $sys_cpu_clk spi_clkgen/clk | ||
| ad_connect spi_clk spi_clkgen/clk_0 | ||
| ad_connect adc_data_ready $hier_spi_engine/trigger | ||
| ad_connect axi_adaq77681_dma/s_axis $hier_spi_engine/M_AXIS_SAMPLE | ||
| ad_connect $hier_spi_engine/m_spi adc_spi | ||
| ad_connect $sys_cpu_clk $hier_spi_engine/clk | ||
| ad_connect spi_clk $hier_spi_engine/spi_clk | ||
| ad_connect spi_clk axi_adaq77681_dma/s_axis_aclk | ||
| ad_connect sys_cpu_resetn $hier_spi_engine/resetn | ||
| ad_connect sys_cpu_resetn axi_adaq77681_dma/m_dest_axi_aresetn | ||
|
|
||
| ad_connect sys_cpu_clk mclk_clk_wiz/clk_in1 | ||
| ad_connect sys_cpu_resetn mclk_clk_wiz/resetn | ||
|
|
||
| ad_connect mclk_clk mclk_clk_wiz/clk_out1 | ||
|
|
||
| # AXI address definitions | ||
|
|
||
| ad_cpu_interconnect 0x44a00000 $hier_spi_engine/${hier_spi_engine}_axi_regmap | ||
| ad_cpu_interconnect 0x44a30000 axi_adaq77681_dma | ||
| ad_cpu_interconnect 0x44a70000 spi_clkgen | ||
|
|
||
| # interrupts | ||
|
|
||
| ad_cpu_interrupt "ps-13" "mb-13" axi_adaq77681_dma/irq | ||
| ad_cpu_interrupt "ps-12" "mb-12" $hier_spi_engine/irq | ||
|
|
||
| # memory interconnects | ||
|
|
||
| ad_mem_hp2_interconnect sys_cpu_clk sys_ps7/S_AXI_HP0 | ||
| ad_mem_hp2_interconnect sys_cpu_clk axi_adaq77681_dma/m_dest_axi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make the SPI ENGINE framework blocks bigger?