
Simple electronics with GPIO Zero
Take control of the real world with your Raspberry Pi
Phil King(Author)
Raspberry Pi Press
2nd Edition
Published on 27. June 2025
Book
Paperback/Softback
132 pages
978-1-916868-44-1 (ISBN)
Description
There are many things that distinguish Raspberry Pi from other computers. The GPIO header might just be the most significant of them all - it allows you to connect electronic components to your Raspberry Pi and control them with code you've written yourself.
The most popular programming language for controlling electronics on a Raspberry Pi is Python, particularly the code in the GPIO Zero library, which you can use to control LEDs, sensors, motors, and many more components.
With this book, you'll learn how to use GPIO Zero as you build a series of simple electronics projects:
Program some LED lights
Add a push button to your project
Build a motion-sensing alarm
Create your own distance rangefinder
Make a laser-powered tripwire
Build a Raspberry Pi robot
The GPIO pins on your Raspberry Pi open up a whole new world of possibilities - specifically, the physical world around you. It may seem daunting at first, but you'll be creating electronic circuits and controlling them with code before you know it. Grab your breadboard and start taking control of the real world with your Raspberry Pi today!
Updated for the latest Raspberry Pi devices, this book has all the information you need to get started.
The most popular programming language for controlling electronics on a Raspberry Pi is Python, particularly the code in the GPIO Zero library, which you can use to control LEDs, sensors, motors, and many more components.
With this book, you'll learn how to use GPIO Zero as you build a series of simple electronics projects:
Program some LED lights
Add a push button to your project
Build a motion-sensing alarm
Create your own distance rangefinder
Make a laser-powered tripwire
Build a Raspberry Pi robot
The GPIO pins on your Raspberry Pi open up a whole new world of possibilities - specifically, the physical world around you. It may seem daunting at first, but you'll be creating electronic circuits and controlling them with code before you know it. Grab your breadboard and start taking control of the real world with your Raspberry Pi today!
Updated for the latest Raspberry Pi devices, this book has all the information you need to get started.
More details
Edition
2nd Revised edition
Language
English
Place of publication
Cambridge
United Kingdom
Edition type
Revised edition
Product notice
Paperback (trade)
Illustrations
Illustrations
Dimensions
Height: 210 mm
Width: 151 mm
Thickness: 17 mm
Weight
223 gr
ISBN-13
978-1-916868-44-1 (9781916868441)
Copyright in bibliographic data and cover images is held by Nielsen Book Services Limited or by the publishers or by their respective licensors: all rights reserved.
Schweitzer Classification
Other editions
Additional editions

E-Book
06/2025
2nd Edition
Raspberry Pi Press
€4.49
Available for download
Person
Phil King is a Raspberry Pi enthusiast and regular contributor to The MagPi magazine. Growing up in the 'golden era' of 8-bit computers in the 1980s, he leapt at the chance to write about them in magazines such as CRASH and ZZAP!64. When consoles took over the video games world, he missed the opportunity to program... until the Raspberry Pi came along. Phil is now an avid coder and electronics dabbler, who loves to work on projects with his six-year¿old son.
Content
- Get started with electronics and GPIO Zero
- Control LEDs with GPIO Zero
- User input with a push button
- Make a push button music box
- Measure CPU usage with an RGB LED
- Make a motion-sensing alarm
- Make a range finder
- Make a laser tripwire
- Build an internet radio
- Create an LED thermometer
- Build a GPIO Zero robot
- Appendices:
- Output devices
- Input devices
- SPI devices
- Boards, accessories, and system devices