Emulating the OSWALD

This section describes how to use qemu to emulate the OSWALD.

Check out the source code

First, you'll need to checkout the source code. You can do so by running the following command:

git clone git://code.oregonstate.edu/oswald-qemu

Building qemu with OSWALD emulation support

Next we want to build qemu with ARM emulation support. First enter the source code directory that we just checked out:

cd oswald-qemu

Next, run the configure script with ARM support enabled:

./configure --target-list=arm-softmmu --disable-werror

Note that we're only building qemu with ARM system emulation support. Use additional configuration options if you want to enable other features or types of system emulation.

Finally, build qemu:

make

If qemu built successfully, you should have an arm system emulator in the arm-softmmu directory that can be used to emulate the OSWALD. To confirm this you can run the following commands:

cd arm-softmmu
./qemu-system-arm -M help

The final command should output a list of supported ARM system emulation targets and the OSWALD should be included.

Running the OSWALD qemu emulator

If you were able to build qemu successfully, then the next step is to get OSWALD emulation running. For now, the easiest way to do this is to generate a bootable SD card image and then use the dd command to create an image file of the card that can be booted with the emulator. For example, the emulator can be run with the following:

./qemu-system-arm -M oswald -sd /path/to/SD/image/file -serial stdio

which will pipe the serial output to the current console and use an SD card image to boot from.

If you just want to view serial output with no graphical window use the following command:

./qemu-system-arm -M oswald -sd /path/to/SD/image/file -nographic

Note that you'll have to use terminal commands to interact with the emulator. Use Ctrl-a-h or Ctrl-a-? to view the available bindings.