TinyGo logo in a red wagon

TinyGo Needs to Get Going

Support for the Pico W?

Mike Riley
The Pragmatic Programmers
3 min readNov 1, 2022

--

https://pragprog.com/newsletter/

Long-time readers of my Medium articles know that I am a fan of the Python language. Those same readers also know that over the past year, I have also become a proponent of Google’s Go language. While I still occasionally use Python for quick and dirty scripts that need to do a simple job without a lot of scale or guaranteed uptime, most of my coding investment these days is with Go. Scalability, easy deployment, multi-OS architecture support, and the simplicity of the language are all major reasons for this current preference.

Back in September of 2022, I wrote an article about how the Raspberry Pi Pico W was a game changing hardware innovation that would dramatically increase the number of automation opportunities for personal and business projects. I have several Pico Ws currently running in my home. They monitor temperature, trigger messages anytime certain events occur, and even control various actuators such as step motors for opening and closing things. Currently, all these operations are written in a version of MicroPython that has been specifically compiled for the Pico W. While this version of Python meets nearly all the controller and networking aspects I need, it’s Python. Wouldn’t it be cool if something like MicroGo existed so I could maintain a consistent language across my Pi servers and Pi Pico microcontrollers? To my surprise, it appears that such an effort is underway in an open-source project called TinyGo. But there’s a problem. A big problem.

As of October 2022, TinyGo supports only the original Pico hardware release. The Pico W has been available for several months, yet no notable updates have been made to TinyGo as of yet. This issue has been opened on the TinyGo GitHub repository site but seems to have stalled. Given that Go was written specifically for networked systems in mind, it’s too bad that more effort isn’t being directed toward resolving this deficiency. Perhaps once the Pico’s wireless networking stack is supported, the TinyGo developers can also work toward supporting (or at the very least, partially supporting) Go’s net/http libraries. While these libraries didn’t make much sense on the original Pico hardware, they will be essential in promoting TinyGo’s popularity with Pico W owners.

Now it may sound as if I’m being a bit harsh on the current state of TinyGo. It’s actually a pretty remarkable subset of the Go language, and to know that it can run on a Pico is a commendable feat in of itself. But as the supply chain constraints for Pico W hardware continues to ease, more Go developers who want to do interesting things with this hardware will amplify the need for TinyGo to support the Pico W and additional Go networking libraries. Otherwise, C and MicroPython will be the only key languages that Pico W enthusiasts will consider in their projects.

Be sure to pick up a copy of Portable Python Projects by Mike Riley, available from The Pragmatic Bookshelf. You can save 35 percent with promo code python_automation_2022 now through November 30, 2022. Promo codes are not valid on prior purchases.

--

--