Skip to content

Latest commit

 

History

History
82 lines (48 loc) · 3.19 KB

INSTALL-STANDALONE.md

File metadata and controls

82 lines (48 loc) · 3.19 KB

Building onecourse

Last updated: May 6, 2019

Overview

The installation steps below will allow you to set-up the application as a standalone application alongside your current filesystem without the need to flash custom filesystem images. If you instead want to build custom filesystem images (i.e., clear the file system and have a single application remain on the tablet) for onecourse application, follow the steps detailed in BUILD file.

Note: OS-specific commands are mentioned where required. All other commands are OS independent (i.e., they work on both Windows and Mac/Linux)

Requirements

  1. Ensure you have adb installed on your computer. To do this, you can follow the steps in this helpful guide.
  2. Connect your device to the computer via USB.

1. Device preparation

Enable developer mode on your device
  1. Go to Settings --> About tablet.
  2. Tap Build Number 7 times until it displays "You are now a developer".
Enable USB Debugging on your device
  1. Go to Settings --> Developer options.
  2. Tap Enable USB debugging.
  3. Tap OK when prompted by the disclaimer.
  4. You should see a dialog box with your computer's "RSA key fingerprint".
  5. Tap "Always allow from this computer".
  6. Tap OK.

2. Building the onecourse app

  1. Ensure you have Android Studio installed. To do this, you can follow the steps in this helpful guide.

  2. Configure the ROOT_FOLDER environment variable and ANDROID_HOME environment variable based on the location of the Android SDK:

    Follow these steps for macOS (Mavericks or later) or Linux-based system:

     export ROOT_FOLDER=onecourse
     
     export ANDROID_HOME=[PATH/TO/ANDROID_SDK]
    

    Follow these steps for a Windows 7 or later system:

     Set-Variable -Name "ROOT_FOLDER" -Value "onecourse"
     
     Set-Variable -Name "ANDROID_HOME" -Value "PATH/TO/ANDROID_SDK"
    
  3. Clone the onecourse source repository:

     git clone https://github.com/XPRIZE/GLEXP-Team-onebillion.git $ROOT_FOLDER/
    
  4. In the ROOT_FOLDER build gradle tasks:

     ./gradlew tasks
    
  5. Build the onecourse .apk:

    onecourse English:

       ./gradlew assembleEnGB_community_debug
    

    onecourse Swahili:

       ./gradlew assembleSw_community_debug
    
  6. Download the language-specific assets from the releases section and extract into your ROOT_FOLDER.

3. Installing onecourse

  1. Install the application via adb:

    onecourse English:

     adb install app/build/outputs/apk/enGB_community_/debug/app-enGB_community_-debug.apk
    

    onecourse Swahili:

     adb install app/build/outputs/apk/sw_community_/debug/app-sw_community_-debug.apk
    
  2. Copy the assets to the Android device:

     adb push -p assets/ /sdcard/onebillion/assets
    
  3. Once the assets are transferred, open the application and grant all the required permissions. It is now ready to use.
    Note: Grant the Allow modify system settings permission to allow the application to manage brightness setting.