liveBook · Manning

What you will learn in Build Your Own Robot: Using Python, CRICKIT, and Raspberry Pi

Using Python, CRICKIT, and Raspberry PI

by Marwan Al-Sabbagh

Chapter by chapter

Chapter 1: What is a robot?

1.1 Why robots are amazing · 1.2 Our approach to making robots · 1.2.1 Learning from failures · 1.2.2 What will you gain? · 1.2.3 Prototyping · 1.2.4 Teaching · 1.2.5 Production ready · 1.2.6 Limitations · 1.3 What are robots made of? · 1.3.1 The robot building blocks · 1.3.2 Servos and DC motors on a Raspberry Pi · 1.3.3 Hardware stack · 1.3.4 Python and Linux · 1.3.5 Software stack · 1.4 Summary

What you learn in chapter 1 →

Chapter 2: Getting started

2.1 Introducing our robotic hardware · 2.1.1 Raspberry Pi · 2.1.2 Adafruit CRICKIT HAT · 2.2 Configuring the software for our robots · 2.3 Changing Neopixel colors · 2.4 Checking the touch sensor state · 2.5 Controlling DC motors · 2.6 Controlling motors with the touch sensor · 2.7 Summary

What you learn in chapter 2 →

Chapter 3: Driving the robot

3.1 What’s a robot chassis kit? · 3.2 Hardware stack · 3.3 Software stack · 3.4 Writing a move forward function · 3.5 Using environment variables for configuration · 3.6 Controlling the speed and duration of movements · 3.7 Moving backward · 3.8 Turning right · 3.9 Moving left and spinning in either direction · 3.10 Refactoring by finding common logic · 3.11 Refactoring by using functools · 3.12 Summary

What you learn in chapter 3 →

Chapter 4: Creating a robot shell

4.1 What’s a REPL or shell? · 4.2 Benefits of a REPL · 4.3 Hardware stack · 4.4 Software stack · 4.5 Creating the robot shell · 4.6 Handling command arguments · 4.7 Adding a speed argument · 4.8 Running robot shell scripts · 4.9 Summary

What you learn in chapter 4 →

Chapter 5: Controlling robots remotely

5.1 Hardware stack · 5.2 Software stack · 5.3 Robot testing tips · 5.4 Controlling robots over SSH · 5.4.1 Creating the server-side script · 5.4.2 Running the script remotely · 5.4.3 Creating the client-side script · 5.5 Creating web services for robots · 5.5.1 Creating our first web service · 5.5.2 Creating web services to perform robot movements · 5.6 Calling web services from Python · 5.6.1 Using the read–evaluate–print loop to call web services · 5.6.2 Creating a basic web service client · 5.6.3 Creating a web service client with persistent connections · 5.6.4 Measuring client performance · 5.7 Summary

What you learn in chapter 5 →

Chapter 6: Creating robot web apps

6.1 Hardware stack · 6.2 Software stack · 6.3 Moving robots forward and backward over the web · 6.3.1 Creating a basic web application · 6.3.2 Detecting failed requests · 6.3.3 Moving robots forward with web apps · 6.4 Creating a full-movement web app · 6.4.1 Creating the full-movement application · 6.4.2 Web interface design · 6.4.3 Measuring application performance in the browser · 6.4.4 Web hardware devices · 6.5 Summary

What you learn in chapter 6 →

Chapter 7: Joystick-controlled robots

7.1 Hardware stack · 7.2 Software stack · 7.3 Joystick events · 7.4 Reading joystick events using Pygame · 7.4.1 Detecting events in Pygame · 7.4.2 Detecting joystick events · 7.5 Reading Linux joystick events · 7.5.1 Exploring the Linux input subsystem · 7.5.2 Unpacking joystick events · 7.5.3 Mapping joystick events · 7.5.4 Working with axis events · 7.6 Measuring the rate of joystick events · 7.6.1 Calculating the event rate · 7.6.2 Calculating the level rate · 7.7 Moving robots with joysticks · 7.7.1 Creating the joystick client · 7.8 Summary

What you learn in chapter 7 →

Chapter 8: Keyboard-controlled camera

8.1 Hardware stack · 8.2 Software stack · 8.3 Capturing images using OpenCV · 8.3.1 Exploring the OpenCV library · 8.3.2 Drawing shapes and displaying text with OpenCV · 8.3.3 Taking snapshots with OpenCV · 8.4 Moving a camera with servos · 8.4.1 Exploring the servo motors with the CRICKIT library · 8.4.2 Performing a pan-and-tilt sweep · 8.4.3 Controlling servos and the camera together · 8.5 Summary

What you learn in chapter 8 →

Chapter 9: Face-following camera

9.1 Hardware stack · 9.2 Software stack · 9.3 Detecting faces in an image · 9.3.1 Exploring face detection · 9.3.2 Marking detected faces · 9.4 Detecting faces in live video · 9.4.1 Measuring face detection performance · 9.4.2 Reducing the number of pixels to process · 9.4.3 Optimizing face detection performance · 9.4.4 Showing detected faces in live video · 9.5 Creating a face-following robot · 9.5.1 Zoning the face detection · 9.5.2 Moving motors to follow faces · 9.6 Summary

What you learn in chapter 9 →

Chapter 10: Robotic QR code finder

10.1 Hardware stack · 10.2 Software stack · 10.3 Detecting QR codes in an image · 10.3.1 Exploring QR codes · 10.3.2 Marking detected QR codes · 10.4 Streaming live video to multiple applications · 10.4.1 Saving the video stream to a ramdisk · 10.4.2 Watching the filesystem for changes · 10.4.3 Streaming to a graphical application · 10.4.4 Detecting QR codes in a video stream · 10.4.5 Streaming to a web browser · 10.5 Moving the robot to a target QR code · 10.5.1 Find the QR code · 10.6 Summary

What you learn in chapter 10 →

Chapter 11: Building a snack-pushing robot

11.1 Hardware stack · 11.2 Software stack · 11.3 Finding and pushing snacks · 11.3.1 Reading the list of snacks · 11.3.2 Pushing snacks · 11.4 Creating the snack-pushing application · 11.4.1 Selecting snacks with the application · 11.4.2 Styling the web application · 11.4.3 Adding the live video stream to the application · 11.5 Summary

What you learn in chapter 11 →

Concepts explained in this book

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.