Oracle Mobile Application Framework (MAF) enables you to create an application that can house different types of content that runs on mobile devices powered by Apple iOS platforms or Android devices. This section of the tutorial walks you through configuring your environment so that you can develop and test Oracle MAF applications using OEPE and an Android environment. In this section you configure an environment to use OEPE and an Android emulator on which you will deploy your MAF application. Although we are configuring the environment to use an emulator, you can also deploy to an actual Android device.
Step 1: Download and Install the Required Components
  1. Download and install the Android Stand-alone SDK tools from . You will need to accept the terms and conditions before you download the SDK.

    check for updates

  2. Unpack the ZIP file you just downloaded. It will unpack into a directory named android-sdk-macosx. Move it to an appropriate location such as Documents, or Development tools, or where ever you prefer.

  3. On Windows double-click SDK Manager.exe and on Mac, navigate to android-sdk-macosx/tools and double-click android.

  4. By default, the Android SDK Tools, Android SDK Platform-tools and several other packages are selected to be installed the first time you run the SDK Manager. Click Install to install the default packages. You will need to accept the terms and conditions.

    check for updates

  5. If it wasn't selected and installed by default, select and install the Android 5.0.1 (API 21) components. If it is installed by default, skip to the next step. You will need to accept the software terms to install the packages.

    check for updates
  6. You also need to install the Google Cloud Messaging for Android Library. To see this option you must select the Obsolete checkbox at the bottom of the window. Then, scroll toward the bottom of the SDK Manager, select the Google Cloud Messaging for Android Library.

    You also need to download and install the package for the emulator accelerator. In can be found in the Extras node and may already be installed (Intel x86 Emulator Accelerator (HAXM) Installer) . If it is not, then select it too. 

    Then click Install. You will need to accept the license agreement.

    check for updates
  7. To use the Intel x86 Emulator Accelerator, once downloaded, you then must then install the drivers.
    On windows, find and double-click IntelHaxm.exe. On Mac, use Finder to locate android-sdk-macozx/extras/intel/Hardware_Accelerated_Execution_Manager and install the correct intelHAXM dmg depending on your OS version.

    check for updates
  8. Set the memory reservation to 1024 MB and finish the installation.

    check for updates
  9. You will need to have installed Oracle Enterprise Pack for Eclipse before you can continue to the next steps.

  10. Open OEPE. HINT: On Windows, from the install directory double-click eclipse.exe. On Mac double-click in the install directory.

    check for updates

  11. In WIndows select Window > Preferences and on Mac, select Eclipse > Preferences.

    step 1 in check for updates

    step 1 in check for updates
  12. In the Preferences dialog, select Oracle > Mobile Application Framework >Android.

  13. step 1 in check for updates

  14. Click Add to add the SDK. You will see a dialog where you can browse to where to installed the Android SDK. Select your install directory including the sdk subdirectory. When you have selected the install directory, click OK to add the SDK.

    step 2 in check for updates

  15. In the Preferences dialog, you will see the SDK details are now populated. Click OK to close the Preferences dialog.

    restart jdevloper message

  16. Before you create, deploy, and test a MAF application, you will need to launch the Android emulator. To deploy the smaller and faster Release packaging, you will want to expand the Android section and fill out the Android Keystore node.

  17. If you are on Windows, navigate to the SDK folder within the SDK installation folder. Double-click AVD Manager.exe to open it. This opens the AVD manager directly.

    preferences menu
  18. If you are on a Mac, navigate the the Android SDK Home /tools and double-click android.This launches the Android SDK Manager.

    preferences menu
  19. If you are on a Mac, use the Android SDK Manager menu select Tools > Manage AVDs.

    preferences menu
  20. In the Android Virtual Device Manager, click Create to create a new Android Virtual Device and specify the following values to the properties.

    check for updates

    AVD Name = MAF
    Device = Nexus 4 (4.7", 768 x 1280; xhdpi)
    Target = Android 5.0.1 - API Level 21
    CPU/ABI = Intel Atom (x86_64)
    Skin = No skin
    Front Camera = Emulated
    Back Camera = Emulated
    Memory Options Ram = 512
    MiB Internal Storage = 1024 MiB
    SD Card = 1024 MiB
    Use Host GPU (checked)

  21. For the remainder, keep the defaults and click the OK button.

    You may choose another device type, keeping in mind that newer devices have greater resource demands and you may run into RAM issues on your own machine.

    check for updates

  22. A notification of the new AVD is displayed. Click OK to dismiss it.

    check for updates

  23. Select the new AVD and click the Start button.

    check for updates

  24. Accept the default values in the Launch Options pane, and click Launch.

  25. check for updates

  26. It may take a while for the emulator to be invoked and start running. Depending on the speed of your CPU, 2 minutes is possible. Once it's running, you may minimize the emulator window. (HINT: If the emulator does not start successfully, select the device and click Edit to check the settings.)

    check for updates

  27. The setup is now complete.

Back to top
Copyright © 2014, Oracle. All rights reserved.