Book Image

Learning Robotics using Python

Book Image

Learning Robotics using Python

Overview of this book

If you are an engineer, a researcher, or a hobbyist, and you are interested in robotics and want to build your own robot, this book is for you. Readers are assumed to be new to robotics but should have experience with Python.
Table of Contents (14 chapters)
13
Index

Summary


In this chapter, we discussed creating a GUI for ChefBot that can be used by an ordinary user who doesn't have any idea about the internal working of a robot. We used Python binding of Qt called PyQt to create this GUI. Before we go to the main GUI design, we saw a Hello World application to get an easier understanding of PyQt. The UI design was done using the Qt Designer tool and the UI file was converted into its equivalent Python script using Python UI compiler. After designing the main GUI in Qt Designer, we converted the UI file into Python script and inserted the necessary slots in the generated script. The ChefBot GUI can start the robot, select a table number, and command the robot to get into that position. The position of each table is acquired from the generated map we hardcoded the positions in this Python script for testing. When a table is selected, we set a goal position on the map, and when we click on the Go button, the robot will move into the goal position. The...