Project 5: Build a Robot with a Streaming Camera Feed
It's been a long journey, but we've reached our final project in this book. The previous four projects focused on practical uses for the Tinker Board, but for the grand finale we're going to stray a bit from the practical and build a simple robot that can
- PDF / 1,854,043 Bytes
- 30 Pages / 439.37 x 666.142 pts Page_size
- 80 Downloads / 173 Views
Project 5: Build a Robot with a Streaming Camera Feed It’s been a long journey, but we’ve reached our final project in this book. The previous four projects focused on practical uses for the Tinker Board, but for the grand finale we’re going to stray a bit from the practical and build a simple robot that can be operated via a custom Bluetooth controller and will stream video.
Why a Robot? A robot is the quintessential electronics project. Robots come in many varieties and can be very simple or incredibly complex. By now you’re well aware of the Tinker Board’s features, and once again the Internet connectivity, full operating system, and diverse IO options beyond GPIO make it a great platform for a robot with more features than your average beginner robot.
© Liz Clark 2019 L. Clark, Practical Tinker Board, https://doi.org/10.1007/978-1-4842-3826-4_11
287
Chapter 11
Project 5: Build a Robot with a Streaming Camera Feed
Robot Supplies For the construction of the robot, we’ll be using two DC motors with wheels attached to a mini robot chassis. If you want to use a different motor type, such as gearbox motors, you can. The concept will be the same. For the chassis, there are countless options available on the market, and the one you choose really comes down to personal preference since its purpose is to hold the electronics and attach the motors. Different shapes, colors, or materials won’t affect the robot’s technical outcome. To keep everything mobile, the Tinker Board will be powered by a USB battery bank, which will be mounted to whatever chassis you choose. You’ll need a high-capacity battery bank, especially with the Tinker Board’s amperage concerns. Luckily, these larger capacity battery banks are becoming more common and are also available in smaller sizes. Because of this you will probably get better power results with the original Tinker Board than the Tinker Board S, since the Tinker Board S needs 3A to boot. Of course, something needs to control the motors, since hardware PWM is not available on the Tinker Board’s GPIO and is a necessary feature when it comes to controlling motors. As a result, we’ll be using another HAT, this time by Adafruit, specifically the Motor HAT. Additionally, we’ll use their Python library for the HAT, which will make coding the motors’ movement a lot more straightforward. Adafruit was mentioned in the GPIO chapter as an option for procuring electronics supplies. In addition to selling standard electronics components, they’re also an open source hardware company in the United States that designs, manufactures, and supports a variety of boards produced in-house.
288
Chapter 11
Project 5: Build a Robot with a Streaming Camera Feed
I2C The HAT communicates with the Tinker Board through I2C (Inter- integrated Circuit, pronounced “I squared C”), which is a serial communication protocol that is very similar to SPI in that it allows for multiple integrated circuits to communicate with each other. However, I2C requires only two pins to communicate with multiple devices; by
Data Loading...