Where I begin to develop applications for the RP2040 (Pi Pico and Pi Pico W) using Micropython.
In Getting Started, we created simple programs and used paste mode to enter the programs into the Pico storage. This works well for short programs and particularly well, for debugging. It will continue to be a valuable technique. That said, paste mode becomes cumbersome for developing longer programs and programs with multiple files. For this we want to be able to quickly upload a file or set of files, preferably remaining in our code editor.
Updated: Where I describe the different options for using a serial monitor and the serial software in AVR_C and change my recommended programs.
CoolTerm appears to be malware on some systems and PuTTY, its important to install from the proper site, has better security. PLEASE ENSURE YOU DOWNLOAD IT FROM THIS SITE ONLY: https://freeware.the-meiers.org/
For macOS, I do likeSerial, however, this is a $40 serial program. For free, the solutions is tio, which can be easily installed using Homebrew or CoolTerm.
Where I describe how to use the GNU Linker wrapper capability and variable arguments to enhance printf()
for better debugging.
This recent post fascinated me. It describes a feature of the GNU linker called wrapping which allows you to replace an existing symbol (command) with a new version. The example describes adding a timestamp to printf()
. While, for me, this might be a solution looking for a problem, I really liked the idea. And at the very least wanted to add the concept to AVR_C.
Where I describe various methods of debugging programs using MicroPython on the RP2040 (Pi Pico and Pi Pico W).
Programming is a science, debugging is an art. When I chat with students learning to program, I’ve found it isn’t “programming” which causes the most problems, its “what to do when the programming doesn’t work.”
On any new microcontroller, there is a new tool chain and a new process, which affects how you debug. For example, with the AVR family of microcontrollers, you have gdb, bloom as a hardware debugger (which is fantastic!), make and gcc. Or you may use the Arduino framework. Both approaches are well-defined, well-understood and work well.
Where I begin to develop a web server for the RP2040 (Pi Pico and Pi Pico W) using MicroPython and microdot.
The Pico W added wireless capability to the Pico, which brings the ability to network the Pico board. Once a board can be networked, it becomes valuable to have it serve web pages. An HTTP-compliant web page is a simple first step to using the Pico W via a network.
A set of entries which comprise a course for learning how develop MicroPython programs for the RP2040.
An updated look at the utility, mpremote, used to communicate with a board running MicroPython.
A tool which has improved a great deal with the 1.20 release is mpremote - micropython remote control. After using it extensively, I’ve found its biggest issue is the lack of documentation as compared to its capabilities. It is invaluable, if not mandatory for interacting with a MicroPython board.
# to install
pip install mpremote
# to upgrade
pip install --upgrade mpremote
Once installed, use the help command to see the available commands. Make sure CoolTerm is not connected, otherwise you won’t be able to connect to the board via mpremote.
Where I illustrate how to establish a wireless connection using the Pi Pico W.
When the Pico W was introduced, there was finally a great product from Raspberry Pi to compete with the ESP32. The ESP32-based products are good, however, I prefer the Pi Pico-based products due to superior support and documentation due to its ARM Cortex-based architecture. The Pico W added wireless capability to the Pico, which brought the ability to network the Pico board. It also added bluetooth, which will be a different tutorial.
Where I demonstrate how to begin to program the RP2040 (Pi Pico and Pi Pico W) using Micropython.
I already have quite a few entries on Micropython. While I’ve experimented with multiple boards using the language, ESP32, FIDI, and the Adafruit Feather RP2040, this entry begins a set of entries on using Micropython as a development language with the Pi Pico W as the development microcontroller. The cost ($6) of the Pico W, with it’s computing power and wireless capability coupled with the ease of development of Micropython, makes this combination compelling.
Where I describe how I develop Forth on my Mac using Sublime Text 3 and Serial, as my Forth IDE.
Make the change in: mecrisp-stellaris-x.y.z/mecrisp-stellaris-source/rp2040-ra/terminal.s lines 165-166 and added the comment below the lines, replacing the comment line 168: