Smartphone Development

From Lazarus wiki
Jump to navigationJump to search

There is a multitude of Smartphone platforms available today, and in many of them it is possible to write Free Pascal and Lazarus software.

Smartphone Marketshares

Precise reports about Smartphone marketshares can be bought from Gartner, but this information also comes up in scattered news. This section attempts to put some organization in those news to reconstruct a precise picture of the marketshare for those which cannot aford the full report from Gartnet. This information can be relevant when choosing for which operating system to develop and the potential market that they offer. The market can be very different in different parts of the world, but mostly information about US and Worldwide markets come in the news, but occasionally there is also information about regional markets.

Worldwide Marketshares

By Quarter

Year Marketshares Sales Total Sales
2007 Q2 Symbian 66%, BlackBerry 9%, WinCE 12%, Linux 10%, Mac 1% Symbian 18m, BlackBerry 3m, WinCE 3m, Linux 3m, Mac - 28m
2007 Q4 Symbian 62%, BlackBerry 11%, WinCE 12%, Linux 7%, Mac 5% Symbian 23m, BlackBerry 4m, WinCE 4m, Linux 3m, Mac 2m 37m
2008 Q1 Symbian 57%, BlackBerry 13%, WinCE 12%, Linux 8%, Mac 5% Symbian 18m, BlackBerry 4m, WinCE 4m, Linux 3m, Mac 2m 32m
2008 Q2 Symbian 57%, BlackBerry 17%, WinCE 12%, Linux 7%, Mac 3% Symbian 18m, BlackBerry 6m, WinCE 4m, Linux 2m, Mac 1m 32m
2008 Q3 Symbian 50%, BlackBerry 15%, WinCE 11%, Linux ?, Mac 13% Symbian 19m, BlackBerry 6m, WinCE 4m, Linux ?, Mac 5m 36m
2008 Q4 Symbian 47%, BlackBerry 20%, WinCE 12%, Linux 6%, Mac 11% Symbian 18m, BlackBerry 7m, WinCE 5m, Linux 3m, Mac 4m 38m
2009 Q1 Symbian 49%, BlackBerry 20%, WinCE 12%, Linux 8%, Mac 11% Symbian 18m, BlackBerry 7m, WinCE 5m, Linux 3m, Mac 4m 36m
2009 Q2 Symbian 50%, BlackBerry 20%, WinCE 9%, Linux 3%, Mac 14%, Android 3% Symbian 20m, BlackBerry 8m, WinCE 4m, Linux ?, Mac 5m 41m
2009 Q3 Symbian 45%, BlackBerry 19%, WinCE 8%, Linux 5%, Mac 17%, Android 4% Symbian 19m, BlackBerry 8m, WinCE 3m, Linux 2m, Mac 7m, Android 2m 43m
2009 Q4 Symbian 44%, BlackBerry 20%, WinCE 7%, Linux 3%, Mac 16%, Android 9% Symbian 24m, BlackBerry 11m, WinCE 4m, Linux 2m, Mac 9m, Android 5m 54m
2010 Q3 Symbian 37%, BlackBerry 15%, WinCE 3%, Linux 2%, Mac 17%, Android 21% Symbian 29m, BlackBerry 12m, WinCE 2m, Linux 2m, Mac 13m, Android 26m 81m
2010 Q4 Symbian 31%, BlackBerry 14%, WinCE/WP7 3%, Linux 2%, Mac 16%, Android 33% Symbian 31m, BlackBerry 15m, WinCE/WP7 3m, Linux 2m, Mac 16m, Android 33m 101m
2011 Q1 Symbian 26,0%, BlackBerry 13,6%, WinCE/WP7 2,6%, iPhone 18,3%, Android 36,1% Symbian 26m, BlackBerry 14m, WinCE/WP7 3m, iPhone 19m, Android 37m 101m
2011 Q4 Symbian 11,7%, BlackBerry 8,8%, WinCE/WP7 1,9%, iPhone 23,8%, Android 50,9% Symbian 17m, BlackBerry 13m, WinCE/WP7 3m, iPhone 35m, Android 76m 149m
2012 Q1 Symbian 6,8%, BlackBerry 6,4%, WinCE/WP7 2,2%, iPhone 23,0%, Android 59,0% Symbian 10m, BlackBerry 10m, WinCE/WP7 3m, iPhone 35m, Android 90m 149m
2012 Q2 Symbian 4.4%, BlackBerry 4.8%, WinCE/WP7 3.5%, iOS 16.9%, Android 68.1%, others 3.5% Symbian 6.8m, BlackBerry 7.4m, WinCE/WP7 5.4m, iOS 26m, Android 104.8m, others 3.6m 154m
2012 Q3 Symbian 2.6%, BlackBerry 5.3%, WinCE/WP7 2.4%, iOS 13.9%, Android 72.4%, Bada 3.0%, others 0.4% Symbian 4.4m, BlackBerry 8.9m, WinCE/WP7 4.1m, iOS 23.6m, Android 122.5m, Bada 5.1m, others 683t 169m
2012 Q2 Symbian 0.3%, BlackBerry 2.7%, WinCE/WP7 3.3%, iOS 14.2%, Android 79.0%, Bada 0.4%, others 0.2% Symbian 631t, BlackBerry 6.2m, WinCE/WP7 7.4m, iOS 31.9m, Android 177.9m, Bada 838t, others 471t 225m

