MicroBlocks (https://microblocks.fun) is a live, parallel, visual programming language for microcontrollers. It works on a variety of devices, including the micro:bit, Calliope, Adafruit Circuit Playground Express, NodeMCU, M5Stack and many others. It is a brand-new language written from the ground up by developers John Maloney, Bernat Romagosa and Jens Mönig, with contributions from collaborators around the globe, extensive testing by our faithful alpha testers from the Edutec group at the Citilab and elsewhere, community-provided translations for 15 languages, with advice and documentation by our team members Kathy Giori, Jen Lavalle, Tom Lauwers, Jadga Hügle and Amon Millner.
A collection of microcontrollers supported by MicroBlocks
MicroBlocks aims to make programing of physical devices simpler and more engaging by adhering to its four basic principles: liveness, autonomy, parallelism and portability.
By liveness, we mean that the environment is a real time one, a characteristic inspired in the Smalltalk programming systems that we love and miss dearly. In MicroBlocks, you can click on a block at any time and see the result instantly, or change a script while it’s running and immediately see the effect of your modification, or graph sensor values while they change.
Graphing sensor values live in MicroBlocks, in parallel with another task
We went so far into the idea of liveness that, in MicroBlocks, you can disconnect the board at any point without having to click on any upload buttons or wait for any synchronization process. The program will just keep running on the board. In fact, it always runs on the board. What you see in the screen is a representation of the program the board is running.
When you like what your program does, just unplug the board and you're good to go. Make a game, a fitness app, or light-up clothing that goes wherever you do. You don’t need to explicitly upload, compile, or even learn what that jargon means. Just unplug your board at any point, the program is already there and will stay there.
MicroBlocks is also a parallel language, meaning you can write several scripts that run at the same time. This is often cognitively easier for beginners. Instead of having to pack all the logic into a long string of blocks, they can separate their program into simpler scripts that perform single independent tasks.
Thanks to the Smalltalk-like virtual machine approach, MicroBlocks programs are also portable, which means that a program written for one microcontroller can also run in any of the other microcontrollers supported by MicroBlocks, as long as their capabilities are compatible or can be emulated. Buttons, sensors, and display blocks behave the same on all boards with the relevant hardware. MicroBlocks even simulates the micro:bit 5x5 LED matrix on TFT displays.
Taking portability to the extreme, in MicroBlocks the board acts like a memory stick. No need for files; just plug in a board and the scripts reappear in your screen. Hand your board to a friend so they can explore your code. They might even add a cool new feature!
When we started MicroBlocks there were two types of blocks-based systems for microcontrollers. Static systems let you push a program to the board and run it autonomously, but they don't support liveness. In contrast, dynamic systems like Snap4Arduino, are live but require that the board always remain tethered to the computer; they don't support autonomy.
We believe liveness is probably the most undervalued and essential feature in a programming system, especially an educational one, but when we're talking about microcontrollers, being able to disconnect the board from the computer and have the program still running is also essential. In MicroBlocks, we wanted to get the best of both worlds. We wanted to write the language for physical computing that we wished existed when we got into microcontrollers.
It's been three years since John Maloney first sent an email to Jens Mönig and myself containing an initial version of a Smalltalk-inspired virtual machine that ran in the micro:bit and the Calliope. Having had discussed the feasibility of such a project in a video call just a couple of months before, we certainly didn't expect John to finish the bulk of it so quickly. But, alas! As famous programmer Tom Cargill very neatly puts it, «The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.»
Today, the other 90% of the development time later, MicroBlocks is officially beta software, and we're very proud of how far it's gotten.
Our most sincere appreciation goes out to every person and organization that has helped us and believed in us since before the software was fully usable. This has been an amazing and exciting journey, and we can't wait to see where it takes us next!
The SAP Young Thinkers group is always looking for new ways to bring computing and digital literacy to the younger ones, so you can expect learning modules, webinars and workshops on physical computing with MicroBlocks to come your way very soon. Stay tuned
MicroBlocks is free software released under the terms of the Mozilla Public License v2. It runs natively on GNU/Linux, MacOS, Windows and Chromebook. It is also provided as a native web application for Chrome browsers that have the "experimental web features" flag enabled.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.