-
UF2 Library and a RP2040 Python Disassembler
02/01/2021 at 23:41 • 0 commentsPreparing for the stream tomorrow, I created a small JavaScript library to read the UF2 file format. I'm still not sure if we'll use it or continue with the .hex files, but it was fun creating it nevertheless!
The source code is available here: https://github.com/wokwi/uf2 (it has a nice unit-test suite),
and it has also been published as an NPM package: https://www.npmjs.com/package/uf2.Meanwhile, some random programmer who watched the stream started working on a RP2040 disassembler in Python: https://github.com/pyTony/rp2040
Nice work Tony! Thank you for sharing it with us :-)
-
Let there be Serial: Hacking UART
01/31/2021 at 23:49 • 0 commentsHacking the Pico simulator on a live stream was a bit intense, but also a lot of fun!
So I decided to try turning it into a weekly thing. The next stream will be on Tuesday, 2PM EST (just like the last time):
I'll keep posting the updates here, but if you prefer to get them in your email, you can sign-up here:
https://pages.wokwi.com/rp2040
See you on Tuesday!
-
6 Instructions and a Blink
01/26/2021 at 22:12 • 2 commentsIn the first live stream we implemented 6 instructions: B, BL, LSLS, MOVS, PUSH, STR - just the bare minimum to run the main loop of the blink example.
Eventually, we got it running in the simulation, and also wrote unit tests for most of these instructions.
You can find the code in the project's repo: https://github.com/wokwi/rp2040js
Now, it's your turn: I'd love to get your feedback about the format, and learn if you want me to do more live-streaming sessions showing how I gradually evolve this project into a usable, general-purpose Raspberry Pi Pico emulator.
-
Building the Bootrom
01/26/2021 at 13:45 • 0 commentsAfter digging a bit into the RP2040 datasheet, it seems like we might also need to take a look at the bootrom. Fortunately, the full source code is available on GitHub.
There's no documentation how to build it, but it turns out it's pretty straightforward. Here are the complete instructions for building the RP2040 bootrom from source:
- Install dependencies:
sudo apt install cmake gcc-arm-none-eabi
Checkout the repository:
git clone https://github.com/raspberrypi/pico-bootrom
Build it!
cd pico-bootrom git submodule update --init mkdir build cd build cmake .. make -j4
Enjoy :-)
- Install dependencies:
-
First live-stream
01/25/2021 at 18:54 • 0 commentsFor the first live-stream tomorrow, we'll use the following documents:
- Getting started with Raspberry Pi Pico guide (mostly for SDK installation instructions)
- RP2040 Datasheet
- ARM® v6-M Architecture Reference Manual
You can find a copy of all the three documents in the Files section of the project page.
We'll also use the Pico SDK and Pico Examples repo.
To save time, I have already set them up on my machine, so we can get straight to planning/coding (without having to wait for the 1.2GB gcc-arm-none-eabi package to download).
See you tomorrow!