qt development on android n.
Skip this Video
Download Presentation
Qt Development on Android

Loading in 2 Seconds...

play fullscreen
1 / 11

Qt Development on Android - PowerPoint PPT Presentation

  • Uploaded on

Qt Development on Android. May 10, 2012 Lloyd Moore, President/Owner. Overview. Quick Start Video Building Mobility 1.2 SDK Emulator Quirks Installing On A Device Summary. Quick Start Video .

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
Download Presentation

PowerPoint Slideshow about 'Qt Development on Android' - moesha

Download Now An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
qt development on android
Qt Development on Android

May 10, 2012

Lloyd Moore, President/Owner

  • Quick Start Video
  • Building Mobility 1.2 SDK
  • Emulator Quirks
  • Installing On A Device
  • Summary
quick start video
Quick Start Video

Excellent video on the web showing how to set everything up so we’ll just start with that: http://labs.qt.nokia.com/2011/02/28/necessitas/

Necessitas home: http://sourceforge.net/p/necessitas/home/necessitas/


Project is actively being worked on, and is currently at Alpha 3, update 4 revision level. Last update was Feb 18, 2012. This is a technology you will want to watch, but NOT start any major projects with at this time.

The rest of this presentation is based on Ubuntu 10.10 and some assumptions are made about directories and such, which may vary based on your individual configuration.

building mobility 1 2 sdk
Building Mobility 1.2 SDK

Pretty much the same as doing this for the desktop, however directories are different.

  • Download Qt Mobility 1.2 from http://download.qt.nokia.com/qt/add-ons/ and unzip to wherever you would like
  • Create the following batch file


  • Run the batch file: source my_batch_file.cmd
  • Run the configure command:

./configure -prefix /opt/necessitas/Android/Mobility/480/armeabi/ -modules "location“

  • Build the SDK: make
  • Install the SDK: sudo make install
  • Restart Qt Creator
build issues we hit building mobility
Build Issues we hit building Mobility
  • Necessitas installs to “/opt/necessitas” so you will need to make sure all directory references point here. The scripts and commands above have already had this change added in.
  • Related to #1 the tool chain ends up in a different place than expected. This can easily be fixed with a “soft link” or “symbolic link”

ln –s ~/NecessitasQtSDK /opt/necessitas

emulator quirks
Emulator Quirks

The Android emulator generally appears to work, however it is a bit slow and this creates some issues.

  • When starting a test run from inside Qt Creator for the first time, Qt Creator does not wait long enough for the emulator to start in all cases.


Start the emulator manually before attempting the test run

Just allow the first run to timeout, wait for the emulator to boot, and do it again

This seems to be better in more recent releases

  • For best results unlock the emulator before running your application
  • Qt libraries will need to be downloaded the first time, this takes a while and Qt Creator does not wait for this.


Again just wait for this to happen the first time and then start the test run again.

The libs appear to be saved even if the emulator is turned off.

configuring hardware target
Configuring Hardware Target

Need to turn on client side debugging

  • “Settings” -> “Applications” -> “Development”
  • Turn on “USB debugging”, “Stay Awake” and “Allow Mock Locations”
  • Other options may be available on your device, device shown below is a Motorola Droid.
installing application on a device
Installing Application On A Device

Device needs to have a current version of Android on it, not sure specifically what the cut off is at this point but Android 2.2 does NOT work.

Have not found the mechanism to do this yet inside QtCreator, pieces appear to be there but not complete yet.

Standard SDK tool from Android SDK is called Android Debug Bridge

  • adb devices

- Will allow you to see attached devices and give the serial number of each

-Also shows emulator(s)

-Prefix with “sudo” if running under Linux to get needed permissions

    • adb –s <device id> install <my_package.apk>

- Installs your program/package to the actual device

-Will also install a default icon for the application

Full documentation for adb available at: http://developer.android.com/guide/developing/tools/adb.html

live demos
Live Demos
  • If interested and time we can fire up the live environment and do some live builds and runs of:
  • Mobility Location Services
  • Hello World application
  • LocoMaps application
  • Source code for the Hello World application will also be made available.
  • Quick Start Video
    • http://labs.qt.nokia.com/2011/02/28/necessitas/
  • Necessitas Installer Downloads
    • http://sourceforge.net/p/necessitas/home/necessitas/
  • NecessitasWiki Pages
    • http://sourceforge.net/p/necessitas/wiki/Home/
  • Android SDK Documentation
    • http://developer.android.com/index.html
  • My Contact Info:
    • Lloyd@CyberData-Robotics.com
    • http://www.CyberData-Robotics.com
  • Will be around a bit after the meeting for individual questions
  • Feel free to e-mail me