Automatic emulation in Ubuntu

From Openmoko

(Difference between revisions)
Jump to: navigation, search
(Problems)
Line 77: Line 77:
 
I got the problem too, again on gusty (beta) <br>
 
I got the problem too, again on gusty (beta) <br>
 
[[User:xuedi|xuedi]] 17 October 2007
 
[[User:xuedi|xuedi]] 17 October 2007
 +
 +
I've asked it into the bugzilla, maybe we will have an answer soon<br>
 +
[[User:Dolfje|Dolfje]] 21:07, 17 October 2007 (CEST)

Revision as of 20:07, 17 October 2007

This is a tutorial for getting an emulation environment on an Ubuntu system. For other systems see the Installation_guide

Contents

Installation

You have to know that there is a great tool to get it running on a linux system, namely the MokoMakefile. This is a sort of wrapper round several instructions, so it is easy to set up and maintain a development environment. If you build the whole MokoMakefile, you will need approximately 12GB, a swap+ram memory of about 1GB and minimum 5 hours time. But we will only build it for Qemu (the emulator that I will use) and that needs (on my system) only 890mb and a 15 min of your time.

To get it running, you will have to tweak your ubuntu a little bit (This will not damage other programs, everything will work as before).

  • Open your terminal (Applications->Accessories->Terminal).
  • Enter following command and select NO if it ask to install dash as /bin/sh.
   sudo dpkg-reconfigure dash
  • Install the needed programs (You will have to enter your password):
   sudo apt-get install monotone git-core cogito python-dev ccache m4 sed bison make cvs gawk libc6-dev g++ subversion sharutils docbook openjade quilt libmpfr-dev libpcre3-dev texinfo texi2html libboost-date-time-dev libboost-filesystem-dev libboost-regex-dev libboost-test-dev libboost-dev zlib1g-dev build-essential dh-make debhelper devscripts gcc-3.4 lynx netpbm libsdl1.2-dev dosfstools help2man python-psyco

Voila your system is ready to get the install the openmoko.

Now we will install Openmoko in a directory by downloading the MokeMakefile in it and build it.

  • Create a directory and go into the directory:
   mkdir openmoko
   cd openmoko
  • Get the MokoMakefile:
   wget http://www.rwhitby.net/files/openmoko/Makefile
  • Make the MokoMakefile and tell it, you want to install it for qemu:
   make qemu

This will download the necessarily files of the lastest release and build them following the MokoMakefile. After that it will start into the emulator for the first time. Voila your have now successfully installed openmoko onto your ubuntu system.

Start Openmoko

  • Open your terminal (Applications->Accessories->Terminal).
  • Go to the directory:
   cd openmoko
  • starting with the MokoMakefile
   make run-qemu

Now the bootloader will load. There you can choose different options. For select an option you have to press enter (=aux) and to execute it, hit space (=power). Thus if the bootloader shows, you just have to hit the space bar and the phone software will load.

Update Openmoko

  • Open your terminal (Applications->Accessories->Terminal).
  • Go to the directory:
   cd openmoko
  • Update with the MokoMakefile
   make qemu

Extra

Problems

If you have any problems, just add it here

When trying flash-qemu-local, following error occurs:

   Create BBT and erase everything ? <y/N>
   Skipping bad block at  0x03ff0000
   Skipping bad block at  0x03ff4000
   Skipping bad block at  0x03ff8000
   Skipping bad block at  0x03ffc000
   
   Creating BBT. Please wait ...Bad block table not found for chip 0
   Bad block table not found for chip 0
   Bad block table written to 0x03ffc000, version 0x01
   Bad block table written to 0x03ff8000, version 0x01
   
   GTA01Bv4 # setenv bootcmd 'openmoko/flash.sh: line 88:  4153 Terminated              
   $qemu -mtdblock "$script_dir/$flash_base" -kernel "$script_dir/$1" -serial stdio -nographic 
   -usb -monitor null 0<&0
   
   U-boot failed to finish writing in 300 seconds, giving up.
   
   make: *** [flash-qemu-local] Błąd 255

--mav 08:37, 9 October 2007 (CEST)

Same problem here. I'm trying to find a solution. Are you also using ubuntu gutsy?
Dolfje 00:46, 11 October 2007 (CEST)


