3. Hypervisor Initialization
3.1. First Time Initialization
After finishing the setup and rebooting a boot menu is shown and the default entry Ubuntu Configure RTOSVisor is selected, keep this and do not select any other entry.
After logging in, you need to change to the hypervisor bin directory:
cd /hv/bin
In the next step, the hypervisor needs to be initialized, also memory settings for the real-time guest OS have to be defined (these settings are rtos-dependent!). Use the inithv script:
sudo ./inithv.sh [-baseaddr rtos_baseaddr] rtos_memsize shm_memsize
The optional -baseaddr parameter of the inithv.sh script will set the physical base address where the RTOS shall be located.
This parameter is required for RTOS guests which are not relocatable (e.g. VxWorks or RTOS-32).
The next parameter defines the amount of memory to be assigned to the real-time guest OS, the last parameter will define the shared memory pool size.
All units are in MB.
Real-time Linux guest:
sudo ./inithv.sh 256 16VxWorks guest:
sudo ./inithv.sh -baseaddr 64 64 16On Time RTOS-32 guest:
sudo ./inithv.sh -baseaddr 64 64 16
Caution
If you want to install a Windows or Ubuntu guest, the shared memory pool size must be at least 16 MByte and a power of 2 (16, 32, 64, 128, etc.)!
Caution
If you get the message WARNING: CPU frequency not stable... when running the inithv.sh script, you may not have properly disabled power settings in the BIOS. Please follow the respective instructions above (Prerequisites).
After! rebooting the Hypervisor, resetting the configuration using the hv_resethv command may fix this issue (hv_resethv implicitly re-runs inithv).
Hint
hv_adjmemconf command.hv_adjmemconf -baseaddr 64 768 32
Now, to get the changes effective, a reboot is required:
sudo reboot
3.2. Reset Hypervisor Initialization
At any time later, you can reset the hypervisor initialization using the hv_resethv command.
Running this command will also reset the configuration (located in /hv/config) as well as the example guests (located in /hv/guests/examples).
You should preserve the previous configuration and guest settings in case you have changed them.
The hv_resethv command will automatically try to preserve these folders (e.g. into /hv/config.bak).
If these preserved folder already exist, you may run hv_resethv -force to automatically remove the current settings without preserving them.
hv_resethv [-force]
You may also use different a memory configuration when running hv_resethv. The same parameters are used as in inithv.sh.
The following command will reset the configuration and set the RTOS memory size to 768 MByte and the Shared Memory size to 32 MByte. The base address settings will taken over from the previous configuration settings.
hv_resethv 768 32
The following command will reset the configuration and set the RTOS memory base address to 96 MByte, the RTOS and Shared Memory size will be taken over from the previous configuration settings.
hv_resethv -baseaddr 96
The following command will reset the configuration, set the RTOS memory base address to 64 MByte, set the RTOS memory size to 256 MByte and the Shared Memory size to 16 MByte.
hv_resethv -baseaddr 64 256 16