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,759 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!
CircuitPython 6.2.0 Beta 4 Released!
This release, 6.2.0-beta.4, is the fifth beta release of CircuitPython 6.2.0. Notable changes since 6.2.0-beta.3 include new RP2040 fixes and features, enhancements to
bitmaptools, and turning off
usb_cdc by default (it can still be enabled in a custom build). This beta is available for download on circuitpython.org for all supported boards. As always, please try out the beta and if you find any bugs, please file an issue.
More – Adafruit Blog.
CircuitPython Badges from Open Hardware Summit 2020 Finally Arriving!
The goodie bags from Open Hardware Summit 2020 are shipping to folks who registered. Due to unforeseen circumstances, this took longer than expected. Everyone is super excited about the CircuitPython-powered badge that functions as a watch!
CircuitPython Deep Dive Stream with Scott Shawcroft
This week, Scott streams his work on flash wrap-up.
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!
Another helping of live roundtable from Digi-Key for Pi Day – PSCP.tv.
Showcasing the Contentful blog with e-ink, CircuitPython and IoT – Dev.to.
A mouse jiggler using Raspberry Pi Pico – YouTube.
A quick sensor to detect when a doorbell rings and alert you – GitHub.
cmdix is a pure Python implementation of various standard UNIX commands, like ‘ls’, ‘cp’ and ‘sleep’ – GitHub.
Papermerge is an open source document management system (DMS) primarily designed for archiving and retrieving your digital documents – GitHub.
MicroPython with Encryption (MBEDTLS) support for Raspberry Pi Pico – GitHub.
With the latest (14th March) daily build of firmware, nano-gui now works on the Pi Pico – MicroPython.org.
Using MicroPython and uploading libraries on Raspberry Pi Pico – mfitzp.com.
Custom touch screen running CircuitPython on a Pimoroni Tiny2040 – GitHub.
Atlas: Our journey from a Python monolith to a managed platform – Dropbox.tech.
Pyladies share some of their stories and what they love about their group – Twitter.
A button pusher that automates Animal Crossing tasks – Hackaday.
A Q&A with Pablo Galindo, a member of the Python steering council – TechRadar.
Off-Grid Sensor Platform using GSM – GitHub.
Using the Maker Pi Pico and a simple bit of code that uses two lists, pins and LEDs – Twitter.
Clemens Mayer’s EI.O.T is an egg-shaped, breadboard-friendly, open source ESP32-S2 development board – Hackster.io.
3/20/21 Stream from CircuitPythonista FoamyGuy (Tim) takes a look at
bitmaptools.rotozoom() and a new DialGauge widget. – YouTube.
DuckyScript interpreter written in CircuitPython – GitHub.
Luck of the Na’vi pandora flower, powered by CircuitPython – Twitter.
Adafruit Feather RP2040 review: like a Raspberry Pi Pico, only better (Russian) – Habr.com.
Step 1 of building a NeoPixel cube with Adafruit QT Py and CircuitPython complete: 3 down, 51 to go – Twitter.
pyBase for MicroPython and PyBoard – WordPress.com.
Reduced version of the schedule library for CircuitPython – PyPI.org.
Use a Raspberry Pi Pico to build your own affordable Stream Deck – Hackster.io.
Interfacing 0.96″ OLED display with ESP32 using MicroPython – How2Electronics.com.
Install CircuitPython on your Raspberry Pi Pico – YouTube.
How to get WiFi on a Raspberry Pi Pico using an Adafruit AirLift FeatherWing – Tom’s Hardware.
Playing sounds from the Raspberry Pi Pico using CircuitPython – recantha.co.uk.
Comparing the Feather RP2040 and Pico with CircuitPython – YouTube.
typed_python module provides strong runtime types to Python and a compiler that can take advantage of them – GitHub.
Audacity version 3.0.0 released – audacityteam.org.
A wireless MicroPython REPL from a Raspberry Pi 400 – RaspberryPi.org.
What would you do with the TMCM-0960-MotionPy board, and what would you need to do it? – Element14.com.
Arduino Day, a worldwide celebration of all things Arduino, is March 27th, 2021 – Arduino.cc.
PyDev of the Week: John Sheehan from Mouse vs Python
Get ready for our fastest Metro ever – the NXP iMX RT1011 microcontroller powers this board with a 500 MHz ARM Cortex M7 processor. There’s 4 MB of execute-in-place QSPI for firmware + disk storage and 128KB of SRAM in-chip! – Adafruit Blog and Twitter.
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 X 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!
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 306!
Here’s this week’s new CircuitPython libraries:
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!
My ESP32-S2 fix for a bad interaction of I2C with WiFi went into CircuitPython last week. It’s still not clear exactly why the fix works. Unfortunately the part of the ESP-IDF SDK that I would need to trace is in closed-source code, though much of the ESP-IDF is open source.
As I mentioned last week, we turned off the second CDC serial channel in CircuitPython by default due to its interference with some workflows. It is still available in a custom build. To ameliorate the problem in the future, I have written a small library, Adafruit_Board_Toolkit, that determines which of the two serial channels is the REPL channel. I’ve submitted a pull request to Mu to incorporate some code that uses the library. Using the library also means that we can identify CircuitPython boards without needing to know their USB Vendor and Product IDs (VID/PIDs). To make the library work, I had to enhance some Windows-specific code from the pyserial library that returns information about serial ports Windows. Our community member Neradoc also fixed an issue with similar code for MacOS. Together, we have submitted two pull requests to the pyserial library. The fixed code lives in the Adafruit_Board_Toolkit library for now.
Among other things, I’ve been working on some speed boosts for bitmaps with CircuitPython: In the recently-released beta (together with an updated bundle) it is now possible to read pcf-format fonts much faster, up to 10x faster for really chonky font files, thanks to
bitmaptools.readinto. Need to get data between a bitmap and some other form?
bitmaptools.arrayblit can cover your needs going IN to a bitmap, and soon you’ll be able to use a bitmap with
ulab.frombuffer to get your data back out quick.
I think this will enable some cool stuff, and I can’t wait to see what the community finds to do with it.
This week I finished up some guide work. I am still working on getting pages set up using the new template feature in Learn, and getting those templates added to existing board guides. The idea is that instead of a general set of CircuitPython Essentials pages mirrored into every board guide, each guide will have its own tailored version that covers the same concept as every other board guide, except has specific code and wiring diagrams applicable to that board. It’s going to take a lot of time, but it should make for a smoother experience for those getting started with CircuitPython and compatible boards.
I also added a fancy wiring diagram to the Feather RP2040 guide, courtesy of Bill Binko from ATMakers. The Pinouts page was already quite thorough, but having a visual can be crucial for some folks, so this was an excellent addition.
Finally, we’re still working through some CI issues across the libraries with regards to the recently enabled duplicate code check. Expect another Adabot patch soon to increase the threshold that triggers that check. Luckily, we’ve made it so CI changes do not require a release, so hopefully we don’t destroy anyone’s inbox too badly.
I’m finally honing in on some of the problems that have been affecting STM32 Deep Sleep mode, by using a Saleae logic analyzer to more accurately visualize when interrupts are occurring across the system:
Currently, while the system can enter sleep correctly, it is having difficulty performing basic system tasks after waking up – I suspect that this is due to the way the RTC retains data across resets and low power modes, and I’ve been digging into the documentation to try and find reasons why it might ignore the hard reset that is supposed to occur on chip startup. I’m also seeing various other unexpected waking events and inefficiencies that might not be STM32 specific, and thus affecting every port to varying degrees of seriousness. Unfortunately, it’s not easy to visualize when every interrupt in the system triggers, as convenient as that might be.
In other news, I’ve dug out my Meowbit to test out the PWMAudioIO module, which should allow WAV files to be played on boards that support it. I’m also keeping an eye on any additional socket issues that might need more attention going forward.
This week I finished writing the 2.13” eInk display guide. This included writing drivers for the new higher resolution Tri-Color e-Ink displays for both CircuitPython and Raspberry Pi. You can check out the new guide here.
After that, I worked on fixing up miscellaneous GitHub issues and testing Pull Requests. This included work on improving the RPLidar library in an attempt to update it to a firmware that is only available on newer devices. Since mine is stuck on older firmware, it has been a lot of guesswork, reading documentation, and mostly just making sure it still works with the existing firmware.
I’m nearly through my flash adventures. I’ve debugged getting quad spi going and am now connecting it to the CircuitPython build. I also tweaked some of the settings in the nvm.toml repository that stores data about different flash chips: https://github.com/adafruit/nvm.toml
The last piece is to read the capacity of the flash from the chip itself so we can support many different sizes. Unfortunately, the init code is out of space. So, either with help we’ll figure out how to compact the code or we’ll add code to CircuitPython to load it later. Hopefully it’ll be out for review next week and I can move onto BLE workflow.
The 2021 Open Hardware summit will be held online, Friday April 9, 2021. The summit will be livestreamed, but ticket holders will have access to additional interactive portions of the summit like meet-and-greets, workshops, and sponsor booths. Find details, including ticket and sponsorship information at 2021.oshwa.org – OSHWA.
The online GeoPython conference is focused on Python and Geo, its toolkits and applications. April 22-23, 2021 – https://2021.geopython.net/.
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.
20210321 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, Microcenter, Raspberry Pi and more.
Job of the Week
Makerspace Manager – MacInspires Makerspace – MacInspires is searching for an experienced maker and educator to manage our new location opening in Chelsea, Manhattan – Adafruit Jobs Board.
The Adafruit Discord community, where we do all our CircuitPython development in the open, reached over 28,154 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
Codecademy “Learn Hardware Programming with CircuitPython”
Codecademy, an online interactive learning platform used by more than 45 million people, has teamed up with the leading manufacturer in STEAM electronics, Adafruit Industries, to create a coding course, “Learn Hardware Programming with CircuitPython”. The course is now available in the Codecademy catalog.
Python is a highly versatile, easy to learn programming language that a wide range of people, from visual effects artists in Hollywood to mission control at NASA, use to quickly solve problems. But you don’t need to be a rocket scientist to accomplish amazing things with it. This new course introduces programmers to Python by way of a microcontroller — CircuitPython — which is a Python-based programming language optimized for use on hardware.
CircuitPython’s hardware-ready design makes it easier than ever to program a variety of single-board computers, and this course gets you from no experience to working prototype faster than ever before. Codecademy’s interactive learning environment, combined with Adafruit’s highly rated Circuit Playground Express, present aspiring hardware hackers with a never-before-seen opportunity to learn hardware programming seamlessly online.
Whether for those who are new to programming, or for those who want to expand their skill set to include physical computing, this course will have students getting familiar with Python and creating incredible projects along the way. By the end, students will have built their own bike lights, drum machine, and even a moisture detector that can tell when it’s time to water a plant.
Codecademy has helped more than 45 million people around the world upgrade their careers with technology skills. The company’s online interactive learning platform is widely recognized for providing an accessible, flexible, and engaging experience for beginners and experienced programmers alike. Codecademy has raised a total of $43 million from investors including Union Square Ventures, Kleiner Perkins, Index Ventures, Thrive Capital, Naspers, Yuri Milner and Richard Branson, most recently raising its $30 million Series C in July 2016.
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.