Qt Creator Manual

Using Maemo or MeeGo Harmattan Emulator

The Maemo 5 (Fremantle) and MeeGo Harmattan emulator are installed as part of the Qt 4 SDK. After they are installed, you can start them from Qt Creator.

The Maemo 5 emulator emulates the Nokia N900 device environment. You can test applications in conditions practically identical to running the application on a Nokia N900 device with software update release 1.3 (V20.2010.36-2).

The MeeGo Harmattan emulator emulates the Nokia N9 device environment.

With the emulators, you can test how your application reacts to hardware controls, such as the power button, and to the touch screen.

To test the application UI, user interaction with the application, and functionality that uses the mobility APIs, use Qt Simulator, instead. For more information, see the Qt Simulator Manual.

The difference between Qt Simulator and the emulators is that when you compile your application binary for Qt Simulator, it is compiled against a host library. The binary run on the emulator is compiled for the actual device, using the Maemo 5 or Harmattan tool chain.

Starting the Emulator

The Start MeeGo Emulator button is visible if you have a project open in Qt Creator for which you have added a kit with Maemo or MeeGo Harmattan device type. It starts the Maemo or MeeGo Harmattan emulator, depending on the selected kit.

To start the emulator, click "Start MeeGo Emulator button" .

Test your application on the emulator as on a device. For a list of keyboard shortcuts that you can use to emulate keys and functions, see Emulating Device Keys.

Rendering Graphics

The emulators support OpenGL to improve graphics rendering. Hardware acceleration produces better results than software rendering. By default, Qt Creator automatically detects, whether hardware acceleration is supported on the development PC and tries to use it. However, sometimes the results of the automatic detection are not reliable, and hardware acceleration might be selected even if it is actually not available on the development PC. This causes the emulator to crash.

If the emulator crashes, you are asked whether you want to try software rendering, instead.

To specify the OpenGL mode, select Tools > Options > Linux Devices > MeeGo Qemu Settings.

Emulating Device Keys

The following table summarizes the keyboard shortcuts that you can use to emulate device keys and functions.

Device KeyKeyboard Shortcut
  • Alphabet keys
  • Comma (,)
  • Period (.)
  • Space
  • Arrow keys
  • Enter
  • Backspace
Respective keys on the development PC keyboard.
ShiftLeft Shift key (Maemo 5)

Shift (Harmattan)

CtrlLeft Ctrl key (Maemo 5)

Ctrl (Harmattan)

ModeLeft Alt key (Maemo 5)

Alt (Harmattan)

PowerEsc
Keypad slider open and closeF1
Keypad lock (Maemo 5 only)F2
Camera lens open and close (Maemo 5 only)F3
Camera focusF4
Camera take pictureF5

Note: The actual camera functionality is not emulated.

Stereo headphones connect and disconnect (Maemo 5 only)F6
Volume downF7
Volume upF8
Accelerometer x axis, negative1
Accelerometer x axis, positive2
Accelerometer z axis, negative4
Accelerometer z axis, positive5
Accelerometer y axis, negative7
Accelerometer y axis, positive8

Note: Each press of the accelerometer key turns the acceleration by 50 percent.

Closing the Emulator

To close the emulator, click the X at the top right corner of the device emulator view. The emulator interprets this as a press of the power button and displays the text Shutting down in the emulator window title pane. The emulator closes shortly after this.

You can also select the Start MeeGo Emulator button to close the emulator. This is a faster way to close the emulator, because it does not wait for the operating system running on the emulated machine to shut down, but this also means that it is less safe.