Quartus 配置 Nios® II EDS 开发环境

安装 Quartus

按照我之前写的文章安装即可 —— Quartus 入门

安装 Ubuntu 18.04(Linux 桌面用户直接跳过该步骤

在官方下载页面可以看到,我们需要安装 Ubuntu 18.04 LTS 并启用 WSL

WSL

这里介绍 WSL 的安装方法,打算使用 WSL2 的读者请根据需要阅读本文中的参考链接

  1. 打开设置,搜索控制面板,点击应用,启用或关闭windows功能。往下滑,打开适用于 windowsLinux 子系统等服务(虚拟机相关)

  2. 使用 管理员权限 打开 PowerShell ,输入以下命令

wsl --install

如果报错: "无法解析服务器的名称或地址",请尝试使用代理再运行该命令

  1. 设置默认的 WSL 版本为版本1
wsl --set-default-version 1

Ubuntu

  1. Internet 属性 - 高级 选项卡中勾选上 使用 TLS 1.2

  2. 打开微软商店,下载 Ubuntu 18.04 on Windows

  3. 下载安装后打开,设置用户名和密码(注意,输入密码时屏幕没反应,是正常现象)

  4. 运行命令

sudo apt update && sudo apt upgrade
sudo apt install wsl
sudo apt install dos2unix
sudo apt install make
sudo apt install build-essential

提示信息一路 Y 即可

安装 Eclipse IDE

可以看到,Eclipse IDE 需要单独安装

  1. 打开 Quartus 安装的文件夹,依次打开 intelFPGA_lite - 22.1std - nios2eds - bin 能看到一个 README 文件,用记事本打开,内容如下
QUARTUS ECLIPSE MANUAL INSTALLATION
1. Download CDT 8.8.1 which is Eclipse C/C++ IDE for Mars.2
a. Windows: https://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/mars/2/eclipse-cpp-mars-2-win32-x86_64.zip
b. Linux: https://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/mars/2/eclipse-cpp-mars-2-linux-gtk-x86_64.tar.gz
2. Extract the downloaded file into <Quartus installation directory>/nios2eds/bin. You should see <Quartus installation directory>/nios2eds/bin/eclipse folder after extraction is done.
3. Rename <Quartus installation directory>/nios2eds/bin/eclipse folder to <Quartus installation directory>/nios2eds/bin/eclipse_nios2
4. Extract <Quartus installation directory>/nios2eds/bin/eclipse_nios2_plugins.zip (or tar.gz for Linux) to <Quartus installation directory>/nios2eds/bin. The extraction will override files in <Quartus installation directory>/nios2eds/bin/eclipse_nios2.
5. Verify the extraction is done correctly by making sure you see <Quartus installation directory>/nios2eds/bin/eclipse_nios2/plugin_customization.ini file
6. You can now launch Nios2 II SBT for Eclipse via eclipse-nios2.exe
  1. 使用链接下载
  1. 下载到 README 所在的文件夹,解压后更名为 eclipse_nios2 即可

至此,大功告成

常见问题

  • Q1: failed to execute :wsl dos2unix create-this-bsp; ./create-this-bsp --cpu-name nio2_gen2_0 --no -make
  • A1:检查 WSL 是否正确安装并启用,Ubuntu 安装中相应的命令有没有执行完成

参考链接

posted @ 2024-04-18 21:40  Leeds_Garden  阅读(100)  评论(0编辑  收藏  举报