Learn the fundamentals of robotics - Part 1
The Robot revolution is coming. Robots are no longer just machines of science fiction, from self-driving cars, to flying drones, robots are on the march. Over the next few years robots are going to be seen all over the place and will be increasingly used in agriculture, manufacture, medicine, education, as well as in our own homes. The amazing thing is that now almost anyone can become a roboticist and if you have a Raspberry Pi you’re already half way there.
Before we get into the what and how-to of any robotics, the first question may be why would you want to build a robot with a Raspberry Pi in the first place? Also, what kind of things will a Raspberry Pi robot be able to do?
The great thing about robots is that they are physical and immersive. Instead of providing output to pixels on a screen, a robot is in your personal space and its movements, lights and sounds go way beyond the limits of a screen. With the Raspberry Pi and some low cost hardware, not only can you make a robot move, you can make a robot that can speak, dance and a whole lot more besides! Why wouldn't you want to turn a Raspberry Pi into a robot?
What makes the Raspberry Pi so good for robotics (as well as so many other projects) is its special GPIO port (General Purpose Input Output). This allows the Raspberry Pi to connect to all kinds of electronics and hardware. The fundamental requirements for the most interesting robots are the ability to both sense and interact with their environment, and it is the GPIO port of the Raspberry Pi that makes this possible.
Before going into further details for building a simple robot, let's first consider some robot fundamentals.
What makes a robot robotic?
Wikipedia defines a robot as a machine which can be electronically programmed to carry out a variety of physical tasks or actions". In addition to this requirement to perform physical actions, a proper robot should also have an autonomous ability. Autonomy allows a robot to act independently in the world and this makes them different from things like radio controlled vehicles that are not able to function by themselves. The Raspberry Pi's processing ability (both CPU and GPU), along with its GPIO port, gives it lots of potential for developing autonomous behaviour. As a simple example let's take a look at the classic line following robot.
A line following robot has the ability to move forward, change direction and detect a line on the ground. This is a classic example of autonomous behaviour. No matter where the line leads, the robot is programmed to follow the line without the need for any external control.
While autonomous behavior can be very useful in a robot it can also be a lot of fun to control it directly. Some of the most interesting applications happen when a robot combines the two. Imagine a flying robot that can fly around at your command but can also be programmed never to crash into walls and other obstacles.
Anatomy of a Raspberry Pi robot
Let us go through all the things you need to build your own robot using a Raspberry Pi. I will detail a minimal possible Raspberry Pi robot step by step. These basic steps are:
As you can see it's really simple to get started on robotics, all you need is a few basic materials, enthusiasm about the topic and some spare time. Nowadays everyone can became a roboticist.