[[ubuntu_virtual_cae_system]]

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
ubuntu_virtual_cae_system [2019/03/27 14:20]
beckmanf [Preconfigured VirtualBox virtual machine] Replaced my vm with Hans vm
ubuntu_virtual_cae_system [2022/03/15 11:22] (current)
beckmanf switched link to new gitlab server
Line 1: Line 1:
-===== Ubuntu ​Virtual CAE System =====+===== Lubuntu ​Virtual CAE System =====
  
-The Ubuntu(r) virtual CAE System is an Ubuntu ​Linux(r) based CAE environment based on Altera(r), Quartus(r), Modelsim(r) and a MIPS(r) Cross compiler. The idea is to run Ubuntu Linux in a virtual machine.+The Lubuntu(r) virtual CAE System is a Lubuntu ​Linux(r) based CAE environment based on Altera(r), Quartus(r), Modelsim(r) and a MIPS(r) Cross compiler. The idea is to run Ubuntu Linux in a virtual machine. The lab as two different boards which require different Quartus Version.
  
 +  * [[altera_boards|Altera DE1 board]] (Digitaltechnik,​ Entwurf digitaler Systeme 1) with Cyclone II FPGA
 +  * NOT IN SS21!!! Altera DE1 SOC (Master VLSI, Master COM) with Cyclone V FPGA
 +
 +The last version that supports Cyclone II fpga architecture is Quartus 13.0sp1. That version does not support the Cyclone V architecture. All quartus versions that support Cyclone V do not support Cyclone II. So unfortunately there is not one Quartus version that supports both fpga architecutures. ​
 ==== Preconfigured VirtualBox virtual machine ==== ==== Preconfigured VirtualBox virtual machine ====
  
