Graphical User Interface: Design and Implementation
- Munifa
- Apr 10, 2020
- 2 min read

The Graphical User Interface (GUI) allows the user to interactively control the trike. When the application is started, a loading frame is displayed while peripheral devices (such as the motor controllers) are initialized in the background. Once all the initializations are completed, the main application frame is displayed on the touchscreen. The main frame displays some instructions relating to the use of brake levers, the Xbox controller and the emergency power switch. In auto mode, a color image overlaid with depth data from the Intel RealSense D435 camera is also displayed on the touchscreen. This allows the user to observe what the camera is “seeing”, so if there is an obstacle that the camera fails to identify, the user can apply the brakes in time.

The five buttons function as follows:
Start Trip: After initializing all the peripherals and setting up the threads, the code enters a ‘waiting’ state and remains in that state (by looping) until this Start Trip button is pressed. We can improve the system’s efficiency by modifying this ‘waiting’ state to be an ‘idle’ state. In ‘idle’ state, we would put the Jetson and other power-hungry components in an idle or low-power mode.
End Trip: When this button is pressed, the system returns to the ‘waiting’ state described above.
Switch to Auto Mode/Switch to Manual Mode: By pressing this button, the user can toggle between the auto and manual modes. In manual mode, the user can control the trike using the Xbox controller. In auto mode, the PI Control and Computer Vision subsystems collect and process data to autonomously drive and steer the trike.
Quit: When this button is pressed, a confirmation prompt is displayed. If the user responds in affirmative, then a sequence of de-initializing subroutines are executed in the background to safely disconnect and/or turn off all connected devices.
Fullscreen/Exit Fullscreen: This is more for development purposes to allow us to resize the screen and view any debugging information printing on the terminal.

When an obstacle is detected, e-brake is automatically applied, and the user is prompted to take manual control.
Overall, our intention with this GUI design was to make it simple, informative and user friendly.
MATERIALS REFERENCED
Comentarios