Intern
    Lehrstuhl für Informatik VIII - Informationstechnik für Luft- und Raumfahrt

    Rodos VM Installation (English version)

    The University of Würzburg offers a virtual machine (Rodos IDE) in which all necessary programs and source files are already installed so that you can start programming for RODOS at once. 

    In case you do not want to use the VM, you can download Rodos from GitLab and have a look at  this YouToube channel showing how to set up an Eclipse and run Rodos executables using Windows Subsystem for Linux (WSL).

    The following howto is also available as pdf from here.

     

    Preparation

    First, download or clone our RodosVM gitlab project, containing the vm image and documentation.

    After obtaining the image, you need to decompress it, e.g., using  7zip.

    VirtualBox Installation

    1. Download VirtualBox >=  version 4.3.16 from https://www.virtualbox.org/wiki/Downloads
      1.  if you need software virtualization, use  VirtualBox 6.0
    2. Install VirtualBox.
    3. Download the VirtualBox Extension Pack from https://www.virtualbox.org/wiki/Downloads.  Please note, the VirtualBox Extension Pack version number must be the same as VirtualBox version number.
    4. Install the VirtualBox Extension Pack by clicking the extension pack file (name ending in "*.vbox-extpack").

     

    In case something goes wrong: there's a vm troubleshooting guide at the bottom of this page.  

     

    RodosVM Creation & Configuration

    Creating the RodosVM

    1. Open VirtualBox
    2. Click [New] to create a new virtual machine.
    3. Now the "Name and operating system" pop up opens, enter:
      1. Name:      RodosVM
      2. Type:        Linux
      3. Version:   Ubuntu (64-Bit)
      4. Click [Next].

    4. In the "Memory size" window:

    1. choose at least 2GiB (2048MiB) memory
    2. Click [Next]

    5. In the "Hard disk" window:

    1. choose Use an exisiting virtual hard disk file
    2. Then click on the small folder icon right of the drop down menu

    6. This has opened the "Hard disk selector" pop up. Please do:

    1. Click [Add]
    2. in the file menu, find your unpacked RodosVM image.
    3. Click [Open]
    4. Back in the "Hard Disc Selector" window that image should now be shown & highlighted.
    5. Click [Choose]

    7. This brings you back to the "Hard disk" window, click [Create]

    RodosVM Configuration

    Please click [Settings] and choose the following settings in the submenus:

     

    1.  General / Advanced: choose Shared Clipboard "Host to Guest" in the drop down menu

    2.  System / Processor: Processors slider: leave it at  1 CPU

    3.  Display / Screen: raise VideoMemory to 128MB

    4.  Shared Folders:

    1. Click the small folder+ icon on the right to add a new shared folder.

    5.  This opens the "Add share" window, here:

    1. In the Folder Path-Dropdown: choose Other..
    2. this opens the file manager, you can choose a directory or create a new one for the shared folder, then click [Ok]
    3. Check the box next to  AutoMount
    4. Click [Ok].

    (You don't need to specify a mount point, there is a default setting for this.)

     

    Using the RodosVM

    Your RodosVM should boot when you click on [Start]. This might take a moment.

    At the login screen, enter these credentials:

    User: Rodos IDE User
    Password: rodos2020

    Final touches - USB setup

    When developing for hardware targets such as the Discovery Board, Gecko, etc., the corresponding USB ports must be forwarded on to the VM.

    You can do this while running the vm via the VirtualBox Devices menu. Simply activate the desired device under Devices>USB.

    (You need the VirtualBox expansion pack in order to have all options shown in the picture available.)

    Final touches - reinstalling the VirtualBox Guest Additions

    Although the virtual machine comes with installed guest additions, those might not work with your version of virtualbox. In this case you need to reinstall the virtualbox guest additions.

    There is a howto for that at the troubleshooting section at the end of this page.

    Passwords and locations

    User:

    Rodos IDE User

    Password:

    rodos2020

    Root password:

    rodos2020

    Rodos source code directory:

    /home/user/rodosTemplate/rodos

    Rodos project template:

    /home/user/eclipse-projects/rodosTemplate

    Building and running the Rodos example

    Using Eclipse

    To make getting started with Rodos programming as easy as possible, we have created an Eclipse project featuring a minimal Rodos application.

    You can find the example in the file manager under /home/rodos/eclipse-projects/rodosTemplate. When you click on the Eclipse Icon on the desktop, the Eclipse IDE opens and shows the Rodos example project "MyRodosApp".

    Clicking on the hammer symbol at the top left starts the compilation, first the Rodos libraries are built and then the example code. In the standard setting, the project is built for Linux so that it can be executed directly in the VM.

    The terminal (bottom center) displays the build program's output (cmake and make).  After a successful build, you can find the the executable "MyRodosApp" in the Project Explorer (left) under rodosTemplate/build-linux/my-rodos-app.

    You can now click the "Run" button with the green play symbol to the right of the "Build" button to run the built executable.

    The terminal below will then show the output of the running programm.

    Congratulations, everything is up and running. Now you can start having fun with the Rodos IDE.

     

     

    Building Rodos from the command line

    There are two ways ogf building Rodos from the command line:


    Using the Rodos Build Scripts

    1.  Open a terminal
    2. Clone Rodos from Gitlab:  git clone gitlab.com/rodos/rodos.git
    3. Change into the Rodos directory: cd rodos
    4. You can list the contents of the folder via: ls
    5.  Source the setenvs script: source ./setenvs.sh
    6. You should be able to build the Rodos libraries now:  rodos-lib.sh linux-x86

    If the libs build everything is set up all right.


    Building a Rodos executable:

    Now you can, e.g., build the hello world example from the Rodos tutorials: rodos-executable.sh linux-x86 ../tutorials/10-first-steps/helloworld.cpp

    The syntax:  rodos-executable.sh <architecture> <path to your .cpp>

    Video Howto

      

    VM Troubleshooting

    There are no 64bit options shown in operating systems dropdown menu??? 

    1. Virtualization is turned off in BIOS / UEFI => look for the VT-x option and turn it on, Instructions
    2. Hyper-V interferes => turn it off, Instructions
    3. Problems with VirtualBox >= 6.1, which does not support software virtualization => download  older version

     

    "Cannot register the hard disk 'C:\vm\[...] because a hard disk 'C:\vm\rodos\Xubuntu 18.04.3 (64bit).vdi' with UUID {a1457371-c6c4-4690-8383-ee4d757847de} already exists."

    You already have a virtual machine that's using a harddisk / image with the same name => delete the older virtual machine in VirtualBox or rename one of the two vm images.

     

    VirtualBox claims it cannot open "another session"

    1. Virtualization turned off in BIOS / UEFI => look for the VT-x option and turn it on, Instructions
    2. No idea why, but sometimes it helps to delete the vm & create a new one

     

    After vm startup, I only see a  blinking cursor

    1. Known problems with Hyper-V and/or WSL => Deactivate or deinstall WSL and Hyper-V:  how to turn of Hyper-V , how to turn of WSL
    2. Virtualization is turned off in the BIOS / UEFI => turn it on,  Instructions
    3. Both  => Instructions fto resolve both on HowtoGeek

     

    I run VirtualBox on Linux & there's no USB 2.0 | 3.0 forwarding???

    The open source virtualbox-host-module Expansion packs, as provided by various package managers, are only capable of forwarding  USB 1.0. You need  the Oracle Expansion Pack in order to use USB 2.0 | 3.0 Forwarding (which you will need for connecting to most target boards).

    Download it manually & install it, e.g., with the bash command: sudo VBoxManage extpack install  --accept-license=sha256 </Path/to/ExtensionPack/ExtensionPackName>

     

    The shared folder / copy and paste between host and guest does not work!

    Although the vm comes with installed guest additions, those might not work with your version of virtualbox. In this case you need to reinstall the virtualbox guest additions.

     

    Clang is missing!

    We forgot to install Clang in one version of the Rodos-VM  (Sorry!)

    You can fix this by entering the following command in the terminal: sudo apt-get install clang

     

    Reinstalling the VirtualBox Guest Additions

    1.  When the vm is running, click on [Devices] > [Insert Guest Additions CD image]

    2.  Virtualbox will then ask you if it should download the guest additions image.

         Click  [Download]

    3.  In some cases it will ask you again to confirm the download.

        Click  [Download]

    4.  After virtualbox downloaded the image:

        the guest additions cd image can be seen on the vm's desktop.

        Click on it to open the folder with the installation scripts.

    5.  This should open the folder in the File Manager:

    1. Right click into the folder view, and
    2. select  [Open Terminal Here]  in the drop down menu.

    6.  In the terminal type the following command: sudo ./autorun.sh  then hit [RETURN].

    7.  When asked for your sudo passwort type: rodos 2020  then hit [RETURN].

    8.  You should now see a console window showing the output of the installation script.

         Wait till it is finished, then hit any key.

    screenshot of terminal commands and installation output

     9.  Now shut down the vm.

    When you restart the vm, the shared folders and copy & paste should be working.