Emulating the XO: Difference between revisions

From OLPC
Jump to navigation Jump to search
(begging of a linux quick start.)
(revert FreeBSD Quick Start layout experiment. also tweaked.)
Line 47: Line 47:
=== FreeBSD Quick Start ===
=== FreeBSD Quick Start ===


Install qemu from ports:
{| cellspacing=5


cd /usr/ports/emulators/qemu && make install clean
|- valign="top"
| Install qemu from ports:
| style="background:lightgray; " | <tt>cd /usr/ports/emulators/qemu && make install clean</tt>


or as a package
|- valign="top"
| or as a package
| style="background:lightgray; " | <tt>pkg_add -r qemu</tt>


pkg_add -r qemu
|- valign="top"
| Once installed, load kqemu and aio kernel modules:
| style="background:lightgray; " | <tt>kldload kqemu<br>kldload aio</tt>


Then load kqemu and aio kernel modules:
|- valign="top"

| and launch the image you want:
kldload kqemu
| style="background:lightgray; " | <tt>qemu -hda olpc-stream-development-7-20060609_1600-ext3.img</tt>
kldload aio

and launch the image you want:

qemu -hda olpc-stream-development-7-20060609_1600-ext3.img
:Should this take the same arguments as the linux qemu invocation? Are those arguments even needed for linux? [[User:MitchellNCharity|MitchellNCharity]] 21:18, 23 May 2007 (EDT)


|}


=== Quick Start: Get image ===
=== Quick Start: Get image ===

Revision as of 01:18, 24 May 2007

This page is an inprogress overhaul of OS images for emulation.

Quick Start

Mac Quick Start

Linux Quick Start

1. Obtain qemu.

On Fedora, as root:

yum install qemu

On Debian/Ubuntu, as root:

apt-get install qemu

2. Obtain an image.

Download olpc-redhat-stream-development-ext3.img.bz2 (md5). Then,

bzcat olpc-redhat-stream-development-ext3.img.bz2 > laptop.img

3. Run qemu on the image.

qemu -soundhw es1370 -serial `tty` -hda laptop.img

4 (optional) Make qemu run faster.

If you want to use kqemu to speed up the emulation (on x86 and related cpus) then

modprobe kqemu major=0

and add the -kernel-kqemu option. See Using QEMU for Troubleshooting for tips.

We have heard multiple people say that QEMU doesn't work with these images on the debian-derived distributions. The symptom is that the kernel hangs during boot. There's a problem with bochsbios version 2.2, version 2.3 works. As a quick fix, apm=off can be added to OLPC kernel arguments. (For more info, see the discussion.)

If you have network problems through Qemu and OLPC, try this.


FreeBSD Quick Start

Install qemu from ports:

cd /usr/ports/emulators/qemu && make install clean

or as a package

pkg_add -r qemu

Then load kqemu and aio kernel modules:

kldload kqemu
kldload aio

and launch the image you want:

qemu -hda olpc-stream-development-7-20060609_1600-ext3.img
Should this take the same arguments as the linux qemu invocation? Are those arguments even needed for linux? MitchellNCharity 21:18, 23 May 2007 (EDT)


Quick Start: Get image

Developing software using emulation