Building An Inexpensive Remote Controlled Robot
INTRODUCTION
The micro:bit is an inexpensive, easy to program computer with a slew of built-in hardware capabilities:
-
A 5x5 LED Matrix
-
Two programmable push buttons.
-
An on-board motion detector.
-
A built-in compass.
-
A radio module to communicate with other micro:bit computers.
These items can be programmed easily using Python, JavaScript or C++.
Upon acquiring a micro:bit, I experimented with writing programs for the on-board actuators and sensors using Python. The micro:bit Python API is easy to understand and all the devices are simple to monitor and control. Having the "basics" under my belt, I started looking for a more challenging micro:bit project. So I wondered, how easy would it be to create a micro:bit robot vehicle with remote control using the micro:bit radio interface? This would give me the opportunity to experience connecting the micro:bit to additional external hardware and see how flexible the micro:bit really is.
And so, this project was born. Here is my list of what I wanted the vehicle to be capable of doing:
-
Be inexpesensive and easily assembled from a set of off the shelf parts.
-
Basic mobility capabilities:
-
Drive forward
-
Drive in reverse
-
Turn left
-
Turn right
-
Spin left
-
Spin right
-
Brake.
-
-
Additionally:
-
The robot must have the ability to autonomously perform obstacle avoidance maneuvers (we don't want to hit the furniture).
-
The robot must have the ability to be controlled remotely using the micro:bit radio interface.
-
The following types of remote control interfaces must be provided without the need to re-flash the robot vehicle when changing remote types:
-
Web Page Graphical User Interface(GUI).
-
Tkinter GUI.
-
A micro:bit native gestures interface.
-
An external button controller
-
-
In the following sections of this document, we will discuss:
-
Building and coding the robot vehicle.
-
Coding and using the remote controllers.
The source code for this project is available on GitHub.