Jason Xu 9c5c2813a0 Update QEMU command in all README and Makefile | 2 lat temu | |
---|---|---|
.. | ||
Makefile | 5 lat temu | |
Makefile.clang | 2 lat temu | |
Makefile.gcc | 2 lat temu | |
OLVASSEL.md | 2 lat temu | |
README.md | 2 lat temu | |
gpio.h | 6 lat temu | |
kernel8.img | 4 lat temu | |
link.ld | 6 lat temu | |
main.c | 6 lat temu | |
mbox.c | 6 lat temu | |
mbox.h | 6 lat temu | |
start.S | 3 lat temu | |
uart.c | 3 lat temu | |
uart.h | 6 lat temu |
This tutorial does the same as tutorial 04, but it prints the serial number on UART0. As such, it can be used easily with qemu, like
$ qemu-system-aarch64 -M raspi3b -kernel kernel8.img -serial stdio
My serial number is: 0000000000000000
Before we could use a rate divisor value, we must establish a valid clock rate for the PL011. It's done via mailboxes, with the same property channel we used earlier. Otherwise this interface is identical to the UART1 one.
We query the board's serial number and then we display it on the serial console.