Emulating the XO/Help and tips: Difference between revisions
No edit summary |
m (Reverted edits by 123.99.228.14 (123.99.228.14); changed back to last version by 24.13.53.221) |
||
Line 9: | Line 9: | ||
See [http://www.h7.dion.ne.jp/~qemu-win/ Qemu on Windows] and [http://fabrice.bellard.free.fr/qemu/download.html QEMU Home Page] |
See [http://www.h7.dion.ne.jp/~qemu-win/ Qemu on Windows] and [http://fabrice.bellard.free.fr/qemu/download.html QEMU Home Page] |
||
Does the version of the QEMU support KQEMU? Type ctrl |
Does the version of the QEMU support KQEMU? Type ctrl+alt+2 and type '''info kqemu'''. Use ctrl+alt+1 to return to OLPC screen. |
||
== Configuring X == |
== Configuring X == |
||
Line 28: | Line 28: | ||
<tt> |
<tt> |
||
{|align=center border="1" style="text-align: center;" |
{|align=center border="1" style="text-align: center;" |
||
| |
|+VGA kernel color / resolution table |
||
!Colors!!640x480!!800x600!!1024x768!!1280x1024 |
!Colors!!640x480!!800x600!!1024x768!!1280x1024 |
||
|- |
|- |
||
Line 56: | Line 56: | ||
A typical case is that their keyboard and mouse don't work. A solution to the problem is: |
A typical case is that their keyboard and mouse don't work. A solution to the problem is: |
||
#Make sure the the window has the focus (label should say <tt>QEMU - Press Ctrl-Alt to exit grab</tt>). |
#Make sure the the window has the focus (label should say <tt>QEMU - Press Ctrl-Alt to exit grab</tt>). |
||
#Press <tt>Alt |
#Press <tt>Alt + Ctrl + 1</tt> (or <tt>Alt + Ctrl + 3</tt>) to enter the terminal mode of the OLPC. Notice that QEMu seems to respond better to by pushing first down Ctrl, after Alt and finally the number. |
||
#Make sure that you're logged in. |
#Make sure that you're logged in. |
||
#*If not, just hit <tt>enter</tt> and it'll ask you to. |
#*If not, just hit <tt>enter</tt> and it'll ask you to. |
||
Line 62: | Line 62: | ||
#Type <tt>modprobe i8042</tt> (oddly, you may need to try this multiple times before it works, so ''keep trying!'') |
#Type <tt>modprobe i8042</tt> (oddly, you may need to try this multiple times before it works, so ''keep trying!'') |
||
[[Image:Tty1_ps.PNG]] |
[[Image:Tty1_ps.PNG]] |
||
#Press <tt>Alt |
#Press <tt>Alt + Ctrl + 7</tt> to return to the graphical mode of the OLPC. |
||
#Your keyboard and mouse should be working fine. |
#Your keyboard and mouse should be working fine. |
||
#*Usually the result is a continuous series of 1's will flow (as if the key is stuck) |
#*Usually the result is a continuous series of 1's will flow (as if the key is stuck) |
||
Line 116: | Line 116: | ||
If it does not work see the sendkey method of Alternative #3 |
If it does not work see the sendkey method of Alternative #3 |
||
# |
# |
||
#Press <tt>Alt |
#Press <tt>Alt + Ctrl + F1</tt> to enter the terminal mode of the OLPC. |
||
#Make sure that you're logged in. |
#Make sure that you're logged in. |
||
#*If not, just hit <tt>enter</tt> and it'll ask you to. |
#*If not, just hit <tt>enter</tt> and it'll ask you to. |
||
#*Login as <tt>root</tt> (no password is required) |
#*Login as <tt>root</tt> (no password is required) |
||
#Type <tt>dhclient</tt> and press return. |
#Type <tt>dhclient</tt> and press return. |
||
#Press <tt>Alt |
#Press <tt>Alt + Ctrl + F7</tt> to return to the graphical mode of the OLPC. |
||
#Your browser / network connection should be working fine. |
#Your browser / network connection should be working fine. |
||
Line 133: | Line 133: | ||
[[Image:Empty_no_apps_no_frame.png|300px]] |
[[Image:Empty_no_apps_no_frame.png|300px]] |
||
Make sure your mouse is active in QEmu, then press ctrl |
Make sure your mouse is active in QEmu, then press ctrl+alt+2 together. |
||
This will bring up a screen like a command line, called the QEmu monitor. |
This will bring up a screen like a command line, called the QEmu monitor. |
||
Line 143: | Line 143: | ||
And press return. |
And press return. |
||
Then with the keyboard hold down the following keys: '''ctrl |
Then with the keyboard hold down the following keys: '''ctrl+alt+7''' |
||
Another text based screen will appear, asking you to log-in. Sometimes there can be an extra "1" after the word "Login:", just delete it. Type '''root''' and press return |
Another text based screen will appear, asking you to log-in. Sometimes there can be an extra "1" after the word "Login:", just delete it. Type '''root''' and press return |
||
Line 161: | Line 161: | ||
Some of the numbers have been removed from the screenshot above - they're not important. |
Some of the numbers have been removed from the screenshot above - they're not important. |
||
Then hold down the following keys on the keyboard: '''ctrl |
Then hold down the following keys on the keyboard: '''ctrl+alt+2''' |
||
and type the following: |
and type the following: |
||
Line 167: | Line 167: | ||
sendkey ctrl-alt-f7 |
sendkey ctrl-alt-f7 |
||
Then using the keyboard, hold down the following keys: '''ctrl |
Then using the keyboard, hold down the following keys: '''ctrl+alt+1''' |
||
Now open the browser and you should have internet access. |
Now open the browser and you should have internet access. |
Revision as of 20:23, 11 April 2007
More often than not, technology manages to get us 95% of the way... being the last 5% a mix of magical incantations, rituals and other esoteric activities only clear to the initiated. This page tries to take some of the magic away from the sufficiently advanced science
If you want to use nano for system file edits, make sure line wrap is disabled by Alt-L (or look here for it's documentation).
My emulator is very slow
Are you using the kqemu or qvm accelerator modules? You do have to have administrator rights to install the services. QEMU manager (in Windows) knows to start these services according to your profile settings. See Qemu on Windows and QEMU Home Page
Does the version of the QEMU support KQEMU? Type ctrl+alt+2 and type info kqemu. Use ctrl+alt+1 to return to OLPC screen.
Configuring X
- In some builds X is configured to load the Geode driver by default. You need to modify it to load the frame buffer driver instead. In /etc/X11/xorg.conf, go to the "Device" section and change the Driver setting from "amd" to "fbdev"
- You can then change XKbLayOut in the same file to your keyboard code with for example nano text editor by
nano /etc/X11/xorg.conf
Setting Framebuffer resolution
NOTE: If you don't set the VGA kernel parameter to 0x317 (in order to get a 1024x768 with 64k colors) you will NOT be able to view / use Etoys properly.
In order to set the framebuffer's VGA kernel parameter you must edit /boot/grub/grub.conf according to the following table:
Colors | 640x480 | 800x600 | 1024x768 | 1280x1024 |
---|---|---|---|---|
256 | 0x301 | 0x303 | 0x305 | 0x307 |
32k | 0x310 | 0x313 | 0x316 | 0x319 |
64k | 0x311 | 0x314 | 0x317 | 0x31A |
16M | 0x312 | 0x315 | 0x318 | 0x31B |
Sound
Latest images add support of sound. Emulation does not work properly with Tam-Tam, yet, even with kqemu at 2 GHz Pentium4 (performance or insufficient emulation issue?). Maybe somebody could install Csound in host and pipe sound over the virtual network? Windows version can be found in Cecilia and Csound for Windows installer --Tonyv
Keyboard and Mouse
A typical case is that their keyboard and mouse don't work. A solution to the problem is:
- Make sure the the window has the focus (label should say QEMU - Press Ctrl-Alt to exit grab).
- Press Alt + Ctrl + 1 (or Alt + Ctrl + 3) to enter the terminal mode of the OLPC. Notice that QEMu seems to respond better to by pushing first down Ctrl, after Alt and finally the number.
- Make sure that you're logged in.
- If not, just hit enter and it'll ask you to.
- Login as root (no password is required)
- Type modprobe i8042 (oddly, you may need to try this multiple times before it works, so keep trying!)
- Press Alt + Ctrl + 7 to return to the graphical mode of the OLPC.
- Your keyboard and mouse should be working fine.
- Usually the result is a continuous series of 1's will flow (as if the key is stuck)
- Just hit any key (to stop it) and delete the offending 1's
Alternatively you can use the developers console and su command. I have not been able to bring up the terminal in most images. Quote from BTest-1_Release_Notes :
The terminal (activity) does not appear on the Frame, but can be launched by typing Alt-Shift-F11. (F11 is found in the 3rd position from the left in the Volume Slider key.) Note that on some newer builds, the terminal window (Memphis) is launched by typing Alt-Shift-F12. In even more recent builds, e.g., Build 224, Memphis is launched by typing Alt-View_Source or Alt-F12.
See also Sugar Instructions:Terminal --Tonyv 01:24, 13 January 2007 (EST)
Network
Chances are that the network will not be enabled. Following are two possible ways to enable it.
Enabling the Network Alternative #1
When the emulator is starting GRUB boot loader, press a key.
- Choose then the Qemu line with arrow keys.
- Press E
- Move to the 'Kernel' line and press End
- Add Space 1 to end of the line
- Press Enter
- Press B
You will be automaticaly log in as superuser in terminal (in single user mode).
You can start network and put your local keyboard layout command there like this (using tabulator key to complete the filenames):
echo ifup eth0 >> /etc/rc.local
or
#(change ONBOOT from "no" to "yes") nano /etc/sysconfig/network-scripts/ifcfg-eth0 #(disable NetworkManager) mv /etc/rc5.d/S98NetworkManager /etc/rc5.d/K98NetworkManager
Put your own keyboard layout for text terminals
echo loadkeys Your_two_letter_country_code >> /etc/rc.local . /etc/rc.local
Type Ctrl-D to continue normal boot.
Keyboard layout and network should work automatically every time you start the QEMU image. --Tonyv 01:52, 13 January 2007 (EST)
Enabling the Network Alternative #2
Make sure the the window has the focus (label should say QEMU - Press Ctrl-Alt to exit grab). If the following keys do not work try pushing also the Shift key down to exit the Sugar environment. If it does not work see the sendkey method of Alternative #3
- Press Alt + Ctrl + F1 to enter the terminal mode of the OLPC.
- Make sure that you're logged in.
- If not, just hit enter and it'll ask you to.
- Login as root (no password is required)
- Type dhclient and press return.
- Press Alt + Ctrl + F7 to return to the graphical mode of the OLPC.
- Your browser / network connection should be working fine.
Enabling the Network Alternative #3
The steps below work on QEmu regardless of which operating system you are running.
If you are having trouble getting an internet connection inside QEmu:
Get the image running in QEmu so that you can see the normal view with the XO icon in the middle.
Make sure your mouse is active in QEmu, then press ctrl+alt+2 together.
This will bring up a screen like a command line, called the QEmu monitor.
Type the following:
sendkey ctrl-alt-f1
And press return.
Then with the keyboard hold down the following keys: ctrl+alt+7
Another text based screen will appear, asking you to log-in. Sometimes there can be an extra "1" after the word "Login:", just delete it. Type root and press return
Then type:
dhclient
or
ifup eth0:
You should see the screen fill with text.
Some of the numbers have been removed from the screenshot above - they're not important.
Then hold down the following keys on the keyboard: ctrl+alt+2
and type the following:
sendkey ctrl-alt-f7
Then using the keyboard, hold down the following keys: ctrl+alt+1
Now open the browser and you should have internet access.
Logging boot messages
qemu -serial stdio -hda olpc-redhat-stream-development-ext3.img | tee boot.log
The kernel params in /boot/grup/menu.lst are already set to send to console IO to both the screen and serial ( console=ttyS0,115200 console=tty0), so -serial stdio is all it takes to have it sent to stdout.