December - Week 2

3 minute read

Working from the rainforest

Our week 2 post came in a little late, but better than late than never! Doing productive work in Malaysia is really hard. There are tons of distractions around me – from endless errands to chatty relatives. Despite everything I managed to carve out small pockets of time in the middle of the night to get a little work done.


Arch Linux

The Raspi is running on Arch Linux so that there are minimal processes running in the background. This is our first step taken in optimising the camera module – to have a simple system to work with. I have also installed Arch Linux on my laptop which is currently dual booting. As installing C++ libraries on a Windows laptop is a troublesome process, and it seemed impossible after numerous tries, we thought that a Linux system would streamline this process. However, due to my lack of experience with Linux, I cannot boot Arch Linux on my laptop anymore. What happen was that i updated Arch Linux which caused the boot manager to lose the ability to boot it. From this, it is clear that I should have chosen a simpler distro like Ubuntu.

GUI

Previously, in order to identify the different colour values or to change the program, we had to enter the Raspi using VNC. Now that our Raspi do not have a graphical user interface, we have to create a GUI to view the feed from the Picam. With this GUI we could add the functions we want accordingly. Some functions are to toggle between different colour modes instantly, select a region to identify its colour range, and to display such data in charts.

By using the sockets library I could send the frames captured on the Picam to my laptop which is then further processed based on the different settings selected on the GUI.

Looking ahead, more functions would be added to the GUI. One of those functions would be a text editor where I can edit the program inside of the Raspi. Also, after confirming the different calibrations values i.e. colour values and exposure it will be saved in a text file in the Raspi which will be accessed by the main program.

Pi Camera

When we were calibrating the camera this year, we realised that the shade of orange varied when the robot is placed at different parts of the field. This made our colour values unreliable. Therefore, we have looked into white balance calibration as we plan to disable the auto w/b function in the Pi camera.

Since the shade of orange might be constantly changing we could predict the next colour range using the current and past few colour ranges, this allows our program to be more dynamic.


Conclusion

Juggling between work and life in Malaysia is tough. Avoid using Arch Linux as a start, opt for Ubuntu or something simpler. Right now, we are optimising the camera and its calibration process.