Skip to content
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

Hdl 2022 r2 support #161

Merged
merged 3 commits into from
Oct 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions +adi/Version.m
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
%Version
% BSP Version information
properties(Constant)
HDL = 'hdl_2021_r2';
Vivado = '2021.2';
HDL = 'hdl_2022_r2';
Vivado = '2022.2';
MATLAB = 'R2023b';
Release = '23.2.1';
AppName = 'Analog Devices, Inc. High-Speed Converter Toolbox';
Expand Down
6 changes: 3 additions & 3 deletions CI/gen_doc/docs/_pages/targeting.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ High-Speed Converter Toolbox supports the IP Core generation flow from MathWorks

## Getting Started

To perform targeting will require FPGA vendor tools for the FPGA system. For Xilinx this will be Vivado and the toolbox will require specific versions for each release. For the current release this is Vivado 2021.2. Using other versions are not supported. To build the necessary BOOT.BIN files will require the Xilinx SDK as well.
To perform targeting will require FPGA vendor tools for the FPGA system. For Xilinx this will be Vivado and the toolbox will require specific versions for each release. For the current release this is Vivado 2022.2. Using other versions are not supported. To build the necessary BOOT.BIN files will require the Xilinx SDK as well.

Once you have the installed the necessary 3rd party tools MATLAB needs to be told where they are installed by use of the [hdlsetuptoolpath](https://www.mathworks.com/help/hdlcoder/ref/hdlsetuptoolpath.html) command. For Windows the following MATLAB command can be used:

```matlab
hdlsetuptoolpath('ToolName', 'Xilinx Vivado', 'ToolPath', 'C:\Xilinx\Vivado\2021.2\bin\vivado.bat');
hdlsetuptoolpath('ToolName', 'Xilinx Vivado', 'ToolPath', 'C:\Xilinx\Vivado\2022.2\bin\vivado.bat');
```

or Linux:

```matlab
hdlsetuptoolpath('ToolName', 'Xilinx Vivado', 'ToolPath', '/opt/Xilinx/Vivado/2021.2/bin/vivado');
hdlsetuptoolpath('ToolName', 'Xilinx Vivado', 'ToolPath', '/opt/Xilinx/Vivado/2022.2/bin/vivado');
```

Please change the tool path if it is different on your system.
Expand Down
2 changes: 1 addition & 1 deletion CI/scripts/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ MLRELEASE := R2023b
endif

ifeq ($(HDLBRANCH),)
HDLBRANCH := hdl_2021_r2
HDLBRANCH := hdl_2022_r2
endif

ifeq ($(OS),Windows_NT)
Expand Down
2 changes: 1 addition & 1 deletion CI/scripts/build_bsp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set -x

if [ -z "${HDLBRANCH}" ]; then
HDLBRANCH='hdl_2021_r2'
HDLBRANCH='hdl_2022_r2'
fi

# Script is designed to run from specific location
Expand Down
4 changes: 2 additions & 2 deletions CI/scripts/synth_designs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ MLPATH=/usr/local/MATLAB
cd ../..
cp hdl/vendor/AnalogDevices/hdlcoder_board_customization.m test/hdlcoder_board_customization_local.m
sed -i "s/hdlcoder_board_customization/hdlcoder_board_customization_local/g" test/hdlcoder_board_customization_local.m
source /opt/Xilinx/Vivado/2021.2/settings64.sh
source /opt/Xilinx/Vivado/2022.2/settings64.sh
Xvfb :77 &
export DISPLAY=:77
export SWT_GTK3=0
source /opt/Xilinx/Vivado/2021.2/settings64.sh
source /opt/Xilinx/Vivado/2022.2/settings64.sh
$MLPATH/$MLRELEASE/bin/matlab $MLFLAGS -r "cd('test');runSynthTests('$BOARD');"
pidof Xvfb
if [ $? -eq 0 ]; then
Expand Down
10 changes: 5 additions & 5 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ dockerHost = 'docker'

////////////////////////////

hdlBranches = ['main','hdl_2021_r2']
hdlBranches = ['main','hdl_2022_r2']

stage("Build Toolbox") {
dockerParallelBuild(hdlBranches, dockerHost, dockerConfig) {
Expand All @@ -23,14 +23,14 @@ stage("Build Toolbox") {
sh 'make -C ./CI/scripts gen_tlbx'
}
} catch(Exception ex) {
if (branchName == 'hdl_2021_r2') {
if (branchName == 'hdl_2022_r2') {
error('Production Toolbox Build Failed')
}
else {
unstable('Development Build Failed')
}
}
if (branchName == 'hdl_2021_r2') {
if (branchName == 'hdl_2022_r2') {
archiveArtifacts artifacts: '*.mltbx'
stash includes: '**', name: 'builtSources', useDefaultExcludes: false
}
Expand All @@ -40,7 +40,7 @@ stage("Build Toolbox") {
/////////////////////////////////////////////////////

boardNames = ['daq2','ad9081','ad9434','ad9739a','ad9265', 'fmcjesdadc1','ad9783']
dockerConfig.add("-e HDLBRANCH=hdl_2021_r2")
dockerConfig.add("-e HDLBRANCH=hdl_2022_r2")

cstage("HDL Tests", "", flags) {
dockerParallelBuild(boardNames, dockerHost, dockerConfig) {
Expand Down Expand Up @@ -69,7 +69,7 @@ def board = 'ad9208';
def nodeLabel = 'baremetal && high_memory';
deployments[board] = { node(nodeLabel) {
cstage("Baremetal HDL Test", "", flags) {
withEnv(['BOARD='+board,'MLRELEASE=R2023b','HDLBRANCH=hdl_2021_r2','LC_ALL=C.UTF-8','LANG=C.UTF-8']) {
withEnv(['BOARD='+board,'MLRELEASE=R2023b','HDLBRANCH=hdl_2022_r2','LC_ALL=C.UTF-8','LANG=C.UTF-8']) {
try {
cstage("AD9208 HDL Test", "", flags) {
echo "Node: ${env.NODE_NAME}"
Expand Down
8 changes: 4 additions & 4 deletions JenkinsfileCron
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ dockerHost = 'docker'

////////////////////////////

hdlBranches = ['hdl_2021_r2']
hdlBranches = ['hdl_2022_r2']

stage("Build Toolbox") {
dockerParallelBuild(hdlBranches, dockerHost, dockerConfig) {
Expand All @@ -19,14 +19,14 @@ stage("Build Toolbox") {
sh 'make -C ./CI/scripts gen_tlbx'
}
} catch(Exception ex) {
if (branchName == 'hdl_2021_r2') {
if (branchName == 'hdl_2022_r2') {
error('Production Toolbox Build Failed')
}
else {
unstable('Development Build Failed')
}
}
if (branchName == 'hdl_2021_r2') {
if (branchName == 'hdl_2022_r2') {
stash includes: '**', name: 'builtSources', useDefaultExcludes: false
}
}
Expand All @@ -47,7 +47,7 @@ for (int i=0; i < boardNames.size(); i++) {
nodeLabel = 'baremetal && high_memory';
deployments[board] = { node(nodeLabel) {
stage("Synthesis Tests") {
withEnv(['BOARD='+board,'MLRELEASE=R2023b','HDLBRANCH=hdl_2021_r2','LC_ALL=C.UTF-8','LANG=C.UTF-8']) {
withEnv(['BOARD='+board,'MLRELEASE=R2023b','HDLBRANCH=hdl_2022_r2','LC_ALL=C.UTF-8','LANG=C.UTF-8']) {
try {
stage("Synth") {
echo "Node: ${env.NODE_NAME}"
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ As with many open source packages, we use [GitHub](https://github.com/analogdevi

| HDL Branch | MATLAB Release | Installer Package |
|:------------------:|:--------------:|:-------------------:|
| 2021_R2 | R2023b | <a href="http://swdownloads.analog.com/cse/toolboxes/hsx/master/AnalogDevicesHighSpeedConverterToolbox_v23.2.1.mltbx"><img src="https://upload.wikimedia.org/wikipedia/commons/2/21/Matlab_Logo.png" data-canonical-src="https://upload.wikimedia.org/wikipedia/commons/2/21/Matlab_Logo.png" height="40" /></a>|
| 2022_R2 | R2023b | <a href="http://swdownloads.analog.com/cse/toolboxes/hsx/master/AnalogDevicesHighSpeedConverterToolbox_v23.2.1.mltbx"><img src="https://upload.wikimedia.org/wikipedia/commons/2/21/Matlab_Logo.png" data-canonical-src="https://upload.wikimedia.org/wikipedia/commons/2/21/Matlab_Logo.png" height="40" /></a>|

If you use it, and like it - please let us know. If you use it, and hate it - please let us know that too.

## Supported Tools and Releases

We provide support for certain releases of MATLAB. This does not mean older releases will not work but they are not maintained. Currently supported tools are:
- Bug fixes: MATLAB R2022b with Vivado 2021.1
- Bug fixes and new features: MATLAB R2023b with Vivado 2021.2
- Bug fixes: MATLAB R2023b with Vivado 2021.2
- Bug fixes and new features: MATLAB R2023b with Vivado 2022.2

## Support and Documentation

Expand Down
2 changes: 1 addition & 1 deletion hdl/vendor/AnalogDevices/+AnalogDevices/plugin_rd.m
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

% Tool information
%hRD.SupportedToolVersion = {adi.Version.Vivado}; % FIXME
hRD.SupportedToolVersion = {'2021.2'};
hRD.SupportedToolVersion = {'2022.2'};

% Get the root directory
rootDir = fileparts(strtok(mfilename('fullpath'), '+'));
Expand Down
Loading