I've got the Same Problem and i'm not able to find a workaround. Can anyone help?
Elessar 17 October 2007


I got the problem too, again on gusty (beta)
xuedi 17 October 2007

I've asked it into the bugzilla, maybe we will have an answer soon
Dolfje 21:07, 17 October 2007 (CEST)

Personal tools

This is a tutorial for getting an emulation environment on an Ubuntu system. For other systems see the Installation_guide

Installation

You have to know that there is a great tool to get it running on a linux system, namely the MokoMakefile. This is a sort of wrapper round several instructions, so it is easy to set up and maintain a development environment. If you build the whole MokoMakefile, you will need approximately 12GB, a swap+ram memory of about 1GB and minimum 5 hours time. But we will only build it for Qemu (the emulator that I will use) and that needs (on my system) only 890mb and a 15 min of your time.

To get it running, you will have to tweak your ubuntu a little bit (This will not damage other programs, everything will work as before).

  • Open your terminal (Applications->Accessories->Terminal).
  • Enter following command and select NO if it ask to install dash as /bin/sh.
   sudo dpkg-reconfigure dash
  • Install the needed programs (You will have to enter your password):
   sudo apt-get install monotone git-core cogito python-dev ccache m4 sed bison make cvs gawk libc6-dev g++ subversion sharutils docbook openjade quilt libmpfr-dev libpcre3-dev texinfo texi2html libboost-date-time-dev libboost-filesystem-dev libboost-regex-dev libboost-test-dev libboost-dev zlib1g-dev build-essential dh-make debhelper devscripts gcc-3.4 lynx netpbm libsdl1.2-dev dosfstools help2man python-psyco

Voila your system is ready to get the install the openmoko.

Now we will install Openmoko in a directory by downloading the MokeMakefile in it and build it.

  • Create a directory and go into the directory:
   mkdir openmoko
   cd openmoko
  • Get the MokoMakefile:
   wget http://www.rwhitby.net/files/openmoko/Makefile
  • Make the MokoMakefile and tell it, you want to install it for qemu:
   make qemu

This will download the necessarily files of the lastest release and build them following the MokoMakefile. After that it will start into the emulator for the first time. Voila your have now successfully installed openmoko onto your ubuntu system.

Start Openmoko

  • Open your terminal (Applications->Accessories->Terminal).
  • Go to the directory:
   cd openmoko
  • starting with the MokoMakefile
   make run-qemu

Now the bootloader will load. There you can choose different options. For select an option you have to press enter (=aux) and to execute it, hit space (=power). Thus if the bootloader shows, you just have to hit the space bar and the phone software will load.

Update Openmoko

  • Open your terminal (Applications->Accessories->Terminal).
  • Go to the directory:
   cd openmoko
  • Update with the MokoMakefile
   make qemu

Extra

Problems

If you have any problems, just add it here

When trying flash-qemu-local, following error occurs:

   Create BBT and erase everything ? <y/N>
   Skipping bad block at  0x03ff0000
   Skipping bad block at  0x03ff4000
   Skipping bad block at  0x03ff8000
   Skipping bad block at  0x03ffc000
   
   Creating BBT. Please wait ...Bad block table not found for chip 0
   Bad block table not found for chip 0
   Bad block table written to 0x03ffc000, version 0x01
   Bad block table written to 0x03ff8000, version 0x01
   
   GTA01Bv4 # setenv bootcmd 'openmoko/flash.sh: line 88:  4153 Terminated              
   $qemu -mtdblock "$script_dir/$flash_base" -kernel "$script_dir/$1" -serial stdio -nographic 
   -usb -monitor null 0<&0
   
   U-boot failed to finish writing in 300 seconds, giving up.
   
   make: *** [flash-qemu-local] Błąd 255

--mav 08:37, 9 October 2007 (CEST)

Same problem here. I'm trying to find a solution. Are you also using ubuntu gutsy?
Dolfje 00:46, 11 October 2007 (CEST)


I've got the Same Problem and i'm not able to find a workaround. Can anyone help?
Elessar 17 October 2007


I got the problem too, again on gusty (beta)
xuedi 17 October 2007

I've asked it into the bugzilla, maybe we will have an answer soon
Dolfje 21:07, 17 October 2007 (CEST)