No video

MicroPython + CircuitPython - Talk Python to Me Ep.325

When you think about embedded programming, does it bring low-level languages and tools to mind? Maybe Embedded C or even Assembly language? Thanks to the groundbreaking work by Damien George back in 2014 to create MicroPython, Python is one of the very solid choices for building tiny programmable devices.
On this episode, we welcome back Damien George from MicroPython along with Scott Shawcroft from CircuitPython and Adafruit. We'll talk about how these two frameworks are solving similar problems with slightly different philosophies. More importantly, they are working closely to bring MicroPython and CircuitPython more in sync.
▬▬▬▬ About the podcast ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
This video is the uncut, live recording of the Talk Python To Me podcast ( talkpython.fm ). We cover Python-focused topics every week and publish the edited and polished version in audio form. Subscribe in your podcast player of choice (100% free) at talkpython.fm/....
▬▬▬▬ Guests ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Scott on Twitter: / tannewt
Damien's Site: dpgeorge.net/
▬▬▬▬ Links and resources from the show ▬▬▬▬▬▬▬▬▬▬▬▬
CircuitPython: circuitpython....
MicroPython: micropython.org/
Upstream MicroPython Versions Merged Into CircuitPython: www.adafruitda...
Boards (MicroPython): store.micropyt...
Boards (CircuitPython): www.adafruit.com/
MicroPython Forums: forum.micropyt...
Become a sponsor to MicroPython: github.com/spo...
Adafruit Discord: adafru.it/discord
Download CircuitPython: circuitpython....
CircuitPython Source: github.com/ada...
Scott's Live Stream: • Deep Dive w/Scott: LED...
Listen this episode on Talk Python: talkpython.fm/...
Episode transcripts: talkpython.fm/...
▬▬▬▬ Dive deeper ▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Listen to the Talk Python To Me podcast at talkpython.fm Over 250 hours of Python courses at training.talkp... Follow us on on Mastodon. Michael: fosstodon.org/... & Talk Python fosstodon.org/...

