QtMoko

From Openmoko

Revision as of 12:56, 29 August 2010 by Niebert (Talk | contribs)

Jump to: navigation, search

QtMoko is a Debian based distribution for the Neo FreeRunner. The phone and user interface are based on Qt Extended Improved formerly known as Qtopia. The QtMoko wiki can be found here.

Contents

Download

Download the following files from radekp download to you desktop computer:

Installation

If you flash the FreeRunner with a kernel image from QtMoko, then you must install the kernel and the root file system with dfu-util.

NOTE: You need a fully charged Freerunner for installation.


Installation on SD card with Qi

If you have Qi installed then you can install QtMoko on the SD card. This seems to be useful if you want to work with different distribution and you can change the distribution just by changing the Mirco SD card in your FreeRunner.

NOTE: Installation in NAND-Memory with Qi is possible without errors, but with an installed bootloader Qi the boot process will terminate. Install u-Boot instead!


Installation in NAND Memory with u-Boot

If you have Qi installed then install u-boot again as a bootloader by downloading a u-boot-binary on http://downloads.openmoko.org/distro/unstable/daily/ otherwise the boot process will terminate and you have to install u-Boot.

All versions of the GTA02 (Neo FreeRunner) that have been sold to the public are version 5 hardware, so look for a file with "gta02" and "v5" in the name, for example: u-boot-gta02v5-1.3.1.bin (linked U-Boot-Version from 31.Jan 2010):

 sudo dfu-util -a u-boot -R -D u-boot-gta02v5-1.3.1.bin

Installation of Kernel and Root-FS

Switch off your FreeRunner and press the AUX and Power-On button at the same time. Your FreeRunner is showing the following U-Boot Menu:

  *** BOOT MENU (NOR) ***
  Boot
  Boot from Mirco SD (FAT/ext2)
  Set Console to USB
  Set Console to Serial
  Reboot
  Power Off  

