If you missed Tuesday’s Python on Microcontrollers Newsletter, here is the ICYMI (in case you missed it) version.
To never miss another issue, subscribe now! – You’ll get one terrific newsletter each Tuesday (before this post). Over 8,816 subscribers worldwide!
The next newsletter goes out in a week and being subscribed the best way to keep up with all things Python for hardware. No spam, no selling lists, leave any time.
Welcome to the latest Python on Microcontrollers newsletter, brought you by the community! We’re on Discord, Twitter, and for past newsletters – view them all here. If you’re reading this on the web, subscribe here. Let’s get started!
Adafruit Sponsoring PyCon US 2021
PyCon is the largest annual gathering for the community using and developing the open-source Python programming language. It is produced and underwritten by the Python Software Foundation, the 501(c)(3) nonprofit organization dedicated to advancing and promoting Python. Through PyCon, the PSF advances its mission of growing the international community of Python programmers.
The conference is happening May 14-15, 2021, with sprints to follow. Learn more at PyCon.org!
Mu 1.0 beta 4 Released!
Mu 1.0 beta 4 has been released! This release includes a number of bug fixes and back-end updates, including a new way to detect CircuitPython boards and find the CircuitPython REPL connection.
CircuitPython Deep Dive Stream with Scott Shawcroft
This week, Scott streams his work on MicroPython merging.
You can see the latest video and past videos on the Adafruit YouTube channel under the Deep Dive playlist – YouTube.
News from around the web!
An animation demonstrating the Adafruit Circuit Playground Express acting as an intervalometer to remotely fire the shutter on a Sony camera using infrared commands, the code also features a manual mode where the CPX left button fires the shutter, both useful for stable, vibration-free photography – YouTube.
PicoTouch PCBs designed to work with Raspberry Pi Pico and CircuitPython – Twitter.
Gherkin PCB built specifically for the Raspberry Pi Pico running CircuitPython – 40% Keyboards.
KMK running on the Raspberry Pi Pico using CircuitPython – 40% Keyboards.
A Bluetooth keyboard for controlling the Zoom application, based on an Adafruit NeoTrellis and Feather nRF52840 Express – GitHub.
A functional smart display using CircuitPython, inspired by the tech in Black Panther, built with Marvel API – Twitter.
SMARS-mini-XL, a small wheeled or tracked robot running on CircuitPython – GitHub.
A Raspberry Pi Pico, CircuitPython and an ILI9341 SPI Display with Touch – Hello Raspberry Pi.
The Preader, a Raspberry Pi RP2040-powered, bi-stable ChLCD display e-reader – Hackster.
A simple IoT RGB control project with Raspberry Pi Pico, WIZnet W5500, NeoPixel, and Adafruit WIZNET5K CircuitPython library – Hackster.
Custom USB game controllers with Raspberry Pi Pico, using CircuitPython – Raspberry Pi.
Pico Portal music box running CircuitPython – Hackster.
CircuitPython example using VEML7700 lux sensor and an Adafruit Feather M0 – Learn MicroPython.
Using CircuitPython and the Adafruit CLUE to create a small data visualisation – Twitter.
Moving from a Python library to a CircuitPython library is a few simple modifications – Twitter.
A NeoKey keyboard with LCD, running on a Raspberry Pi Pico and an Adafruit Airlift – GitHub.
MagTag pool temperature monitor – Hackaday.
A Pokeball lamp complete with sound effects, running CircuitPython – Twitter.
Weekend fun with Raspberry Pi Pico, MicroPython and Thonny – Twitter.
So many Picos, so many purposes, including CircuitPython – Twitter.
Raspberry Pi Pico Essentials: 50 MicroPython projects for Pico – Twitter.
Adafruit QT Py RP2040 review: A tiny board for great projects – Tom’s Hardware.
Testing CircuitPython library support for u2if on Raspberry Pi Pico – Adafruit Blog.
Taking the next step in Python game development – Real Python.
The first stage in development of an open source ultrasound kit for college / high school comes to an end – Twitter.
PocketQube picosatellite platform now available for pre-order – Twitter.
Learn text Classification with Python and Keras – Real Python.
Deploying a Python Flask example application using Heroku – Real Python.
Add easy battery management to your Pico project with the Pimoroni LiPo SHIM – site.
Train a neural network model in 10 minutes, and use it on ESP32 with MicroPython to control a light switch – Hackster.
Pyodide consists of the CPython 3.8 interpreter compiled to WebAssembly which allows Python to run in the browser – Mozilla.
This is a basic Python shell that takes a task and asks OpenAI for what Linux bash command to run based on your description – onfabrica.com.
Some Open-source hardware stats: OSHdata ends, OSHWA API and more – Adafruit Blog.
Head First Programing Humble Bundle, including Head First Python – Humble Bundle.
An excellent write up on using the SAMD21’s brown-out detector – Thea.codes.
A Python-powered microscope running on Raspberry Pi – GitHub.
A collection of tutorials on Python best practices – Real Python.
A MicroPython module for the OV2640 camera – GitHub.
Yayagram, a device designed to allow grandparents to communicate with their grandchildren – Twitter.
Sailor Hat with ESP32 runs MicroPython – GitHub.io.
Testing out a QT Py RP2040 expansion board – Adafruit Blog.
Playing around with pseudo color polynomial algorithms in CircuitPython – Twitter.
Working through a wrist injury with a foot pedal powered by CircuitPython and a QT Py, with blue tape for strain relief. Stomp once to build and run – Twitter.
CPX Pinout card (Japanese) – STEAM Tokyo.
Updated version of the NeoPixel watch fob, now with power management in the form of a Sparkfun Soft Power Switch – Twitter.
The easiest way to create a README – Readme.so.
The social contract of open source: a post on how to treat maintainers in a positive way – Snarky.ca.
PyDev of the Week: Haki Benita on Mouse vs Python
Snap-apart ortholinear NeoKey keeb panel – Adafruit Blog.
OV2640 camera breakout with oscillator, because all the modules we found require a 24 MHz clock input and are not very breadboard friendly – Twitter.
A sneak peek of analog inputs working in AdafruitIO Wippersnapper, the no-code interface for AdafruitIO – Adafruit Blog.
New Boards Supported by CircuitPython
The number of supported microcontrollers and Single Board Computers (SBC) grows every week. This section outlines which boards have been included in CircuitPython or added to CircuitPython.org.
This week we had 2 new boards added!
Looking to add a new board to CircuitPython? It’s highly encouraged! Adafruit has four guides to help you do so:
- How to Add a New Board to CircuitPython
- How to add a New Board to the circuitpython.org website
- Adding a Single Board Computer to PlatformDetect for Blinka
- Adding a Single Board Computer to Blinka
New Learn Guides!
Updated Learn Guides!
CircuitPython Project Bundle
When you get to the CircuitPython code section of an Adafruit Learn Guide, sometimes things can get a bit complicated. You not only have the code you need to upload to your device, but you likely also need to add some libraries that the code requires to run. This involved downloading all the libraries, digging through to find the ones you need, and copying them to your device. That was only the beginning on some projects, as those that include images and/or sound files required further downloading and copying of files. But, not anymore!
Now, with Project Bundles, you can download all the necessary code, libraries and, if needed, asset files with one click! We automatically check which libraries are required for the project and bundle them up for you. No more digging through a huge list of libraries to find the ones you need, or fiddling with looking for other files or dependencies. Download the Project Bundle, copy the contents to your device, and your code will simply work. We wanted to make this the easiest way to get a project working, regardless of whether you’re a beginner or an expert. We’ll also be adding this feature to popular IDEs as an add-on. Try it out with any CircuitPython guide on the Adafruit Learning System. Just look for the ‘Download Project Bundle’ button on the code page.
To download and use a Project Bundle:
In the Learning System – above any embedded code in a guide in the Adafruit Learn System, you’ll find a Download Project Bundle button.
Click the button to download the Project Bundle zip.
Open the Project Bundle zip to find the example code, all necessary libraries, and, if available, any images, sounds, etc.
Simply copy all the files over to your CIRCUITPY drive, and you’re ready to go!
If you run into any problems or bugs, or would like to submit feedback, please file an issue on the Adafruit Learning System Guides GitHub repo.
CircuitPython support for hardware continues to grow. We are adding support for new sensors and breakouts all the time, as well as improving on the drivers we already have. As we add more libraries and update current ones, you can keep up with all the changes right here!
If you’d like to contribute, CircuitPython libraries are a great place to start. Have an idea for a new driver? File an issue on CircuitPython! Have you written a library you’d like to make available? Submit it to the CircuitPython Community Bundle. Interested in helping with current libraries? Check out the CircuitPython.org Contributing page. We’ve included open pull requests and issues from the libraries, and details about repo-level issues that need to be addressed. We have a guide on contributing to CircuitPython with Git and Github if you need help getting started. You can also find us in the #circuitpython channel on the Adafruit Discord.
You can check out this list of all the Adafruit CircuitPython libraries and drivers available.
The current number of CircuitPython libraries is 312!
Here’s this week’s updated CircuitPython libraries:
What’s the team up to this week?
What is the team up to this week? Let’s check in!
I’m continuing to work on dynamic USB descriptors. I’ve written a lot of the code, and am finishing up, doing HID devices. I hope that this capability will be compact enough that it can fit even on our smallest boards.
I’ve been working on CircuitPython support for “parallel capture” cameras, starting with the OV7670. This inexpensive camera can be purchased from the usual website that sells everything, and modified to plug in to a Grand Central. Based on code written by Phil B, I’ve created a core driver for “parallel capture” on the SAM D51 microcontrollers including the Grand Central, as well as a Python library to initialize the OV7670 camera.
This week I published the QT Py RP2040 and the Neo Trinkey guides, updated the SHT31-D and HTU21-F breakout guides for the STEMMA QT revisions, and helped with the Adafruit FunHouse guide. I also uploaded a number of PCB files to GitHub based on request.
I updated the script that circuitpython.org uses to generate the /contributing page as well. There had been updates to the script, but they had not been applied to the rendered pages yet. This means the information available on that page is more up to date now.
I wrote a README to include in the new Adafruit Learn System Project Bundles that explains how the bundle works, what to do with it, and includes a link to where it was downloaded from and the date it was downloaded.
I finally have examples of templates! The Neo Trinkey guide includes the NeoPixel Blink template. It looks on this end like a normal guide page. But on the editor end, most of the page is immutable, and the author adds the image and the code. That means a lot less work in the future, but more importantly, provides a much more consistent experience across guides!
This past week I’ve been working on the RP2040 alarm system, starting with TimeAlarm, which makes use of the RTC to wake from light/deep sleep. Since the RP2040 currently uses the Timer peripheral for internal timekeeping, the RTC hasn’t seen a lot of buildout, so I’ve been filling it out with some of the utility code in the STM32 port. The Raspberry Pi official libraries for sleep are still very much in the alpha stages, and I’ve mostly been working from the reference manual and trying different things out by hand to explore what isn’t laid out in prior work.
I’ve also been working on finalizing the NRF52 and STM32 ports of Alarm, fixing various formatting issues and bugs that have been holding them back from being merged, so we can hopefully start getting everything back on the same track soon.
This past week, I wrote the FunHouse product guide. In order to avoid needing to rewrite many copies of similar pages, I learn how to use a new feature of the learn guides called Template pages. These are basically regular guide pages with small sections to add sections in the middle of the page. The guide took a little longer to write than the typical product guide, but it should make writing guides in the future much easier. You can check out the FunHouse guide.
Another thing I did is I added a couple of different versions of the WiFi module to the PortalBase library. The different versions reflect the ESP32-S2 and AirLift WiFi coprocessor that are common on many of our boards. This will make adding similar boards even easier in the future as well as making maintenance of the WiFi modules much easier. I have already updated the FunHouse and MagTag libraries to make use of the changes and will update the PyPortal and MatrixPortal libraries soon.
Since we’re at the start of 7.x work, I’ve begun merging in changes from upstream MicroPython. My brain is completely swamped with that work so I can’t think about much else. My approach is to merge in each release from MicroPython. So, we’re starting with ~1.9.4 and MicroPython just released 1.15. So, we’ve got 1.10, 1.11, 1.12, 1.13, 1.14 and 1.15 to merge in. I’m nearly done with 1.10 and have started with the 1.11 merge. I’m hoping the later versions will be easier merges because MicroPython has started releasing more frequently (and therefore fewer changes.)
PyCon US, the annual official annual Python gathering, has been announced to be held online May 12-15, 2021. Sprints will be held May 16-18, 2021. More information and signups at https://us.pycon.org/2021/
EuroPython, the largest conference for the Python programming language in Europe, has been announced to be held online July 26 – August 1, 2021. More information at https://ep2021.europython.eu/
Send Your Events In
As for other events, with the COVID pandemic, most in-person events are postponed or cancelled. If you know of virtual events or events that may occur in the future, please let us know on Discord or on Twitter with hashtag #CircuitPython.
20210426 is the latest CircuitPython library bundle.
Call for help – Translating CircuitPython is now easier than ever!
One important feature of CircuitPython is translated control and error messages.
With the help of fellow open source project Weblate, we’re making it even easier to add or improve translations.
Sign in with an existing account such as GitHub, Google or Facebook and start contributing through a simple web interface. No forks or pull requests needed!
As always, if you run into trouble join us on Discord, we’re here to help.
jobs.adafruit.com – Find a dream job, find great candidates!
jobs.adafruit.com has returned and folks are posting their skills (including CircuitPython) and companies are looking for talented makers to join their companies – from Digi-Key, to Hackaday, Micro Center, Raspberry Pi and more.
The Adafruit Discord community, where we do all our CircuitPython development in the open, reached over 28,766 humans, thank you! Adafruit believes Discord offers a unique way for CircuitPython folks to connect. Join today at https://adafru.it/discord.
ICYMI – In case you missed it
The wonderful world of Python on hardware! This is our Python video-newsletter-podcast! The news comes from the Python community, Discord, Adafruit communities and more and is reviewed on ASK an ENGINEER Wednesdays. The complete Python on Hardware weekly videocast playlist is here.
Weekly community chat on Adafruit Discord server CircuitPython channel – Audio / Podcast edition – Audio from the Discord chat space for CircuitPython, meetings are usually Mondays at 2pm ET, this is the audio version on iTunes, Pocket Casts, Spotify, and XML feed.
And lastly, we are working up a one-spot destination for all things podcast-able here – podcasts.adafruit.com
The CircuitPython Weekly Newsletter is a CircuitPython community-run newsletter emailed every Tuesday. The complete archives are here. It highlights the latest CircuitPython related news from around the web including Python and MicroPython developments. To contribute, edit next week’s draft on GitHub and submit a pull request with the changes. You may also tag your information on Twitter with #CircuitPython.