Sources:

By Region

Historical data, 2004 to 2010

Region Year Marketshares
Europe, Middle East, Africa 2004 Symbian 92%, WinCE 8%
Japan 2004 Symbian 96%, PalmOS 2%, Other 2%
North America 2004 Symbian 30%, WinCE 20%, PalmOS 45%, Other 5%
China 2004 Symbian 52%, WinCE 6%, PalmOS 1%, Linux 20%, Other 11%
Rest of Asia 2004 Symbian 96%, WinCE 2%, PalmOS 2%
Latin America 2004 Symbian 89%, WinCE 1%, PalmOS 10%
Europe, Middle East, Africa 2006 Symbian 95%, WinCE 4%, Blackberry 1%
Japan 2006 Symbian 60%, Linux 40%
North America 2006 Symbian 10%, PalmOS 20%, WinCE 40%, Blackberry 30%
China 2006 Symbian 56%, Linux 40%, WinCE 2%, Other 2%
Rest of the World 2006 Symbian 94%, WinCE 2%, PalmOS 2%, Linux 2%
Europe, Middle East, Africa 2007 Q3 Symbian 85%, BlackBerry 4%, WinCE 6%, Linux 5%
Japan 2007 Q3 Symbian 69%, WinCE 1%, Linux 30%
China 2007 Q3 Symbian 56%, WinCE 5%, Linux 39%
North America 2007 Q3 Symbian 4%, BlackBerry 35%, WinCE 26%, Linux 2%, Mac 26%, PalmOS 7%
Latin America 2007 Q3 Symbian 82%, BlackBerry 2%, WinCE 7%, Linux 9%
United States 2009 Q4 BlackBerry 41%, Windows 20%, iPhone 25%, Android 3%, Palm 6%
United States 2010 Q1 BlackBerry 43%, Windows 16%, iPhone 25%, Android 7%, Palm 2%
United States 2010 Q2 BlackBerry 42%, Windows 13%, iPhone 24%, Android 13%, Palm 5%
United States 2010 Q4 BlackBerry 27%, Windows 10%, iPhone 27%, Android 29%, Palm 4%

Sources:

India

Region Year Marketshares
India 2012 Q1 Android 51% Symbian 23% BlackBerry 10%, iPhone 2%, Windows Phone 3%, Bada 10%

Sounces:

iOS

For information about writing Free Pascal applications for iPhone, iPad and other iOS devices read:

Windows CE

Windows CE is the name of an operating system which is used in Smartphones, PDAs, GPS devices, bar code scanners and other embedded devices. When run in a Smartphone the latest versions of the operating system have been branded as Windows Mobile, but it's the same operating system.

You can see information about writing Lazarus software for Windows CE devices in the following pages:

For information about using Free Pascal without Lazarus to developed WinCE applications read:

Maemo Linux

Tutorial

Maemo runs "pure" arm-linux applications, so you need to enable FPC to cross compile for arm-linux. It is reccomended to use latest FPC trunk (2.5.x at time of writing; meanwhile FPC 2.6.0 stable has been released and trunk is 2.7.x).

See HERE for the tutorial.

Nokia N900 notes

Some notes specifically meant for the Nokia N900 internet tablet/smartphone.

  • The device accepts eabi v5 code, so make sure to use option
-meabi=5

in the assembler section of the tutorial

  • Target libs

For the Nokia N900, you need to copy /lib/* and /usr/lib/* (no subdirs) to ~/lazarus/fpc/libcross/

Then you have to rename each library that is not found by the linker (ld) to the file name searched by linker itself.

An example: if you get this error

libX11.so not found (or incompatible)

and you have a file called libX11.so.6.2.0 in /usr/lib, you need to copy it to ~/lazarus/fpc/libcross (edited by BigChimp Aug 2012: ?!? I hope this is what was meant) and rename it into libX11.so

It is also possible to compile freepascal/lazarus code right on the device.

Video

Prepare "Maemo SDK Virtual Image" with Lazarus in 10 minutes.

Just copy commands from tutorial and paste into Ubuntu console (remember to replace every /home/user/ with /home/maemo/).

Click HERE to see video.

Android

Currently a Lazarus port for Android is under construction. Read more in Custom Drawn Interface/Android

Other Linux-based phones

For ARM-based phones you can read here: Linux for ARM

Palm OS

An initial FPC port has been started, more information here: PalmOS port

Symbian OS

A FPC port based on Symbian UIQ 2 and 3 was started, but not finished: SymbianOS. In 2009 UIQ was discontinued by it's main promoter, Sony Erricsson and the company responsible for it's development was closed, so any new port should target one of the remaining Symbian platforms, the most popular one being S60.

Blackberry, Java-based phones

There are many phones which can run only Java software, including Blackberry and most of the cheap phones without a native interface. Also some other phones can also run Java applications out of the box, for example Symbian OS.

It's not possible to develop for java-based phones with Free Pascal at the moment, but you can use another compiler, MIDlet Pascal do to it. It has been recently made open source, and can be downloaded here:

http://sourceforge.net/projects/midletpascal/