Пікірлер: 7

  • @JR-ze9gk
    @JR-ze9gk3 жыл бұрын

    Very interesting discussion - highlights the relationship between MicroPython and CircuitPython, as well as the distinctions between them. Kudos to Damien, Scott and Michael for making this happen!

  • @richsadowsky8580
    @richsadowsky85803 жыл бұрын

    Sadly I missed this live. I am a listener to Talk Python but this is first time I've watched the video. I saw it posted by someone during Scott's Live Chat this afternoon. I clicked to find three people I have great respect for: Damien because of MicroPython, Scott because of CircuitPython and Adafruit, and you Michael whose voice I have heard on many an afternoon walk with my dog into the forest or along the lake talking about my favorite language these days: Python. I've been programming 40 years. Recently I was one of the inventors of Jibo, the home social robot on the cover of Time Magazine Nov 27, 2017. Seeing your product as the sole image on the cover of that iconic magazine is pretty incredible. I've done some embedded programming going back to 8-bit days. I love C, C++, assembly languages, but I'm often in need of a higher level language. I've used most of the languages and I went through a node.js and Python as server side systems or utility programs for productivity or data wrangling. I am not your typical Adafruit customer. I am a serial entrepreneur and frequent CTO. Currently I am CTO of global software outsource company. I love the experience of these microcontrollers with Micro- or CircuitPython. I use both and for different reasons. Sometimes I want to very quickly explore an idea that has some number of sensors and outputs light or sound that can evoke an emotional response. For most of this, I use Adafruit boards with RP2040 (the RPi Pico's microcontroller). I have a few other mcu-based boards from Adafruit. I have a big box of displays, SPI, I2C or other protocols and associated sensors. When they can be easily plugged together using the STEMMA QT plug, or similar, those are great for the projects where I don't care about interrupts or assembly language. I use MicroPython on the RPi Pico and similar RP2040 boards when I do need assembly or some other functionality not provided by CircuitPython to keep it simple. I support keep it simple, but I have to admit I got pretty excited when I thought I heard Scott say that an advantage of coming up to date was the new support for asyncio. But then deflated when I heard the CP community did not want this feature. Count me as a CP fan that would love to see some tools for lower level access. I've asked Limor Fried, Lady Ada, in one of her many live discussions why there was no way to define a function to be called on interrupt or support inline assembly (this was a while ago so maybe these things are support in the upcoming 7.x versions). I ran into one of my first incompatibilities with M1 Mac where Mu, the recommended IDE, simply did not work with my MacBook Air 11" M1 but worked on my MacBook Pro 16" and Raspberry Pi 3s and 4's. One of the reasons I wanted to use my MacBook Air M1 is almost trivial, but the mcu industry is moving to USB-C. I have a dozen or two Thunderbolt to USB-A dongles but can't always find one. But there are USB-C style cables at every workspace I have so I can take the plug off of power block/brick/thingy and plug in a USB-C data/power combo. Lucky for me that I wasn't the first person to experience the problem and it took about 10 seconds after I posted to one of the channels in Adafruit's discord server and was informed that was a bug in .04 and I needed .05 (or something like that). Downloaded and was able to confirm fix immediately. I love active communities of fellow professionals, hobbyists, and other creative types. I don't do my mcu programming for my day job. It's part of a series of experiments to find the intersection of art and science, math and music, sound and display patterns. My significant other likes to do assorting crafting projects. So she and I teamed up to mix my science-y "art" with her crafts. Now we both get excited when she wants to stop at Michael's craft store. Way back in 1982 I did a performance on open mic at a university where I took a Commodore 64, programmed it with various classic math formulas that I was studying in my Honors Calculus class. Starting with the right data set and then generating tones or triggering samples was a fun distraction. I'm a lifelong musician. I put the C64 on a folding metal chair dead center stage. Shined a spotlight on it. Then I bowed, pressed enter and left the stage. The next 30 minutes were math-generated music. 50% of the crowd booed because I was playing Dylan songs on acoustic or The Clash songs on electric guitar or just disliked the concept. The other 50% queued up to tell me it was genius or ahead of its time. I remember saying "in the not distant future, many instruments and computers will be hooked together to produce more and more elaborate music and performance art." Somebody should have told me "you're a future inventor and CTO" so I could have relaxed about "what do I want to do?" I never really pondered that because I knew I would play music forever but most like get paid to produce products mostly with software. I get on the chat on discord or other forums and I like to talk to the makers who hang out there. They are the next generation of inventors and entrepreneurs, or at the very least, they will be joining the ranks of product development professionals. As a CTO who specializes in emerging technology, or better said, the convergence of emerging tech with emerging social needs/wants, it's my job to discover where talent will be coming from. Anyhow... Love your content Michael. Damien and Scott have made my world brighter by making very usable Python implementations for microcontrollers. I will continue to use both. As much as I love C or C++, I generally don't need to build my projects with anything but Python. As I say above, I am probably one of the exceptions to the CircuitPython community in that I would love asyncio, IRQ handling, and inline assembly to provide raw access to PIO. In my mind, that's still consistent with the "for learning" mission of CP. It's just the advanced class in learning! Lucky for me, I can use MicroPython and use Blinka module to access certain CircuitPython modules that I've come to love. Thank you for great episode.

  • @mikeckennedy

    @mikeckennedy

    3 жыл бұрын

    Hi Rich, thanks so much for all the kind words and thoughtful feedback. For people interested, here's that Time Magazine link time.com/magazine/us/5027041/november-27th-2017-vol-190-no-22-u-s/ I agree that Python is the right choice almost all the time for these projects. We did have Python powering the Mars lander/rover/heliocotor.

  • @tannewt

    @tannewt

    3 жыл бұрын

    Hi Rich, I'd love to see advanced API support in CircuitPython as well. However, it's not something I think Adafruit-funded folks should work on. If others want to add it, I'll happily review and merge it in. I suggest that interested folks join our Discord if they have questions about building CircuitPython. CircuitPython's PIO support already allows for PIO assembly using a CircuitPython assembler. The API then allows for blocking reads and writes to the PIO FIFO.

  • @richsadowsky8580

    @richsadowsky8580

    3 жыл бұрын

    @@tannewt I agree with your comments. I am checking out how to write low level code (in C/C++ and/or assembly) and bind it to the CircuitPython build for a specific circumstances. I have a number of ideas on things I'd like to be able to do and stay on the CircuitPython side of the fence like map an interrupt to a callable C/C++/assembly function. The challenge isn't the IRQ code, it's how to ensure Circuit Python is in a proper state to be interrupted. I suppose this is harder than I think because of design choices made to optimize CP for educational and hobby/professional maker culture. I used to write portions of major OSes, worked on some of the coolest development tools through the decades. I wrote glue code in the early days of Jibo to handle events coming on the foundational systems level code from devices and call a callback. I did this by instantiated a new Event Loop using low-level node.js APIs and interacting with the V8 web engine where the use case might be doable in traditional single event loop, but I studied Node's implementation and saw how to do this using a second event loop that uses some semaphore (just a change in state of a value in the notepad section of memory we used deep down in the robot to handle coordination of a lot of complex systems above it. That plus 35+ years writing code as low level or as high level as needed. I worked on some of the great compilers and the major OSes. For an old, executive type (more time in meetings than doing any technical hands on), I keep my mind and skills sharp and aware of challenges of assorted problems. Since I am CTO of a company that provides development services to clients worldwide out of three different countries where we staff development/product professionals, I often never know whether my next call will be to talk about the edge of the edge's edge, or the highest level, "no code", ML project and everything in between or even outside that spectrum. It's helpful that regardless of my primary source of income, whether as a programmer, architect, head of department, executive position, or consulting, I ALWAYS make time to program on new, emerging things/trends/realities. So I am doing my CP and RP2040 work as part of my self-directed hobby project. I often invent problems that I can't find solutions for and try to solve them, even if only just because I can.

  • @tannewt

    @tannewt

    3 жыл бұрын

    @@richsadowsky8580 We're happy to help on the Adafruit Discord server! Join #circuitpython-dev with dev questions.

Келесі