FAQ
Setup
1. Ubuntu keeps complaining about low disk space.
Refer to this tutorial for info on increasing the disk space allotted to your VM.
2. Installing Guest additions throws an error.
Run the following command in a terminal in the Ubuntu VM:
sudo apt install virtualbox-guest-additions-iso
Now, try again to install the Virtualbox Guest Additions from the Devices menu in Virtualbox (Refer Lab1).
3. How do I make the Bluetooth adapter work in the VM?
- Passthrough the USB Bluetooth controller to the VM by navigating to the Devices menu in Virtualbox and selecting the USB Bluetooth adapter (It should have the words with “Broadcom BCM” in it). This step essentially allows the VM to take control of the Bluetooth adapter, by relinquishing the host OS of its access privileges.
- If the Bluetooth USB adapter is successfully captured by the VM, you should see no error messages displayed by Virtualbox and when you run the below command in the Ubuntu VM, you should see some output:
sudo hciconfig
- Your Bluetooth code from Lab2 should work from within the Ubuntu VM now.
4. I am running a Windows host and the Bluetooth adapter does not not passthrough to the VM.
If you see an error message indicating the Bluetooth adapter was not successfully captured by the VM for some reason, it might be that your host OS is Windows and it is being possessive. We are now going to forcefully rip the bluetooth adapter out of its hands. (This is a metaphor of sorts, don’t actually unplug the bluetooth adapter just yet)
- In Windows, open Device Manager.
- Navigate to the section “Bluetooth” and click on the small down arrow next to it.
- Right-click on the “Broadcom” Bluetooth adapter and select “Uninstall Device”.
- You may see multiple Bluetooth devices under this section as your laptop/pc may come with its own Bluetooth device. Make sure you uninstall the right one!
- In the popup window, select the check box “Delete the driver software for this device” and click on “Uninstall”.
- Unplug and re-plug the Bluetooth adapter and it should not be listed under the “Bluetooth” section in Device Manager.
- In the VM, try to passthrough the Bluetooth adapter once again and check if it works.
- Verify by running
sudo hciconfig
on a terminal in the Ubuntu VM; it should list a valid bluetooth adapter.
- Verify by running
- If it still fails to passthrough, unplug and re-plug the Bluetooth adapter.
- Open Device Manager in Windows.
- Right click on the “Broadcom” Bluetooth adapter and select “Disable Device” and restart your computer (Host OS).
- After the restart, open Device Manager in Windows and double click on the “Broadcom” Bluetooth adapter. It should inform you that the device is disabled.
- Now, start the VM and try to passthrough the Bluetooth adapter from the Devices Menu.
- Verify by running
sudo hciconfig
on a terminal in the Ubuntu VM; it should list a valid bluetooth adapter.
- Verify by running
All Lab solutions (for internal use only)
Lab 9
1. Instantiating the Mapper class throws an error.
- Check if your map definition has equal number of start and end points.
- Make sure your map is bounded by obstacles. If not, add a bounding box around the map.
- If your map is larger than , change the “ray_length” parameter when instantiating the Mapper class. It specifies the length of the ray used in ray casting and should be greater than the maximum distance between any two points on the perimeter of the map.
- Make sure your rotation behavior conforms to the specifications. The robot needs to perform a full, anti-clockwise 360 degree rotation with at least 18 approximately equally spaced readings from the TOF sensor.
2. How to improve the accuracy of the Bayes filter?
- You may need to change the noise parameters of the odometry and sensor models. Refer to the Jupyter notebook “lab9_real.ipynb” for more info.
- Since your odometry is quite noisy, especially in the linear direction, reduce the distance moved in each iteration of the Bayes filter. You may even use a specific speed that provides slightly more accurate odometry data.
- When you move your robot, consider the lower limits of the sensor and how it may affect your measurement likelihood.
- Regarding the PID controlled rotational scan behavior,
- The 18 measurements should be equally spaced
- The total rotation should be close to 360 degrees
- The radius of the rotation should be small
3. How can I verify if my rotation behavior works correctly?
I am glad you asked. As part of an in-class exercise, we provided you with a function that plots the true measurements (based on ray-casting in the map) and the observation data in the plotter. Use it to your advantage.