-
1Step 1
OVERVIEW
Here's a QUICK-START to loading the "blinker01" binary from dwelch67 on a Pi Zero.
(These instructions may differ slightly for other Pis)
There's a *wealth* of info in there, but you have to jump around from README to README to get that first blinky going...
(Realistically, it's probably better to start with his READMEs, to get a sense of his style so you know where to go next with "blinker02", and further... And you can learn *a lot* about Raspberry Pi, ARMs, CPUs in general, and more, in the process.)
These instructions will *not* be enough to get further than "blinker01", but they are a portion of what's necessary to load any binary, once you've compiled your own...
Again, this is a compilation of the necessary info found in dwelch67's READMEs, so ReadThems!
-
2Step 2
Gather The Files
There are THREE files you'll need:
- bootcode.bin
- start.elf
- "kernel.img"
When downloading these files from these links, DO NOT right-click->download.
Instead, DO click the filename to open a new page, then click download. Took a while to figure that one out.
bootcode.bin and start.elf are FIRMWARE files from The Official Raspberry Pi Github:
https://github.com/raspberrypi/firmware/tree/master/boot
kernel.img is your binary... Whatever *.bin you compile, or the already-compiled "blinker01.bin" file from dwelch67:
https://github.com/dwelch67/raspberrypi/tree/master/boards/pizero/blinker01
-
3Step 3
Copy The Files
Format a microSD card to FAT32.
Copy the three files to the card
Don't forget to rename your "blinker01.bin" file to "kernel.img"
(NOTE: Other Pi versions may require a different filename for kernel.img, e.g. kernel7.img, with a seven... Try that, or you'll need to check the READMEs).
-
4Step 4
Put the SD-Card in the PiZero
Do I need to explain?
-
5Step 5
Boot The Thing
Yahknow, power it up and watch it blink.
-
6Step 6
( 6 a ) Rejoice at Blinkitude!
YAY!
( 6 b ) Cry And Repeat
aka Conclusion
aka Where To Go From Here
If step 6 didn't work... cry... Then reread my instructions, here... They worked for me... This "mythical electronic creature" (the PiZero) appears not only to be a real thing that can really be acquired, much to my surprise, but appears to also function. Again, did you remember to click THEN click "download" at the new page, or did you download the filename from the links, above, e.g. by right-clicking->download (and download the file's webpage, rather than the file), like I did... twice...? Make sure you got "Blinker01.bin" from the pizero subdirectory (or whichever Pi version you have) not from the main folder. I did this with a PiZero, Your Results May Vary.
Note that there might be some mistakes in the READMEs, I swear I saw the filename was "bootloader.bin," when in fact it's "bootcode.bin". Dwelch67's "Bootloader0#" files are different. And probably a good idea... as a next step, do read those READMEs.
If you've got the tools, that's probably the route to go, after this, so you don't have to keep swapping out that SD-Card.
It's probably wise to add a pushbutton on the "Run" header, which seems to me should be called "RST" instead... And if you go the bootloader-route you'll need a few pins for Tx and Rx to a USB to 3.3V-Serial dongle. You could even use, as dwelch67 puts it, "pins you can push in rather than solder" which I hadn't seen before @David Spinden's pretty awesome #ViaConnect Circuit Board Test Tool.
The remainder of dwelch67's examples do *not* contain precompiled binaries... So the next step would definitely need to be downloading of the compilation toolchain... That's definitely beyond the scope of these instructions.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.