The FreeRunner will stay in this mode for only 30 sec. Within this time you have to start dfu-util. If you want to flash the kernel image (you will need to be root on your PC) then you have to start the following command in the 30sec your see the BOOT MENU (use kernel and rootfs from http://sourceforge.net/projects/qtmoko/files/):

# for the Neo FreeRunner:
dfu-util -d 0x1d50:0x5119 -a kernel -R -D  uImage-v24.bin

and finally the root fs with this one:

# for the Neo FreeRunner:
dfu-util -d 0x1d50:0x5119 -a rootfs -R -D qtmoko-debian-v24.jffs2

Preparations on the Connected PC/Laptop

  • To enable connections just by using the hostname openmoko edit the /etc/hosts and add line
 192.168.0.202   openmoko
  • Enable internet connection via USB Networking so that the installation of packages will be possible.

First Boot

After finishing the installation without errors you have to start the FreeRunner and calibrate the touch screen. Then you see the installed QtMoko on your device.

QtMoko after first boot

First Login

If you want to login to your FreeRunner set up a network connection (see USB Networking) with USB cable and start:

  desktop# ssh -X -l root 192.168.0.202

The root password is empty so set it for security reason especially when you open the ssh-daemon on the WLAN network interface. Define root password as usual on a linux box with

  neo# passwd

If you have established the internet connection via USB cable then update the repository data:

  neo# apt-get update 

If you want to check if the internet connection is available on your freerunner ping the OpenMoko web server with:

  neo# ping 88.198.93.221
  neo# ping wiki.openmoko.org

If the first ping works and the second doesn't then check the DNS server settings (see USB Networking).

Setting Time and Date

Set the time and date on from your linux box with

ssh root@openmoko "date -us @`date -u +%s`"

sync the hardware clock with the system time to make your change persist over reboots:

# hwclock --systohc

If you want to set the time with a NTP Client install the following package, if you have a network connection available (see USB Networking)

# apt-get install ntpdate
# ntpdate-debian

For further detail see Setting Date and Time.

Usage

Size Root File System

If you want to install e.g. Twinkle and Navit on QtMoko the size of internal memory is not sufficient. By creating symbolic links this could be avoided.

NOTE: (Size Root Filesystem) Create symbolic links from root file system to SD-card to save internal memory.If some folders are symb-linked to SD-Card (with e.g. ext2 partition), e.g.
 # mkdir /media/card/share
 # mkdir /media/card/share/navit
 # ln -s /media/card/share/navit /usr/share/navit 

The same can be done for Twinkle

 # mkdir /media/card/share/twinkle
 # ln -s /media/card/share/twinkle /usr/share/twinkle 

It recommended to be an ext2-partition. After creating symb-links install software.


NOTE: (Suggestion) An improvement to QtMoko would be a post-installation script, that copies files to a Mirco-SD partition and creates symbolic links. E.g. application for the folder /usr/share/twinkle, you should

backup the directory /usr/share/twinkle before in case copying the file was not sucessful. The execute the following script, which is mention below.

 # sh symblink2sd.sh /usr/share /media/card/share  twinkle

symblink2sd.sh needs 3 parameter. This is the script symblink2sd.sh:

 #!/bin/sh
 echo "create directory $2$3 on SD-Card"
 mkdir $2/$3
 echo "copy files from $1/$3 to $2/$3"
 cp -R $2/$3/* $1/$3/
 # (1) the following line deletes the source folder e.g. /usr/share/twinke
 rm -R $1/$3
 # (2) the following line move the source folder e.g. /usr/share/twinke 
 #     to /usr/share/twinkeBAK . Comment (1) and uncomment mv command in (2)
 # mv $1/$3 $1/$3BAK
 echo "Create symbolic link from $1/$3 to $2/$3 "
 ln -s $1/$3 $2/$3

If you move files you can delete them later. Be careful which directories you are symlinking.


Login

If you want to login to your FreeRunner set up a network connection (see USB Networking) with USB cable and start:

  desktop# ssh -X -l root 192.168.0.202

or if hostname is defined in /etc/hosts

  desktop# ssh -X -l root openmoko

Installation of Applications

If you want to install applications (e.g. myapplication) login on your freerunner

 # apt-get install myapplication

Replace myapplication by the package name of application name you want to start, e.g. if you want to install the command line editor vim.

 # apt-get install vim

Navit

Navit Installation

If you want to install e.g. the application Navit, you have to install the following packages. Navit needs and X-Server and it will run under QX.

 # apt-get install flite
 # apt-get install unzip

The zip-package is necessary to unzip the navit-qtm.zip package.

 # cd /
 # wget http://www.openmobile.nl/media/download_gallery/navit-qtm.zip

During unzip you will be asked to replace /opt/qtmoko/bin/ppp-network. This has to be done to solve problems with DNS over GPRS. Backup ppp-network file before unzipping navit-qtm.zip.

 # cp /opt/qtmoko/bin/ppp-network /opt/qtmoko/bin/ppp-network.bak
 # unzip navit-qtm.zip
 # rm navit-qtm.zip
NOTE: Unzip extracts and overwrites the network settings files mentioned above. Due to this fact the usb0 MAC address changes for the USB connection to your freerunner. E.g. under Ubuntu 10.04 the new network interface for usb0 has to configure again


Now you have to restart your Freerunner, but you can also try from the commandline of your neo:

 # echo 1 > /proc/sys/vm/overcommit_memory

After restart you can start Navit under QX.

Download Maps

Create a folder MapsNavit on your SD card

 # mkdir /media/card/MapsNavit

The navit QT package navit-qtm.zip from http://www.openmobile.nl the navit.xml is predefined for benelux maps and will try to load osm_benelux.bin that should be store at

 /media/card/MapsNavit/osm_benelux.bin

If you want to use map for another country you can just store a downloaded Navit-Map in that folder and rename it osm_benelux.bin. If the map name should make sense, then you have to edit the navit.xml. See Navit-manual for details. You can find the navit.xml at:

 # /usr/share/navit/navit.xml

Create the folder .navit in the home directory on your FR and copy navit.xml to directory:

 # cd ~
 # mkdir .navit
 # cp /usr/share/navit/navit.xml .navit/navit.xml 

If you have the editor vim installed then edit the file at line 376 approx.:

 # vim ~/.navit/navit.xml

If you have downloaded the file germany.bin your mapset-tags should look like this:

 <!-- Mapset template for openstreetmaps -->
 <mapset enabled="yes">
   <map type="binfile" enabled="yes" data="/media/card/MapsNavit/germany.bin"/>
 </mapset>
Starting Navit
  • Open Main Menu by clicking on the green Q-Topia "Q"-Box.
  • Open Applications (4 Boxes, red, yellow, green, blue)
  • Scroll down and open QX
  • Select Navit
  • Click on the white Paper Icon on teh bottom left to open the context menu of the QX application.
  • Select Launch to start Navit.
  • Exit with AUX-Button without stopping navit

VoIP

Integrated VoIP-Client

QtMoko has an integrated VoIP-Client, which would be perfect to use a SIP-Account to do free of charge mobile communication world wide. But at the moment the integrated VoIP-Client does not work, due to some strange problems in Version v24 (see QtMoko-Wiki for current status of development).

Android on Freerunner has an integrated SIP-Client SipDroid that has strange audio problems as well (see http://sipdroid.org ).

Twinkle

See Twinkle for further details or the official Website http://www.twinklephone.com/

  apt-get install twinkle

Links

Personal tools

QtMoko is a Debian based distribution for the Neo FreeRunner. The phone and user interface are based on Qt Extended Improved formerly known as Qtopia. The QtMoko wiki can be found here.

Download

Download the following files from radekp download to you desktop computer:

Installation

If you flash the FreeRunner with a kernel image from QtMoko, then you must install the kernel and the root file system with dfu-util.

NOTE: You need a fully charged Freerunner for installation.


Installation on SD card with Qi

If you have Qi installed then you can install QtMoko on the SD card. This seems to be useful if you want to work with different distribution and you can change the distribution just by changing the Mirco SD card in your FreeRunner.

NOTE: Installation in NAND-Memory with Qi is possible without errors, but with an installed bootloader Qi the boot process will terminate. Install u-Boot instead!


Installation in NAND Memory with u-Boot

If you have Qi installed then install u-boot again as a bootloader by downloading a u-boot-binary on http://downloads.openmoko.org/distro/unstable/daily/ otherwise the boot process will terminate and you have to install u-Boot.

All versions of the GTA02 (Neo FreeRunner) that have been sold to the public are version 5 hardware, so look for a file with "gta02" and "v5" in the name, for example: u-boot-gta02v5-1.3.1.bin (linked U-Boot-Version from 31.Jan 2010):

 sudo dfu-util -a u-boot -R -D u-boot-gta02v5-1.3.1.bin

Installation of Kernel and Root-FS

Switch off your FreeRunner and press the AUX and Power-On button at the same time. Your FreeRunner is showing the following U-Boot Menu:

  *** BOOT MENU (NOR) ***
  Boot
  Boot from Mirco SD (FAT/ext2)
  Set Console to USB
  Set Console to Serial
  Reboot
  Power Off  

The FreeRunner will stay in this mode for only 30 sec. Within this time you have to start dfu-util. If you want to flash the kernel image (you will need to be root on your PC) then you have to start the following command in the 30sec your see the BOOT MENU (use kernel and rootfs from http://sourceforge.net/projects/qtmoko/files/):

# for the Neo FreeRunner:
dfu-util -d 0x1d50:0x5119 -a kernel -R -D  uImage-v24.bin

and finally the root fs with this one:

# for the Neo FreeRunner:
dfu-util -d 0x1d50:0x5119 -a rootfs -R -D qtmoko-debian-v24.jffs2

Preparations on the Connected PC/Laptop

  • To enable connections just by using the hostname openmoko edit the /etc/hosts and add line
 192.168.0.202   openmoko
  • Enable internet connection via USB Networking so that the installation of packages will be possible.

First Boot

After finishing the installation without errors you have to start the FreeRunner and calibrate the touch screen. Then you see the installed QtMoko on your device.

QtMoko after first boot

First Login

If you want to login to your FreeRunner set up a network connection (see USB Networking) with USB cable and start:

  desktop# ssh -X -l root 192.168.0.202

The root password is empty so set it for security reason especially when you open the ssh-daemon on the WLAN network interface. Define root password as usual on a linux box with

  neo# passwd

If you have established the internet connection via USB cable then update the repository data:

  neo# apt-get update 

If you want to check if the internet connection is available on your freerunner ping the OpenMoko web server with:

  neo# ping 88.198.93.221
  neo# ping wiki.openmoko.org

If the first ping works and the second doesn't then check the DNS server settings (see USB Networking).

Setting Time and Date

Set the time and date on from your linux box with

ssh root@openmoko "date -us @`date -u +%s`"

sync the hardware clock with the system time to make your change persist over reboots:

# hwclock --systohc

If you want to set the time with a NTP Client install the following package, if you have a network connection available (see USB Networking)

# apt-get install ntpdate
# ntpdate-debian

For further detail see Setting Date and Time.

Usage

Size Root File System

If you want to install e.g. Twinkle and Navit on QtMoko the size of internal memory is not sufficient. By creating symbolic links this could be avoided.

NOTE: (Size Root Filesystem) Create symbolic links from root file system to SD-card to save internal memory.If some folders are symb-linked to SD-Card (with e.g. ext2 partition), e.g.
 # mkdir /media/card/share
 # mkdir /media/card/share/navit
 # ln -s /media/card/share/navit /usr/share/navit 

The same can be done for Twinkle

 # mkdir /media/card/share/twinkle
 # ln -s /media/card/share/twinkle /usr/share/twinkle 

It recommended to be an ext2-partition. After creating symb-links install software.


NOTE: (Suggestion) An improvement to QtMoko would be a post-installation script, that copies files to a Mirco-SD partition and creates symbolic links. E.g. application for the folder /usr/share/twinkle, you should

backup the directory /usr/share/twinkle before in case copying the file was not sucessful. The execute the following script, which is mention below.

 # sh symblink2sd.sh /usr/share /media/card/share  twinkle

symblink2sd.sh needs 3 parameter. This is the script symblink2sd.sh:

 #!/bin/sh
 echo "create directory $2$3 on SD-Card"
 mkdir $2/$3
 echo "copy files from $1/$3 to $2/$3"
 cp -R $2/$3/* $1/$3/
 # (1) the following line deletes the source folder e.g. /usr/share/twinke
 rm -R $1/$3
 # (2) the following line move the source folder e.g. /usr/share/twinke 
 #     to /usr/share/twinkeBAK . Comment (1) and uncomment mv command in (2)
 # mv $1/$3 $1/$3BAK
 echo "Create symbolic link from $1/$3 to $2/$3 "
 ln -s $1/$3 $2/$3

If you move files you can delete them later. Be careful which directories you are symlinking.


Login

If you want to login to your FreeRunner set up a network connection (see USB Networking) with USB cable and start:

  desktop# ssh -X -l root 192.168.0.202

or if hostname is defined in /etc/hosts

  desktop# ssh -X -l root openmoko

Installation of Applications

If you want to install applications (e.g. myapplication) login on your freerunner

 # apt-get install myapplication

Replace myapplication by the package name of application name you want to start, e.g. if you want to install the command line editor vim.

 # apt-get install vim

Navit

Navit Installation

If you want to install e.g. the application Navit, you have to install the following packages. Navit needs and X-Server and it will run under QX.

 # apt-get install flite
 # apt-get install unzip

The zip-package is necessary to unzip the navit-qtm.zip package.

 # cd /
 # wget http://www.openmobile.nl/media/download_gallery/navit-qtm.zip

During unzip you will be asked to replace /opt/qtmoko/bin/ppp-network. This has to be done to solve problems with DNS over GPRS. Backup ppp-network file before unzipping navit-qtm.zip.

 # cp /opt/qtmoko/bin/ppp-network /opt/qtmoko/bin/ppp-network.bak
 # unzip navit-qtm.zip
 # rm navit-qtm.zip
NOTE: Unzip extracts and overwrites the network settings files mentioned above. Due to this fact the usb0 MAC address changes for the USB connection to your freerunner. E.g. under Ubuntu 10.04 the new network interface for usb0 has to configure again


Now you have to restart your Freerunner, but you can also try from the commandline of your neo:

 # echo 1 > /proc/sys/vm/overcommit_memory

After restart you can start Navit under QX.

Download Maps

Create a folder MapsNavit on your SD card

 # mkdir /media/card/MapsNavit

The navit QT package navit-qtm.zip from http://www.openmobile.nl the navit.xml is predefined for benelux maps and will try to load osm_benelux.bin that should be store at

 /media/card/MapsNavit/osm_benelux.bin

If you want to use map for another country you can just store a downloaded Navit-Map in that folder and rename it osm_benelux.bin. If the map name should make sense, then you have to edit the navit.xml. See Navit-manual for details. You can find the navit.xml at:

 # /usr/share/navit/navit.xml

Create the folder .navit in the home directory on your FR and copy navit.xml to directory:

 # cd ~
 # mkdir .navit
 # cp /usr/share/navit/navit.xml .navit/navit.xml 

If you have the editor vim installed then edit the file at line 376 approx.:

 # vim ~/.navit/navit.xml

If you have downloaded the file germany.bin your mapset-tags should look like this:

 <!-- Mapset template for openstreetmaps -->
 <mapset enabled="yes">
   <map type="binfile" enabled="yes" data="/media/card/MapsNavit/germany.bin"/>
 </mapset>
Starting Navit
  • Open Main Menu by clicking on the green Q-Topia "Q"-Box.
  • Open Applications (4 Boxes, red, yellow, green, blue)
  • Scroll down and open QX
  • Select Navit
  • Click on the white Paper Icon on teh bottom left to open the context menu of the QX application.
  • Select Launch to start Navit.
  • Exit with AUX-Button without stopping navit

VoIP

Integrated VoIP-Client

QtMoko has an integrated VoIP-Client, which would be perfect to use a SIP-Account to do free of charge mobile communication world wide. But at the moment the integrated VoIP-Client does not work, due to some strange problems in Version v24 (see QtMoko-Wiki for current status of development).

Android on Freerunner has an integrated SIP-Client SipDroid that has strange audio problems as well (see http://sipdroid.org ).

Twinkle

See Twinkle for further details or the official Website http://www.twinklephone.com/

  apt-get install twinkle

Links