ICYMI (In case you missed it) – Yesterday’s Python on Microcontrollers Newsletter from AdafruitDaily.com went out.
If you missed it, subscribe now! – You’ll get one terrific newsletter each Tuesday (before this post). Over 7,940+ 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.
Hi everyone! It’s the latest Python for 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. Time to dive in:
Summer of Making
GitHub is working with Hack Club students sponsor the Summer of Making. $50,000 in hardware will be given to teenage makers around the world. If you’re a teenager, tell them what you want to build this summer to get some electronics to support you! Need inspiration? Check out what hackers like @LambdAurora and Prithul are building – More Information.
CircuitPython Day Announced for September 9, 2020
Adafruit has chosen September 9, 2020 (9/9/2020) as the snakiest day of this year for CircuitPython Day! Much more to come on events and happenings to include a CircuitPython team livestream, collaboration with hardware and software folks, and highlighting all things Python and Python on Hardware. More information will be forthcoming. Ideas? Send them via email to firstname.lastname@example.org.
A Wireless and USB-C Keyboard Powered by CircuitPython
Makerdiary has developed a mechanical keyboard using the nRF52840 microcontroller to provide connectivity through USB-C and BLE 5.0 Bluetooth. And the keyboard runs CircuitPython, so it’s fully customizable (just drop a new file onto the flash drive the board presents) – Makerdiary and GitHub.
The Adafruit Discord Server Surpasses 22,000 members
The Adafruit Discord community, where we do all our CircuitPython development in the open, reached over 22,000 humans in the last week! Thank you! Adafruit believes Discord offers a unique way for CircuitPython folks to connect. Join today at https://adafru.it/discord.
…and the Microsoft Python Discord Server is Offering Swag
Microsoft has a Discord server for talking Python with Microsoft tools and technologies, such as Python VS Code. They are offering cloud labs there where you can get swag!
Nominations Open for Python Software Foundation Community Service Awards
The Python Software Foundation is accepting nominations for their second quarter Community Service Awards. Information and previous winners can be found here. Proposals should be made confidentially to the Board by sending email to email@example.com – Twitter
Build a Custom Animated LED Sign Assembly
Melissa demonstrates Part 1 of her Python-Powered Custom Animated LED Sign Series, covering the assembly of the sign and everything you need to do to 3D print and build the hardware – YouTube.
TalkPython Podcast: Device Simulator Express
No IoT hardware things in hand? Simulate them with Device Simulator Express!
Maybe you’ve heard of the Circuit Playground Express, BBC micro:bit, or the fancy Adafruit CLUE. They aren’t too expensive (ranging from $15 to $50 each). But for large groups such as classrooms, this can be a lot of money. Moreover, getting your hands on these devices can sometimes be tricky as well. With an extension for VS Code called Device Simulator Express, you can have instant access to all three (virtually of course). This cool extension adds a visual emulator as well as the native interactions such as buttons and temperature sensors.
Read more – TalkPython.
Serpano, a CircuitPython Development Board for Breadboards
Serpano is a CircuitPython dev board designed for breadboards. It delivers 3.3V @ 2A and 5V @ 2A, an adjustable 1.8-12V @ 3A, current measurement, and a Feather-ish pinout. It can be powered from USB, a 4.5-12V DC jack, or a LiPo battery. Also includes a 1.3” 240×240 LCD for data visualization – Twitter.
CircuitPython Deep Dive Stream with Scott Shawcroft
This week, Scott streams his Seeed Studio Wio Terminal unboxing, ESP32SPI networking API changes and optimizing json.load.
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!
A foot pedal to start/stop audio for transcription. A sewing machine pedal and one resistor are connected to a Seeeduino XIAO board running Adafruit CircuitPython 5.3.0 (12 lines of code!). The pedal acts as a variable resistor to measure voltage using an analog pin – Twitter and GitHub.
Darts: Time Series Made Easy in Python – Medium.
A goodbye party held for Python 2: was it just cake all along? – Tim Gremalm.
8 World-Class Software Companies That Use Python – Real Python.
Texthero is a Python toolkit to work with text-based dataset quickly and effortlessly. Texthero is very simple to learn and designed to be used on top of Pandas – GitHub.
BlurDetection2 – Blur Detection with OpenCV in Python – GitHub
PyDev of the week: Dr. David Pena on Mouse vs Python
The Mu Python Editor
Why Mu? Mu tries to make it as easy as possible to get started with programming but aims to help you graduate to “real” development tools soon after. Everything in Mu is the “real thing” but presented in as simple and obvious way possible. It’s like the toddling stage in learning to walk: you’re finding your feet and once you’re confident, you should move on and explore! Put simply, Mu aims to foster autonomy. Try out Mu today! – codewith.mu
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 do not have any new boards added to circuitpython.org but several are being worked on.
Looking for adding 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 262!
We updated nearly all our libraries this week! Most of it was a simple change to the README. For a list of this week’s updated libraries, check out the CircuitPython Library Report.
PyPI Download Stats!
We’ve written a special library called Adafruit Blinka that makes it possible to use CircuitPython Libraries on Raspberry Pi and other compatible single-board computers. Adafruit Blinka and all the CircuitPython libraries have been deployed to PyPI for super simple installation on Linux! Here are the top 10 CircuitPython libraries downloaded from PyPI in the last week, including the total downloads for those libraries:
Keep checking back for updated download stats coming soon!
What’s the team up to this week?
What is the team up to this week? Let’s check in!
The main focus of my work over the last week has been the AS7341 11-Channel Multi-Spectral light sensor from AMS. This is a pretty neat sensor that holds a lot of capabilities in a small package. Within the 3x2mm footprint are 16 paired CMOS light sensors for separate light wavelength bands as well as two dedicated sensors with no/clear filter, one near-infrared, and one flicker detection sensor.
This impressive collection of sensors is routed through a 16-bit 6-channel ADC that takes the raw measurements from the sensors and converts them to digital values that can be read out over I2C. 12 readable individual sensor elements don’t exactly fit through a 6-channel ADC together so the chip includes a so-called Super MUX (SMUX) that allows you to route the signal from any sensor to any ADC channel. Now that’s some super multiplexing!
The sensor also includes interrupts for measurement thresholds, flicker detection and housekeeping stuff like FIFO overflows. One feature I find particularly interesting is the LDR pin that allows you to control an external LED to aid in spectral measurement. Current control allows you to use the LED to its full capacity without burning it out with too much current.
I’m continuing to work on an implementation of _bleio that supports the HCI (Host Controller Interface) Bluetooth adapter protocol. HCI is a serial protocol available on ESP32, used on our AirLift boards. In order to talk the HCI protocol to the adapter, I started with the HCI communications code in the ArduinoBLE library. But ArduinoBLE uses only a limited set of HCI commands, so I switched to using a complete set of HCI command definitions provided by some include files in Zephyr. I redid the ArduinoBLE HCI code completely, and again got to the point I was at last week, where I was able to ask the adapter for its BLE address. So it’s one step back and one step forward again, but this time wearing boots instead of flip-flops.
Now I’m implementing more of _bleio, starting with advertising, and hope to have more things working in a few days.
In the CircuitPython core, there are lots of things going on behind the scenes. We use background tasks to ensure that things like audio, USB, and display keep working even while your code.py is running. My current project is to enhance this code and restore performance that we gave up temporarily in order to add the “lower power” mode that is helpful for battery-powered projects.
This week, I published the 74HC595 shift register guide. This little chip is rather complicated to wire up, and previous to this, there was only an Arduino guide explaining what to do with it. There has been a CircuitPython library for it for quite some time, but no guide to using that either. So I wrote up this guide which includes pinout details and a clear wiring diagram, as well as a CircuitPython example code to control 8 LEDs using SPI. The example displays a chase animation and then blinks the LEDs.
Along with the guide, there was a bit of miscellaneous. I updated a couple of Fritzing objects, created a couple new Fritzing objects, tested and merged a couple of PRs and tended to some assigned GitHub issues.
Finally, I assisted with the translation of the first guide I ever wrote, Circuit Playground Express: Piano in the Key of Lime into Spanish. A huge thank you to Àlvaro for all of his amazing work translating guides. The next guide up for translation is the Circuit Playground Express guide.
This past week was partially consumed by my move into a new apartment in Boston. However, outside of packing boxes and hooking up internet, I’ve been doing more work on my Timer Allocator. This has included rewriting RGBMatrix to use the new system, updating the internal peripheral profiles of various chips to expose more timers, and other related bugfixes. In the process, I’ve uncovered some regressions with PulseIO which have snuck into the main branch, which I’m currently investigating. Sneaky regressions are always a frustrating find, and this most recent discovery has encouraged me to revisit some old tooling solutions for hardware-based regression testing that I benched this spring.
This week I worked some more on the Blinka PyPortal library and wrote a guide for it. Along the way, I found several bugs for it, with some of them occasionally stopping me from continuing on the guide without addressing the bugs. Eventually though, I was able to get everything working. I was able to get it running on both a Raspberry Pi 4 and the FT232H so that it could be run directly from my computer.
You can check out the guide on the Adafruit Learning System.
This week I’m focused on our WiFi and networking APIs in CircuitPython. I’ve settled on what modifications I want to make and now I’ve gotta do them. The gist is that I want our APIs to be better segmented to save memory when you aren’t using some of the functionality and internally use smaller chunks of memory so they work more often with memory fragmentation.
My approach is to start from the beginning, WiFi scanning, and work through the examples. Watch my Deep Dive streams for the latest information.
EuroPython 2020 this year will be an online conference from July 23-26. The schedule is now available – Website.
Attending the conference days will require a ticket, participating in the sprint days will be free – EuroPython.
PyCon AU has announced they are holding PyConline AU, an online event, from 4–6 September 2020 – pycon.org.au.
PyGotham is a New York City based, eclectic, Py-centric conference covering many topics. PyGotham TV taking place October 2-3, 2020 with a single track of talks presented online – Event Website and Call for Proposals.
PyCon India 2020: the premier conference in India on using and developing the Python programming language. Held online October 3-5, 2020. A call for proposals is now open through August 14, 2020. – Website and Twitter
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.
20200711 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.
ICYMI – In case you missed it
The wonderful world of Python on hardware! This is our first video-newsletter-podcast that we’ve started! The news comes from the Python community, Discord, Adafruit communities and more. It’s part of the weekly newsletter, then we have a segment on ASK an ENGINEER and this is the video slice from that! 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. Join our Discord or post to the forum for any further questions.