Skip to content

Commit c3de7dc

Browse files
Add Altera Modular Dev Kit board
This commit adds the Altera Modular Dev Kit board to the example repo. Signed-off-by: Rod Frazer <rod.frazer@altera.com>
1 parent cb0d0c0 commit c3de7dc

File tree

20 files changed

+4638
-0
lines changed

20 files changed

+4638
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ The project build instructions are documented [**here**](./documentation/17_buil
2828
| Repo Directory | Board Info |
2929
| :--- | :--- |
3030
| brd_altera_a5e065_premium_es | **Company:** Altera Corporation<br>**Board Name:** Agilex* 5 FPGA E-Series 065B Premium Development Kit<br>**OPN:** DK-A5E065BB32AES1<br>**Comment:** ES device |
31+
| brd_altera_a5e065_modular_es | **Company:** Altera Corporation<br>**Board Name:** Agilex* 5 FPGA E-Series 065B Modular Development Kit<br>**OPN:** MK-A5E065BB32AES1<br>**Comment:** ES device |
3132
| brd_arrow_axe5_eagle_es | **Company:** Arrow Electronics, Inc.<br>**Board Name:** Arrow AXE5-Eagle Development Platform<br>**OPN:** AXE5-EAGLE-ES<br>**Comment:** ES device |
3233
| brd_criticallink_mitysbc_es | **Company:** Critical Link, LLC<br>**Board Name:** MitySBC-A5E Single Board Computer<br>**OPN:** A5ED-B9-C7F-RC-SBC-X<br>**Comment:** ES device |
3334
| brd_macnica_sulfur_es_125 | **Company:** Macnica, Inc.<br>**Board Name:** Macnica Mpression Sulfur Kit / Type A<br>**OPN:** ALTSULFUR_A5ED065B_E5_ES0_typeA<br>**Comment:** ES device - 125MHz SDM_OSC_CLK |

brd_altera_a5e065_modular_es/hw_base/a55_do_create_no_pins_hps.tcl

Lines changed: 1999 additions & 0 deletions
Large diffs are not rendered by default.

brd_altera_a5e065_modular_es/hw_base/a76_do_create_no_pins_hps.tcl

Lines changed: 1999 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
#
2+
# SPDX-FileCopyrightText: Copyright (C) 2025 Altera Corporation
3+
# SPDX-License-Identifier: MIT-0
4+
#
5+
6+
#
7+
# This script is created by first going into Quartus and select the menu:
8+
# Project -> Organize Quartus Prime Settings File
9+
#
10+
# Then export the project to TCL:
11+
# Project -> Generate Tcl File for Project...
12+
#
13+
# We then take that TCL file and reformat it for our needs. We discard ancilary
14+
# settings that are of no real use and we remove all .qsys and .ip references
15+
# because we will restore those into future project creations as we reconstruct
16+
# the project from raw source.
17+
#
18+
# The default format of the pin assignments may or may not be desirable, it will
19+
# list all pin locations first followed by all pin instance assignments. If we
20+
# wish to sort this list placing all assignments for a given pin together, we
21+
# can do this:
22+
#
23+
# Duplicate the original generated TCL file and call it pins_only.tcl. Edit the
24+
# file to remove all entries but the pin assignments. Also remove any entity
25+
# references at the ends of any lines, each line should end with the
26+
# "-to <target>" value. Then we can run this command line to sort the pin
27+
# assignments:
28+
#
29+
# []$ awk '{print $NF,$0}' pins_only.tcl | sort -s -k 1,1 | cut -f2- -d' ' > sorted_pins_only.tcl
30+
#
31+
32+
package require ::quartus::project
33+
34+
set PROJECT_NAME "no_pins_top"
35+
if [project_exists $PROJECT_NAME] {
36+
post_message -type error "project already exists..."
37+
post_message -type error "'$PROJECT_NAME'"
38+
qexit -error
39+
}
40+
project_new $PROJECT_NAME
41+
42+
set_global_assignment -name PROJECT_OUTPUT_DIRECTORY output_files
43+
set_global_assignment -name VERILOG_FILE ../hw_base/no_pins_top.v
44+
set_global_assignment -name MIN_CORE_JUNCTION_TEMP 0
45+
set_global_assignment -name MAX_CORE_JUNCTION_TEMP 100
46+
set_global_assignment -name FAMILY "Agilex 5"
47+
set_global_assignment -name TOP_LEVEL_ENTITY no_pins_top
48+
set_global_assignment -name BOARD default
49+
set_global_assignment -name DEVICE A5ED065BB32AE6SR0
50+
set_global_assignment -name ERROR_CHECK_FREQUENCY_DIVISOR 256
51+
set_global_assignment -name STRATIXV_CONFIGURATION_SCHEME "ACTIVE SERIAL X4"
52+
set_global_assignment -name ACTIVE_SERIAL_CLOCK AS_FREQ_100MHZ
53+
set_global_assignment -name DEVICE_INITIALIZATION_CLOCK OSC_CLK_1_125MHZ
54+
set_global_assignment -name USE_HPS_COLD_RESET SDM_IO10
55+
set_global_assignment -name USE_CONF_DONE SDM_IO16
56+
set_global_assignment -name VID_OPERATION_MODE "PMBUS MASTER"
57+
set_global_assignment -name USE_PWRMGT_SCL SDM_IO0
58+
set_global_assignment -name USE_PWRMGT_SDA SDM_IO16
59+
set_global_assignment -name PWRMGT_BUS_SPEED_MODE "400 KHZ"
60+
set_global_assignment -name PWRMGT_PAGE_COMMAND_ENABLE ON
61+
set_global_assignment -name PWRMGT_SLAVE_DEVICE_TYPE OTHER
62+
set_global_assignment -name PWRMGT_SLAVE_DEVICE0_ADDRESS 74
63+
set_global_assignment -name PWRMGT_SLAVE_DEVICE1_ADDRESS 75
64+
set_global_assignment -name PWRMGT_SLAVE_DEVICE2_ADDRESS 00
65+
set_global_assignment -name PWRMGT_SLAVE_DEVICE3_ADDRESS 00
66+
set_global_assignment -name PWRMGT_SLAVE_DEVICE4_ADDRESS 00
67+
set_global_assignment -name PWRMGT_SLAVE_DEVICE5_ADDRESS 00
68+
set_global_assignment -name PWRMGT_SLAVE_DEVICE6_ADDRESS 00
69+
set_global_assignment -name PWRMGT_SLAVE_DEVICE7_ADDRESS 00
70+
set_global_assignment -name PWRMGT_VOLTAGE_OUTPUT_FORMAT "LINEAR FORMAT"
71+
set_global_assignment -name PWRMGT_LINEAR_FORMAT_N "-12"
72+
set_global_assignment -name PWRMGT_TRANSLATED_VOLTAGE_VALUE_UNIT VOLTS
73+
set_global_assignment -name NUMBER_OF_SLAVE_DEVICE 2
74+
set_global_assignment -name ON_CHIP_BITSTREAM_DECOMPRESSION OFF
75+
set_global_assignment -name HPS_DAP_SPLIT_MODE "SDM PINS"
76+
set_global_assignment -name HPS_DAP_NO_CERTIFICATE on
77+
set_global_assignment -name AUTO_RESTART_CONFIGURATION OFF
78+
set_global_assignment -name ENABLE_SIGNALTAP OFF
79+
set_global_assignment -name POWER_APPLY_THERMAL_MARGIN ADDITIONAL
80+
set_global_assignment -name STRATIX_JTAG_USER_CODE 55555555
81+
set_global_assignment -name USE_CHECKSUM_AS_USERCODE OFF
82+
set_global_assignment -name HPS_INITIALIZATION "HPS FIRST"
83+
set_global_assignment -name QSPI_OWNERSHIP HPS
84+
85+
export_assignments
86+
87+
project_close
88+
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<!--
2+
3+
SPDX-FileCopyrightText: Copyright (C) 2024 Intel Corporation
4+
SPDX-License-Identifier: MIT-0
5+
6+
-->
7+
8+
<library>
9+
<path path="../../custom_ip/**/*" >
10+
<tag2 key="COMPONENT_IN_PROJECT" value="true" />
11+
</path>
12+
<plugin
13+
name="DDR4-1600L_800MHz_CL12_alloff_component_1CS_DDP_32Gb_2Gx16.qprs"
14+
file="../hw_base/DDR4-1600L_800MHz_CL12_alloff_component_1CS_DDP_32Gb_2Gx16.qprs"
15+
displayName="DDR4-1600L_800MHz_CL12_alloff_component_1CS_DDP_32Gb_2Gx16.qprs"
16+
version="0.0"
17+
description=""
18+
tags=""
19+
categories=""
20+
type="com.altera.sopcmodel.util.IElementPresetList"
21+
subtype=""
22+
factory="PresetFactory">
23+
<tag2 key="PRESET_TYPE" value="emif_ph2_phy_arch_fp" />
24+
</plugin>
25+
</library>
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
/*
2+
* SPDX-FileCopyrightText: Copyright (C) 2024 Intel Corporation
3+
* SPDX-License-Identifier: MIT-0
4+
*/
5+
6+
`timescale 1ns/10ps
7+
8+
module no_pins_top (
9+
10+
input hps_osc_clk,
11+
12+
output hps_uart0_TX,
13+
input hps_uart0_RX,
14+
15+
output wire emif_hps_emif_mem_0_mem_ck_t,
16+
output wire emif_hps_emif_mem_0_mem_ck_c,
17+
output wire [16:0] emif_hps_emif_mem_0_mem_a,
18+
output wire emif_hps_emif_mem_0_mem_act_n,
19+
output wire [1:0] emif_hps_emif_mem_0_mem_ba,
20+
output wire [1:0] emif_hps_emif_mem_0_mem_bg,
21+
output wire emif_hps_emif_mem_0_mem_cke,
22+
output wire emif_hps_emif_mem_0_mem_cs_n,
23+
output wire emif_hps_emif_mem_0_mem_odt,
24+
output wire emif_hps_emif_mem_0_mem_reset_n,
25+
output wire emif_hps_emif_mem_0_mem_par,
26+
input wire emif_hps_emif_mem_0_mem_alert_n,
27+
input wire emif_hps_emif_oct_0_oct_rzqin,
28+
input wire emif_hps_emif_ref_clk_0_clk,
29+
inout wire [3:0] emif_hps_emif_mem_0_mem_dqs_t,
30+
inout wire [3:0] emif_hps_emif_mem_0_mem_dqs_c,
31+
inout wire [31:0] emif_hps_emif_mem_0_mem_dq
32+
);
33+
34+
no_pins_pd_top hps_system (
35+
36+
.hps_io_hps_osc_clk (hps_osc_clk),
37+
38+
.hps_io_uart0_tx (hps_uart0_TX),
39+
.hps_io_uart0_rx (hps_uart0_RX),
40+
41+
.emif_bank3a_hps_mem_ck_0_mem_ck_t (emif_hps_emif_mem_0_mem_ck_t),
42+
.emif_bank3a_hps_mem_ck_0_mem_ck_c (emif_hps_emif_mem_0_mem_ck_c),
43+
.emif_bank3a_hps_mem_0_mem_a (emif_hps_emif_mem_0_mem_a),
44+
.emif_bank3a_hps_mem_0_mem_act_n (emif_hps_emif_mem_0_mem_act_n),
45+
.emif_bank3a_hps_mem_0_mem_ba (emif_hps_emif_mem_0_mem_ba),
46+
.emif_bank3a_hps_mem_0_mem_bg (emif_hps_emif_mem_0_mem_bg),
47+
.emif_bank3a_hps_mem_0_mem_cke (emif_hps_emif_mem_0_mem_cke),
48+
.emif_bank3a_hps_mem_0_mem_cs_n (emif_hps_emif_mem_0_mem_cs_n),
49+
.emif_bank3a_hps_mem_0_mem_odt (emif_hps_emif_mem_0_mem_odt),
50+
.emif_bank3a_hps_mem_reset_n_mem_reset_n (emif_hps_emif_mem_0_mem_reset_n),
51+
.emif_bank3a_hps_mem_0_mem_par (emif_hps_emif_mem_0_mem_par),
52+
.emif_bank3a_hps_mem_0_mem_alert_n (emif_hps_emif_mem_0_mem_alert_n),
53+
.emif_bank3a_hps_mem_0_mem_dqs_t (emif_hps_emif_mem_0_mem_dqs_t),
54+
.emif_bank3a_hps_mem_0_mem_dqs_c (emif_hps_emif_mem_0_mem_dqs_c),
55+
.emif_bank3a_hps_mem_0_mem_dq (emif_hps_emif_mem_0_mem_dq),
56+
.emif_bank3a_hps_oct_0_oct_rzqin (emif_hps_emif_oct_0_oct_rzqin),
57+
.emif_bank3a_hps_ref_clk_clk (emif_hps_emif_ref_clk_0_clk)
58+
);
59+
60+
endmodule
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/bin/bash
2+
#
3+
# SPDX-FileCopyrightText: Copyright (C) 2024 Intel Corporation
4+
# SPDX-License-Identifier: MIT-0
5+
#
6+
7+
# change into the directory of this script
8+
cd $(dirname ${0})
9+
10+
IMAGE_BUILD_SCRIPTS="
11+
../../common_images/build_demos_fit_image.sh
12+
../../common_images/build_jic_image.sh
13+
../../common_images/create_attribution.sh
14+
../../common_images/fit_no-pins-demos.its
15+
../../common_images/fit_lzma-no-pins-demos.its
16+
../../common_images/jic_no-pins-demos.pfg
17+
"
18+
19+
for NEXT in ${IMAGE_BUILD_SCRIPTS:?}
20+
do
21+
[ -f "$(basename "${NEXT:?}")" ] || {
22+
cp -s -t ./ "${NEXT:?}" || { echo "ERROR" ; exit 1 ; }
23+
echo "Created symbolic link for '$(basename ${NEXT:?})'"
24+
}
25+
done
26+
27+
./build_jic_image.sh || { echo "ERROR" ; exit 1 ; }
28+
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#!/bin/bash
2+
#
3+
# SPDX-FileCopyrightText: Copyright (C) 2024 Intel Corporation
4+
# SPDX-License-Identifier: MIT-0
5+
#
6+
7+
# change into the directory of this script
8+
cd $(dirname ${0})
9+
10+
cp -s \
11+
-t ./ \
12+
../common_build_scripts/build_hw.sh \
13+
../common_build_scripts/check_hw_build.sh \
14+
../common_build_scripts/create_bitstreams.sh \
15+
../common_build_scripts/hw_build_dirs.src \
16+
|| { echo "ERROR" ; exit 1 ; }
17+
18+
# source the hardware build directories variable declaration
19+
. ./hw_build_dirs.src
20+
21+
for NEXT_BUILD_DIR in ${HW_BUILD_DIRECTORIES:?}
22+
do
23+
echo "Creating hardware directory: '${NEXT_BUILD_DIR:?}'"
24+
mkdir "${NEXT_BUILD_DIR:?}" && \
25+
ln -s \
26+
../../common_build_scripts/uart0_init_proj.sh \
27+
./${NEXT_BUILD_DIR:?}/init_proj.sh \
28+
|| { echo "ERROR" ; exit 1 ; }
29+
done
30+
Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
#!/bin/bash
2+
#
3+
# SPDX-FileCopyrightText: Copyright (C) 2024 Intel Corporation
4+
# SPDX-FileCopyrightText: Copyright (C) 2025 Altera Corporation
5+
# SPDX-License-Identifier: MIT-0
6+
#
7+
8+
TAG_NAME="QPDS25.1_REL_GSRD_PR"
9+
10+
# change into the directory of this script
11+
cd $(dirname ${0})
12+
13+
# extract the musl compiler if we don't already have it
14+
[ -d aarch64-linux-musleabi-cross ] || {
15+
tar xf ../../repo_downloads/aarch64-linux-musleabi-cross.tar.xz \
16+
|| { echo "ERROR" ; exit 1 ; }
17+
}
18+
19+
# configure the cross compile environment
20+
export CROSS_COMPILE=$(realpath aarch64-linux-musleabi-cross/bin/aarch64-linux-musleabi-)
21+
export ARCH=arm64
22+
23+
# verify that the tools we need are available in the environment
24+
TOOLS_REQUIRED="
25+
${CROSS_COMPILE:?}gcc \
26+
git \
27+
make \
28+
rsync
29+
"
30+
ERROR_DETECTED=0
31+
for NEXT_TOOL in ${TOOLS_REQUIRED:?}
32+
do
33+
type -P "${NEXT_TOOL}" > /dev/null 2>&1 || {
34+
echo "ERROR: required tool is not avaialble in environment"
35+
echo "'${NEXT_TOOL}'"
36+
ERROR_DETECTED=1
37+
}
38+
done
39+
[ ${ERROR_DETECTED} -ne 0 ] && {
40+
exit 1
41+
}
42+
43+
# check if source repos already exists
44+
[ -d ./arm-trusted-firmware ] && {
45+
echo "INFO: arm-trusted-firmware directory already exists"
46+
exit 0
47+
}
48+
49+
[ -d ./u-boot-socfpga ] && {
50+
echo "INFO: u-boot-socfpga directory already exists"
51+
exit 0
52+
}
53+
54+
# build the bootloaders
55+
tar xf ../../repo_downloads/arm-trusted-firmware-${TAG_NAME:?}.tgz \
56+
|| { echo "ERROR" ; exit 1 ; }
57+
58+
mv arm-trusted-firmware-${TAG_NAME:?} arm-trusted-firmware \
59+
|| { echo "ERROR" ; exit 1 ; }
60+
61+
tar xf ../../repo_downloads/u-boot-socfpga-${TAG_NAME:?}.tgz \
62+
|| { echo "ERROR" ; exit 1 ; }
63+
64+
mv u-boot-socfpga-${TAG_NAME:?} u-boot-socfpga \
65+
|| { echo "ERROR" ; exit 1 ; }
66+
67+
cd arm-trusted-firmware || { echo "ERROR" ; exit 1 ; }
68+
69+
make -j 48 PLAT=agilex5 bl31 || { echo "ERROR" ; exit 1 ; }
70+
71+
cd ../u-boot-socfpga || { echo "ERROR" ; exit 1 ; }
72+
73+
make mrproper || { echo "ERROR" ; exit 1 ; }
74+
75+
make socfpga_agilex5_defconfig || { echo "ERROR" ; exit 1 ; }
76+
77+
ln -s ../arm-trusted-firmware/build/agilex5/release/bl31.bin \
78+
|| { echo "ERROR" ; exit 1 ; }
79+
80+
./scripts/kconfig/merge_config.sh -O ./ ./.config \
81+
../../../common_sw/u-boot_patches/config-fragment \
82+
|| { echo "ERROR" ; exit 1 ; }
83+
84+
PATCH_FILES="
85+
../../../common_sw/u-boot_patches/include-exports.h.patch \
86+
../../../common_sw/u-boot_patches/include-configs-socfpga_soc64_common.h.patch \
87+
../../../common_sw/u-boot_patches/include-_exports.h.patch \
88+
../../../common_sw/u-boot_patches/examples-standalone-Makefile.patch \
89+
../../../common_sw/u-boot_patches/examples-Makefile.patch \
90+
../../../common_sw/u-boot_patches/brd_altera_a5e065_premium_es-arch-arm-dts-socfpga_agilex5_socdk-u-boot.dtsi.patch
91+
"
92+
for NEXT_PATCH in ${PATCH_FILES:?}
93+
do
94+
patch -p1 \
95+
-i ${NEXT_PATCH:?} \
96+
|| { echo "ERROR" ; exit 1 ; }
97+
done
98+
99+
ln -s \
100+
-t ./examples/standalone/ \
101+
../../../../../common_sw/u-boot_standalone_apps/armv8_regs.c \
102+
../../../../../common_sw/u-boot_standalone_apps/boot_app.c \
103+
../../../../../common_sw/u-boot_standalone_apps/cache_regs.c \
104+
../../../../../common_sw/u-boot_standalone_apps/config_clk.c \
105+
../../../../../common_sw/u-boot_standalone_apps/emac.c \
106+
../../../../../common_sw/u-boot_standalone_apps/f2h_bridge.c \
107+
../../../../../common_sw/u-boot_standalone_apps/f2h_irq.c \
108+
../../../../../common_sw/u-boot_standalone_apps/f2h_irq_handler.c \
109+
../../../../../common_sw/u-boot_standalone_apps/f2sdram_bridge.c \
110+
../../../../../common_sw/u-boot_standalone_apps/h2f_bridge.c \
111+
../../../../../common_sw/u-boot_standalone_apps/h2f_bridge_def_sub.c \
112+
../../../../../common_sw/u-boot_standalone_apps/h2f_user_clk.c \
113+
../../../../../common_sw/u-boot_standalone_apps/help_text.h \
114+
../../../../../common_sw/u-boot_standalone_apps/hps_gp.c \
115+
../../../../../common_sw/u-boot_standalone_apps/i2c_bridge.c \
116+
../../../../../common_sw/u-boot_standalone_apps/lwh2f_bridge.c \
117+
../../../../../common_sw/u-boot_standalone_apps/lwh2f_bridge_def_sub.c \
118+
../../../../../common_sw/u-boot_standalone_apps/read_sensors.c \
119+
../../../../../common_sw/u-boot_standalone_apps/sdm_query.c \
120+
../../../../../common_sw/u-boot_standalone_apps/spi_bridge.c \
121+
../../../../../common_sw/u-boot_standalone_apps/standalone_common.h \
122+
../../../../../common_sw/u-boot_standalone_apps/system_counter.c \
123+
../../../../../common_sw/u-boot_standalone_apps/uart.c \
124+
|| { echo "ERROR" ; exit 1 ; }
125+
126+
ln -s \
127+
../../../../../common_sw/u-boot_standalone_apps/select_uart1.h \
128+
./examples/standalone/select_uart.h \
129+
|| { echo "ERROR" ; exit 1 ; }
130+
131+
make -j 48 || { echo "ERROR" ; exit 1 ; }
132+

0 commit comments

Comments
 (0)