-Hans Färber has build a [[https://​www.hs-augsburg.de/​homes/​haf/​php/​dokuwiki/​doku.php?​id=public:​praktikum_digitaltechnik:​cae-virtual-machine:​caevm-install|preconfigured virtual cae machine]] based on Lubuntu. ​ 
  
-===== Build your own from scratch ​(Ubuntu 12.04) ​=====+Hans Färber has build three different virtual machines: 
 + 
 +  * [[https://​www.hs-augsburg.de/​homes/​haf/​php/​dokuwiki/​doku.php?​id=public:​praktikum_digitaltechnik:​cae-virtual-machine:​caevm-install|Altera DE1 Virtual Machine with Quartus and Modelsim]] for Digitaltechnik,​ Digitaltechnik Praktikum and Entwurf digitaler Systeme 1 
 +  * [[https://​www.hs-augsburg.de/​homes/​haf/​php/​dokuwiki/​doku.php?​id=public:​meng:​caemachine:​caevm-install|Altera DE1 Virtual Machine with Quartus, Modelsim and Matlab]] for Master Courses  
 +  * [[https://​www.terasic.com.tw/​cgi-bin/​page/​archive.pl?​Language=English&​No=836|Altera DE1 SoC board]]: [[https://​www.hs-augsburg.de/​homes/​haf/​php/​dokuwiki/​doku.php?​id=public:​meng:​caemachine:​socvm-install|SoC Virtual Machine]] (used in previous years for Master courses) 
 + 
 +===== Build your own from scratch ===== 
 + 
 +The CAD software is based on Lubuntu linux, Quartus and other software. The software and the linux operating system are supposed to run in a virtual machine. If you do not use a virtualization environment,​ then you can install also directly on a native linux machine. The following description assumes Lubuntu 18.04. Just skip the virtual machine section.
  
-Here is the description how the virtual machine is build from scratch. There are specific instructions for [[ubuntu_virtual_cae_system#​Installing on Ubuntu 14.04]]. ​ 
-  
 ==== Virtual Machine ==== ==== Virtual Machine ====
  
 There are different virtual machine environments. ​ There are different virtual machine environments. ​
  
-== VMWare ==+=== VMWare ​===
  
-VMWare(r) provides a commercial version VMWare Fusion for Mac OS(r). This has a very good integration in MacOS and I use +VMWare(r) provides a commercial version VMWare Fusion for Mac OS(r). This has a very good integration in MacOS and I use it with MacOS 10.13.(High Sierra). It is not free. For Windows(r) there is the VMWare Player. The VMWare Player is free. I have not tested it. 
-it with MacOS 10.8.(Mountain Lion). It is not free. For Windows(r) there is the VMWare Player. The VMWare Player is free. I have not tested it. +
  
-== VirtualBox ==+=== VirtualBox ​===
  
-VirtualBox(r) is available for Windows, Linux and Mac OS. It is free. From my experience with MacOS it is not as good integrated as VMWare Fusion. ​The following description targets Virtualbox as this is free of charge+VirtualBox(r) is available for Windows, Linux and Mac OS. It is free. From my experience with MacOS it is not as good integrated as VMWare Fusion. ​If you want to use this, then download and install the the virtual machine software from [[https://​www.virtualbox.org|https://​www.virtualbox.org]]
  
-=== Get the virtual machine ​===+=== Get the Lubuntu 18.04 install image ===
  
-Download ​and install ​the the virtual machine software from [[https://​www.virtualbox.org|https://​www.virtualbox.org]]+Download the ISO file for the 64 Bit Lubuntu 18.04.4 LTS Desktop version. You can download the image from here:
  
-=== Get the Ubuntu install image ===+[[http://​cdimage.ubuntu.com/​lubuntu/​releases/​18.04.4/​release/​lubuntu-18.04.4-desktop-amd64.iso]]
  
-Download the ISO file for the 32 Bit Ubuntu 12.04 LTS Desktop version. You can download the image from here: 
  
-[[http://​de.releases.ubuntu.com/​precise/​ubuntu-12.04.5-desktop-amd64.iso]]+=== Install the Lubuntu machine ===
  
-=== Install Ubuntu in the virtual machine ===+This depends on the virtualization environment that you use.
  
-You can mount the ISO Image as CDROM in the virtual machine and boot from the virtual CDROM. Then you install to your disk. Configure the virtual machine with the following parameters. ​+== VMWare ==
  
-  * fixed vmdk disk with 30 GByte size +Create a new virtual machine ​with minimum 20GB hard disk. The hard disk will result in a file on the host operating system (Here MacOs) but the file size on the host will be dynamic, i.e. it will depend on the actual usage in the virtual machine. I have selected 300GB. Use the username "​caeuser"​ with password "​caeuser"​ because that is the setting in the lab and all descriptions are based on this. The name of your computer shall be "​vcae"​. ​
-  * depending ​on your RAM choose minimum 1 GByte RAM for the virtual machine +
-  * In the Graphics section give 128 MB Ram to the graphics system  +
-  * Enable 2D or 3D acceleration (On my MacBook(r) 3D is proposed)+
  
-To mount the virtual CDROM do+You need to install ​the guest additions. Without the guest additions, the interaction with the host system is not working (file sharing / Clipboard). Run "​Virtuelle Maschine -> VMWare Tools installieren"​ in the VMWare menu. Then run the following:
  
-Choose Devices->CD/DVD Devices ​-> Choose a virtual CD/DVD disk file+<code> 
 +cd 
 +mkdir vmware 
 +cp /media/​caeuser/​VMwareTools-<​versionnumbervmware 
 +cd vmware 
 +tar -xvzf VMwareTools-<​versionnumber>​ 
 +cd vmware-tools-distrib 
 +sudo ./vmware-install.pl  
 +</​code>​
  
-Then select the Ubuntu Install Image ISO file that you downloaded in the previous sectionYou now have the virtually inserted the CDROM. Now reboot the virtual machine. The settings should result in booting from the CDROM and from there you install Ubuntu to the virtual disk driveJust select location and language as appropriate+Say "​yes"​ to all questions...
  
-=== Post install === 
  
-After installing Ubuntu you need to install guest applications from virtual box.  ​+== Virtualbox ==
  
-== Problem: low-res graphics == +to be done
-Problem: The graphical userinterface does not start because it cannot identify the screen resolution. Whatever you do you end in a textual shell.  +
-Solution: You need to install the virtualbox guest additions. ​+
  
-From the textual shell login to the system ​and run the following ​+===== Install Quartus 13.0sp1 and Modelsim ===== 
 + 
 +The following steps will install  
 + 
 +  * Altera Quartus II Web Edition Version 13.0sp1 (13.0.1 build 232) 
 +  * Modelsim Altera Starter Edition Version 10.1d (included in 13.0sp1) 
 + 
 +These versions are required for the Altera DE1 board which is used in the digital design lab and is available in the library. This Quartus version is the last version that supports the Altera Cyclone II FPGA which is on that board. So do not install a later version if you want to use that board. 
 + 
 +Install ​the software at "/​opt/​altera/​13.0sp1"​. Create the altera directory ​and change ​the owner to the caeuser username.
  
 <​code>​ <​code>​
-sudo apt-get install dkms+sudo mkdir /​opt/​altera 
 +sudo chown caeuser:​caeuser /opt/altera
 </​code>​ </​code>​
  
-Virtually insert the VirtualBox Guest additions CD by selecting Devices->​Install ​Guest Additions in Virtualbox application. That will virtually insert a CDROM in the drive. Now you need to mount the cdrom in ubuntu, change to the cdrom directory ​and run the installation script+=== Install ​32Bit Libraries ​ === 
 + 
 +Quartus ​and Modelsim require 32Bit Libraries which are not installed by default 
 + 
 +Enable multiple architectures (32 Bit / 64 Bit)
  
 <​code>​ <​code>​
-sudo mount /dev/cdrom /media +sudo dpkg --add-architecture i386 
-cd /media +sudo apt-get update
-sudo ./​VBoxLinuxAdditions.run ​+
 </​code>​ </​code>​
  
-Now you can reboot and the graphical user interface should start. ​+Install ​the 32Bit libraries
  
 <​code>​ <​code>​
-sudo shutdown ​-r now+sudo apt-get install libc6:i386 libpng16-16:​i386 libfreetype6:​i386 libsm6:i386 libxrender1:​i386 libfontconfig1:​i386 libxext6:​i386 libxft2:​i386 libncurses5:​i386
 </​code>​ </​code>​
  
-After reboot open a shell (terminal) and update ​the ubuntu system ​+=== Missing libpng12 === 
 + 
 +The quartus software requires ​the libpng12 library but Lubuntu 18.04 comes with libpng16. If you do not install libpng12, then the following error will occur:
  
 <​code>​ <​code>​
-sudo apt-get update +fritz@vcae:​~$ quartus 
-sudo apt-get upgrade+quartus: error while loading shared libraries: libpng12.so.0:​ cannot open shared object file: No such file or directory 
 +caeuser@vcae:​~$ ​
 </​code>​ </​code>​
-==== Install Altera Quartus and Modelsim ==== 
  
-Description for 64Bit Linux installation ​is here [[Quartus_on_64bit_linux]]+The following check shows that libpng16 ​is installed but quartus needs libpng12. 
 +<​code>​ 
 +fritz@vcae:​~$ dpkg -l | grep png 
 +ii  libpng16-16:​amd64 ​                    ​1.6.34-1ubuntu0.18.04.1 ​            ​amd64 ​       PNG library - runtime (version 1.6) 
 +caeuser@vcae:​~$ 
 +</​code>​
  
-Go to the tmp directory and download und untar the installation packageThen start the setup+So download, compile and copy the libpng12 library ​to the quartus install ​directory. You have to install both, the 32bit and the 64bit versions.
  
 <​code>​ <​code>​
-cd /tmp +cd 
-mkdir quartus +cd cae 
-cd quartus+sudo apt install build-essential gcc-multilib zlib1g-dev:​i386 
 +wget https://​www.hs-augsburg.de/​homes/​beckmanf/​public/​libpng-1.2.59.tar.gz 
 +tar -xvzf libpng-1.2.59.tar.gz 
 +cd libpng-1.2.59 
 +CFLAGS='​-m32'​ ./configure --libdir=/​usr/​lib/​i386-linux-gnu 
 +make 
 +sudo make install 
 +make clean 
 +./configure --libdir=/​usr/​lib/​x86_64-linux-gnu 
 +make 
 +sudo make install 
 +</​code>​ 
 + 
 +=== Download and install Quartus 13.0sp1 (incl. Modelsim) === 
 + 
 +<​code>​ 
 +cd 
 +mkdir cae 
 +cd cae
 wget http://​www.hs-augsburg.de/​~beckmanf/​public/​Quartus-web-13.0.1.232-linux.tar wget http://​www.hs-augsburg.de/​~beckmanf/​public/​Quartus-web-13.0.1.232-linux.tar
 tar -xvf Quartus-web-13.0.1.232-linux.tar tar -xvf Quartus-web-13.0.1.232-linux.tar
Line 98: Line 145:
 </​code>​ </​code>​
  
-Modelsim does not display ​the fonts very nicelyTo have better fonts do +The installation directory is /​opt/​altera/​13.0sp1. You do not need to install ​the Arria, Cyclone V and MAX device supportChoose the ModelSim-Altera Starter Edition (Free). The Help files are optional. 
 + 
 +=== adapt .profile for PATH === 
 + 
 +First add a symbolic link to the current version of the quartus software
  
 <​code>​ <​code>​
-sudo apt-get install xfonts-75dpi+cd /​opt/​altera 
 +ln -s 13.0sp1 version 
 +cd
 </​code>​ </​code>​
  
-In order to be able to start the binaries from the commandline,​ the path for the binaries has to be in the PATH environment variable. For that you have to modify the .profile file in your home directory. Append the following snippet to the .profile file: +In order to be able to start the binaries from the commandline,​ the path for the binaries has to be in the PATH environment variable. For that you have to modify the .profile file in your home directory. Append the following snippet to the .profile file with [[http://​heather.cs.ucdavis.edu/​~matloff/​UnixAndC/​Editors/​ViIntro.html|vi]].
  
 <code bash .profile>​ <code bash .profile>​
 # Include the ALTERA fpga software # Include the ALTERA fpga software
-PATH="​$PATH:​$HOME/altera/13.0sp1/​quartus/​bin"​+PATH="​$PATH:​/opt/altera/version/​quartus/​bin"​
 # Include the ALTERA Modelsim VHDL simulator # Include the ALTERA Modelsim VHDL simulator
-PATH="​$PATH:​$HOME/altera/13.0sp1/​modelsim_ase/​linuxaloem"+PATH="​$PATH:​/opt/altera/version/​modelsim_ase/​bin"
 </​code>​ </​code>​
  
-To make the new fonts active and to see the changes in the PATH variable, ​you have to logout and login again. ​After that you can already start modelsim and quartus (see below). To check the setting of the PATH variable do: +Then you have to logout and login again to make the changes active.
  
-<code bash> +=== Fix linux_rh60 vco script problem ===
-fritz@fritz-VirtualBox:​~$ echo $PATH +
-/​home/​fritz/​site/​bin:/​usr/​lib/​lightdm/​lightdm:/​usr/​local/​sbin:/​usr/​local/​bin:/​usr/​sbin:/​usr/​bin:/​sbin:/​bin:/​usr/​games:/​home/​fritz/​altera/​13.0sp1/​modelsim_ase/​linuxaloem:/​home/​fritz/​altera/​13.0sp1/​quartus/​bin +
-fritz@fritz-VirtualBox:​~$  +
-</​code> ​+
  
-You can see that the altera directories are now part of the PATH variable. ​+When you run modelsim and see:
  
-The following steps are required to actually program the devicesIf you do not need or want to do that, you can continues with starting modelsim and quartus.+<​code>​ 
 +caeuser@vcae:​~/​cae$ vsim 
 +Error: cannot find /​opt/​altera/​13.0sp1/​modelsim_ase/​bin/​../​linux_rh60/​vsim 
 +caeuser@vcae:​~/​cae$ 
 +</​code>​
  
-==== USB Settings ==== +then, you have to fix the vco script. First change the permissions such that you can modify the script.
  
-For the USB programming via the USB Blaster(tm),​ the port permissions have to be set correctly. For that you have to add the file "​51-usbblaster.rules"​ to the directory "/​etc/​udev/​rules.d"​ and reboot. See also [[http://​www.altera.com/​download/​drivers/​dri-usb_b-lnx.html]] but notice that the rules shown at Altera are different and do not work with ubuntu.+<​code>​ 
 +cd /​opt/​altera/​13.0sp1/​modelsim_ase 
 +chmod u+w vco 
 +</​code>​ 
 + 
 +Open the vco with 
 + 
 +<​code>​ 
 +vi vco 
 +</​code>​ 
 + 
 +and find the following section 
 + 
 +<​code>​ 
 +      else 
 +        case $utype in 
 +          2.4.[7-9]*) ​      ​vco="​linux"​ ;; 
 +          2.4.[1-9][0-9]*) ​ vco="​linux"​ ;; 
 +          2.[5-9]*) ​        ​vco="​linux"​ ;; 
 +          2.[1-9][0-9]*) ​   vco="​linux"​ ;; 
 +          3.[0-9]*) ​            ​vco="​linux"​ ;; 
 +          *)                vco="​linux_rh60"​ ;; 
 +</​code>​ 
 + 
 +And change the "​linux_rh60"​ entry to "​linux"​. 
 + 
 +=== Fix the libfreetype problem === 
 + 
 +If you see 
 + 
 +<​code>​ 
 +caeuser@ADLab-Tools-OS:​~$ vsim 
 +Error in startup script: 
 +Initialization problem, exiting. 
 + 
 +Initialization problem, exiting. 
 + 
 +    while executing 
 +"​InitializeINIFile quietly"​ 
 +    invoked from within 
 +"​ncFyP12 -+" 
 +    (file "/​mtitcl/​vsim/​vsim"​ line 1) 
 +** Fatal: Read failure in vlm process (0,0) 
 +caeuser@ADLab-Tools-OS:​~$ 
 +</​code>​ 
 + 
 +then you have to install an old version or differently configured version of libfreetype. Enable the deb-src packages in the /​etc/​apt/​sources.list file to make the build dependencies work. It should look like this: 
 + 
 +<​code>​ 
 +#deb cdrom:​[Lubuntu 18.04 LTS _Bionic Beaver_ - Release amd64 (20180426)]/​ bionic main multiverse restricted universe 
 + 
 +# See http://​help.ubuntu.com/​community/​UpgradeNotes for how to upgrade to 
 +# newer versions of the distribution. 
 +deb http://​de.archive.ubuntu.com/​ubuntu/​ bionic main restricted 
 +deb-src http://​de.archive.ubuntu.com/​ubuntu/​ bionic main restricted 
 + 
 +## Major bug fix updates produced after the final release of the 
 +## distribution. 
 +deb http://​de.archive.ubuntu.com/​ubuntu/​ bionic-updates main restricted 
 +deb-src http://​de.archive.ubuntu.com/​ubuntu/​ bionic-updates main restricted 
 +</​code>​ 
 + 
 +Now install the build dependencies and compile and install the old libfreetype version. 
 + 
 +<​code>​ 
 +cd 
 +cd cae 
 +sudo apt update 
 +sudo apt build-dep -a i386 libfreetype6 
 +wget https://​download.savannah.gnu.org/​releases/​freetype/​freetype-2.8.1.tar.gz 
 +tar -xvzf freetype-2.8.1.tar.gz 
 +cd freetype-2.8.1 
 +CFLAGS='​-m32'​ ./configure --without-png 
 +make -j8 
 +</​code>​ 
 + 
 +It is important to configure the freetype library with "​--without-png"​. Copy the libfreetype library files to the modelsim directory. 
 + 
 +<​code>​ 
 +mkdir /​opt/​altera/​13.0sp1/​modelsim_ase/​lib32 
 +cp objs/​.libs/​libfreetype.so* /​opt/​altera/​13.0sp1/​modelsim_ase/​lib32/​ 
 +</​code>​ 
 + 
 +Now you have to change modelsim /​opt/​altera/​13.0sp1/​modelsim_ase/​vco file and find the location: 
 + 
 +<​code>​ 
 +dir=`dirname "​$arg0"​` 
 +</​code>​ 
 + 
 +After that line add 
 + 
 +<​code>​ 
 +export LD_LIBRARY_PATH=/​opt/​altera/​13.0sp1/​modelsim_ase/​lib32 
 +</​code>​ 
 + 
 +=== USB Settings === 
 + 
 +For the USB programming via the USB Blaster(tm),​ the port permissions have to be set correctly. For that you have to create and add the file "​51-usbblaster.rules"​ to the directory "/​etc/​udev/​rules.d"​ and reboot. ​
  
 <​code>​ <​code>​
 /​etc/​udev/​rules.d/​51-usbblaster.rules /​etc/​udev/​rules.d/​51-usbblaster.rules
 </​code>​ </​code>​
 +
 +The file should contain the following rules for the Altera DE1 board.
  
 <code bash 51-usbblaster.rules>​ <code bash 51-usbblaster.rules>​
Line 143: Line 295:
 </​code>​ </​code>​
  
-For the following test you need to attach the Altera Board to your computer. Notice that you have to attach the usb device to the virtual machine with Devices->​USB Devices->​Altera USB-Blaster. Then you should be able to see the device in the usb device list with lsusb. ​+For the following test you need to attach the Altera Board to your computer. Notice that you have to attach the usb device to the virtual machine ​(Virtual Box) with Devices->​USB Devices->​Altera USB-Blaster. Then you should be able to see the device in the usb device list with lsusb. ​
  
 <​code>​ <​code>​
-fritz@fritz-VirtualBox:/​etc/​udev/​rules.d$ lsusb+caeuser@vcae:/​etc/​udev/​rules.d$ lsusb
 Bus 001 Device 002: ID 80ee:0021 VirtualBox USB Tablet Bus 001 Device 002: ID 80ee:0021 VirtualBox USB Tablet
 Bus 001 Device 003: ID 09fb:6001 Altera Blaster Bus 001 Device 003: ID 09fb:6001 Altera Blaster
 Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
-fritz@fritz-VirtualBox:/​etc/​udev/​rules.d$+caeuser@vcae:/​etc/​udev/​rules.d$
 </​code>​ </​code>​
  
-You can see the permissions for the devices with ls. See the rw rights for "​others"​ for the device 003 which is +You can see the permissions for the devices with ls. See the rw rights for "​others"​ for the device 003 which is the usb blaster. That is a result of the rules file. 
-the usb blaster. That is a result of the rules file. +
  
 <​code>​ <​code>​
-fritz@fritz-VirtualBox:/​etc/​udev/​rules.d$ ls -l /​dev/​bus/​usb/​001/​+caeuser@vcae:/​etc/​udev/​rules.d$ ls -l /​dev/​bus/​usb/​001/​
 insgesamt 0 insgesamt 0
 crw-rw-r-- 1 root root 189, 0 Mai  7 16:35 001 crw-rw-r-- 1 root root 189, 0 Mai  7 16:35 001
Line 168: Line 319:
  
 <​code>​ <​code>​
-fritz@fritz-VirtualBox:/​etc/​udev/​rules.d$ jtagconfig --enum+caeuser@vcae:/​etc/​udev/​rules.d$ jtagconfig --enum
 1) USB-Blaster [1-2]                          ​ 1) USB-Blaster [1-2]                          ​
   020B30DD ​  ​EP2C(15|20)   020B30DD ​  ​EP2C(15|20)
Line 187: Line 338:
 </​code>​ </​code>​
  
-==== Install qfsm ====+==== Only Bachelor ET and ME students: ​Install qfsm ====
  
 [[http://​qfsm.sourceforge.net|QFSM]] ist the state chart editor used in the lab. First you need to install some required packages. ​ [[http://​qfsm.sourceforge.net|QFSM]] ist the state chart editor used in the lab. First you need to install some required packages. ​
Line 210: Line 361:
 </​code>​ </​code>​
  
-===== Installing on Ubuntu 14.04 =====+===== Optional: Install Quartus 18.=====
  
-  * Ubuntu 14.04 LTS 64 Bit +You need Quartus ​18.1 to program the Altera ​DE1 Soc board with the Cyclone V fpga. [[vcae-lubuntu-18.04|How to install Quartus ​18.1]]
-  * Altera ​Quartus ​II Web Edition Version 13.0sp1 (13.0.1 build 232) +
-  * Modelsim ​Altera ​Starter Edition Version 10.1d (included in 13.0sp1) +
- +
-The ISO Image for the Ubuntu 14.04 is here:  +
- +
-[[http://​de.releases.ubuntu.com/​trusty/​ubuntu-14.04.2-desktop-amd64.iso]] +
- +
-I installed on VMWare on my Macbook running OSX 10.9.3 ​with VMWare 6.03. I did not install any VMWare add ons.  +
-==== Installing Quartus ==== +
- +
-Add the following to your .profile in your home directory. You need to logout and login to make the changes active.  +
- +
-<code bash .profile>​ +
-# Include the ALTERA ​fpga software +
-PATH="​$PATH:​$HOME/​altera/​13.0sp1/​quartus/​bin"​ +
-# Include the ALTERA Modelsim VHDL simulator +
-PATH="​$PATH:​$HOME/​altera/​13.0sp1/​modelsim_ase/​bin"​ +
-</​code>​ +
- +
-Follow the instructions to modify the [[ubuntu_virtual_cae_system#​USB Settings]].  +
- +
-Enable multiple architectures (32 Bit / 64 Bit) +
- +
-<​code>​ +
-sudo dpkg --add-architecture i386 +
-sudo apt-get update +
-</​code>​ +
- +
-Install the 32Bit libraries +
- +
-<​code>​ +
-sudo apt-get install libc6:i386 libpng12-0:​i386 libfreetype6:​i386 libsm6:i386 libxrender1:​i386 libfontconfig1:​i386 libxext6:​i386 libxft2:​i386 libncurses5:​i386 +
-</​code>​ +
- +
- +
-Modelsim does not display the fonts very nicelyTo have better fonts do  +
- +
-<​code>​ +
-sudo apt-get ​install ​xfonts-75dpi +
-</​code>​ +
- +
-Get and install the Quartus/Modelsim package:  +
- +
-<​code>​ +
-cd /tmp +
-mkdir quartus +
-cd quartus +
-wget http://​www.hs-augsburg.de/​~beckmanf/​public/​Quartus-web-13.0.1.232-linux.tar +
-tar -xvf Quartus-web-13.0.1.232-linux.tar +
-./​setup.sh +
-</​code>​ +
- +
-During the setup you can deselect all device specific packages (Arria...) except CycloneII.  +
- +
-Quartus should now run.  +
- +
-==== Modelsim incompatible libfreetype ==== +
- +
-If you start vsim after the installation it will crash with a segmentation fault. The reason is that modelsim is not compatible with a newer version of libfreetype. I followed the instructions here [[http://​mattaw.blogspot.de/​2014/​05/​making-modelsim-altera-starter-edition.html]]. The following should work for the ubuntu install.  +
- +
-=== Compile a new libfreetype === +
-<​code>​ +
-cd /tmp +
-sudo apt-get install libc6-dev-i386 +
-sudo apt-get build-dep -a i386 libfreetype6 +
-wget http://​download.savannah.gnu.org/​releases/​freetype/​freetype-2.4.12.tar.bz2 +
-tar -xjvf freetype-2.4.12.tar.bz2 +
-cd freetype-2.4.12 +
-./configure --build=i686-pc-linux-gnu "​CFLAGS=-m32"​ "​CXXFLAGS=-m32"​ "​LDFLAGS=-m32"​ +
-make -j8 +
-</​code>​ +
- +
-=== Modify the modelsim Installation === +
- +
-<​code>​ +
-cd ~/​altera/​13.0sp1/​modelsim_ase/​ +
-mkdir lib32 +
-cp /​tmp/​freetype-2.4.12/​objs/​.libs/​libfreetype.so* ./lib32 +
-chmod u+w vco +
-</​code>​ +
- +
-Now edit the file "​~/​altera/​13.0sp1/​modelsim_ase/​vco"​.  +
- +
-<​code>​ +
-gedit ~/​altera/​13.0sp1/​modelsim_ase/​vco +
-</​code>​ +
- +
-Find the line +
- +
-<​code>​ +
-dir=`dirname $arg0` +
-</​code>​ +
- +
-and add +
- +
-<​code>​ +
-export LD_LIBRARY_PATH=/​home/​fritz/​altera/​13.0sp1/​modelsim_ase/​lib32 +
-</​code>​ +
- +
-just below that line. You need to adapt the path to the name of your installation.  +
- +
-Now  +
- +
-<​code>​ +
-vsim +
-</​code>​+
  
-should work.  +===== Very Optional: ​Download and build the mips toolchain =====
-===== Download and build the mips toolchain =====+
  
-The MIPS Cross Compiler is only needed for the patterson project. ​+The MIPS Cross Compiler is only needed for the patterson project.
  
 Follow the instructions in [[mips_cross_compiler|MIPS Cross Compiler build]] Follow the instructions in [[mips_cross_compiler|MIPS Cross Compiler build]]
Line 335: Line 379:
 </​code>​ </​code>​
  
-Download the "​Digitaltechnikpraktikum"​ from the git server: [[https://git.etech.fh-augsburg.de/​friedrich.beckmann/​digitaltechnikpraktikum]]+Download the "​Digitaltechnikpraktikum"​ from the git server: [[https://gitlab.elektrotechnik.hs-augsburg.de/​beckmanf/​digitaltechnikpraktikum]]
  
 <​code>​ <​code>​
Line 341: Line 385:
 mkdir projects mkdir projects
 cd projects cd projects
-git clone https://git.etech.fh-augsburg.de/​friedrich.beckmann/​digitaltechnikpraktikum.git+git clone https://gitlab.elektrotechnik.hs-augsburg.de/​beckmanf/​digitaltechnikpraktikum.git
 </​code>​ </​code>​
  
  • ubuntu_virtual_cae_system.1553692851.txt.gz
  • Last modified: 2019/03/27 14:20
  • by beckmanf