Programming the Raspberry Pi Pico/W

in MicroPython, Third Edition

Second Edition Resources 

Errata 

Program Listings: Github Repo

Resources 

PicoPython3E360

Buy from: Amazon

Reviews of previous editions

“This book is great, written by an engineer, showing you how to get around limitations of MicroPython. Has a good section on PIO, I2C, SPI and what to do when they don't work. have read most of the other books on Pi Pico, and this is by far the best.”

"Obviously the author knows his stuff. I love the writing style and helpful hints to deal with Python limitations."

"Book contains many nuggets of info not found in other books."

"The book provides a very good guide through the MicroPython programming of the Raspberry Pi Pico and also goes into enough depth. It has shown me many tricks and tricks that I haven't found anywhere else so far."

“You won’t learn Python from this book, but if you want to know how to use Python on the Pico, then this book is for you, and it is probably the best one out there. There are lots of useful techniques and examples. When I need to know something about Python on the Pico, this is the book I turn to. It is clear and well written. Just buy it!”

“I think this book together with a primer on MicroPython would be a great choice for a beginner. Lots of great examples and it’s obvious the author has programmed the Pico in Python.”


“Shows how to integrate python with assembly language for speed - which not many other guides describe.”

This updated and expanded edition was prompted by the launch of the Pico 2 and Pico 2W which use a new chip, the RP2350, with significant improvements but also changes. This book therefore covers four devices, the new Pico 2 and its WiFi counterpart, the Pico 2W, as well as the original Pico and Pico W.

MicroPython is a good choice of language to program the Pico. It isn’t the fastest way, but in most cases it is fast enough to interface with the Pico’s hardware and its big advantage is that it is easy to use. As a high-level language, MicroPython is based on Python 3 and is fully object-oriented. This means that you can create classes to encapsulate hardware and makes it easier to use and understand.

The purpose of the book is to reveal what you can do with the Pico's GPIO lines together with widely used sensors, servos, motors and ADCs. After covering the GPIO, outputs and inputs, events and interrupts, it gives you hands-on experience of PWM, the SPI bus, the I2C bus and the 1-Wire bus. One of the key advantages of the Pico is its PIO (Programmable I/O) and while this is an advanced feature, it is introduced in this book. After finding out how the PIO works, we apply it to writing a PIO program for the DHT22 and the 1-Wire bus. Three chapters are dedicated to how to make use of the additional features of the Pico W, including how to create a web client and a web server, use HTTPS and asyncio. Finally we look at more advanced hardware, Watchdog timer, file system, SDcard reader, using the second core and more.

Jointly authored by Harry Fairhead and Mike James, this book combines Harry’s expertise in electronics and the IoT with Mike’s knowledge of Python. They have also collaborated on similar titles for the Raspberry Pi, the Raspberry Pi Compute Module 5 and the ESP 32.

Harry Fairhead is also the author of Programming theRaspberry Pi Pico/W in C,Fundamental C: Getting Closer To The Machineand Applying C For The IoT With Linux.

Mike James is the authorof the Programmer's Python: Something Completely Different series of books which set out to show how Python diverges from other programming languages and how its special features deserve our attention and Extending and Embedding Python Using C in which he solves many of Python's speed-related problems.

 Paperback 

  • Publisher ‏ : ‎ I/O Press
  • Publication date ‏ : ‎ July 24, 2025
  • Language ‏ : ‎ English
  • Print length ‏ : ‎ 394 pages
  • ISBN-10 ‏ : ‎ 1871962978
  • ISBN-13 ‏ : ‎ 978-1871962970
  • Item Weight ‏ : ‎ 1.87 pounds
  • Dimensions ‏ : ‎ 7 x 0.89 x 10 inches

Kindle 

  • ASIN ‏ : ‎ B0FJYJF77Q
  • Publisher ‏ : ‎ I/O Press
  • Publication date ‏ : ‎ July 24, 2025
  • Edition ‏ : ‎ 3rd
  • Language ‏ : ‎ English
  • File size ‏ : ‎ 10.7 MB

Hardback

  • Publisher ‏ : ‎ I/O Press (December 28, 2022)
  • Language ‏ : ‎ English
  • Hardcover ‏ : ‎ 360 pages
  • ISBN-10 ‏ : ‎ 1871962064
  • ISBN-13 ‏ : ‎ 978-1871962062
  • Item Weight ‏ : ‎ 1.72 pounds
  • Dimensions ‏ : ‎ 7 x 1 x 10 inches