Summary of steps
Virtual Box to VMware Workstation player
Export VirtualBox appliance
- Power off your virtual machine. Do not save the machine state. Shutdown the virtual machine.
sudo shutdown --poweroff now
-
Click on File -> Export Appliance
-
This will generate an OVA file. The location of my Ubuntu.ova file was
C:\Users\vdhiman\Documents\Ubuntu.ova
The file size for me was around 50 GB.
Install VMware Workstation player
-
Download non-commercial version of VMware Workstation player from here:
-
Install VMWare.
Import VirtualBox in VMware Workstation player
- “Open” the Ubuntu.ova saved earlier.
-
Make sure you are enable the following hardware settings:
-
Edit virtual machine settings
-
Set VMware memory to 75% of your available memory.
-
Set processors to 50% of your available processors. Enable VT-x .
-
Enable 3D acceleration and allow up to 8GB of video memory.
-
-
Play the virtual machine
-
Inside Ubuntu uninstall vbox-guest-additions
sudo vbox-uninstall-guest-additions
-
-
Install open-vm-tools
```
sudo apt install open-vm-tools open-vm-tools-desktop
```
- Reboot
```
sudo shutdown --reboot now
```
Check 3D performance
- Run glmark2 to check 3D performance
glmark2
In Virtual Box, I got only 300 FPS but in VMWare, I get more than 1200 FPS.
Check Lab 5
- Change directory to location of Lab 5
source devel/setup.bash catkin_make source devel/setup.bash roslaunch car_demo demo-light.launch
- We will disable software rendering and enable hardware acceleration in Gazebo.
To disable software rendering open
demo-light.launch
and remove the following line:
<env name="LIBGL_ALWAYS_SOFTWARE" value="1" />
Run gazebo. For me this did not work in VMware.
-
Instead replace the above env line in the
demo-light.launch
with env line given below. Falling back to OpenGL 2.1 from OpenGL 3.3<env name="SVGA_VGPU10" value="0" />
-
I get 60 FPS on gazebo
Connecting joystick to VMWare
- When you connect the USB device to the computer, it will ask whether you want to connect it the host or the virtual machine. Select that you want to connect it to virtual machine.
- Check that “Player” -> “Removable devices” -> “Shenzen Shenwan PC/PS3/Android” is checked.
- If not, click “Connect (Disconnect from host)”
- Check “/dev/input/jsX” using
ls
andjstest
ls /dev/input/js*
The only device I see on my machine is /dev/input/js0
. Check if that is the right device.
jstest /dev/input/js0
Press some buttons on the joystick, if the output on the terminal changes, then it is the right joystick.
Exercise 1
- What FPS did you get with glmark2?
- What FPS did you get with gazebo?