Configure a New Project (Android)

Have more questions? Submit a request

Android  Minimum Requirements

  • Support with Arm64-v8a CPU instruction set
  • Support with API level 27 and higher

1. Include AAR

Include AAR as a new module
  1. After creating a new project, go to New > New Module.
  2. Select Import .JAR/.AAR Package.
  3. Click Next.
  4. Select the AAR file (Binah's SDK) - (bnhhrlib.aar).
  5. Click Finish. The Subproject bnhhrlib is added to your project.

2. Create Dependencies

Create dependencies
  1. Open the build.gradle of your application.
  2. Under dependencies, add implementation project(':bnhhrlib').
  3. Under dependencies, add the following:
    implementation 'com.appmattus.certificatetransparency:certificatetransparency-android:1.0.0'
  4. Open settings.gradle, and make sure the include ':bnhhrlib' is there. If it is not there, simply add it to the file.

The SDK is ready for implementations.

3. Configure C++ and NDK

Configure C++ and NDK

To enable your Android to work with our C++ native libraries, install an NDK that supports C++ 17.

  • Install NDK version 20 and higher (Recommend: 20.1.5948944)
  1. Open Android Studio.
  2. Go to Tools > SDK Manager.
  3. In the Preferences for New Projects window, do the following:
    • Select SDK Tools.
    • Select the Show Package Details option.
  4. Scroll to NDK (Side by side), and select the correct NDK version (20.1.5948944)
  5. Click OK to begin the installation.
  6. When asked, click OK to confirm the changes.
    The NDK installation begins.
    Tip: Click Background to move this window to the background.

4. Start Implementation

Start implementation
  1. Open the MainActivity Java file and add import ai.binah.hrv.*;.
  2. When you start typing, an auto completion box opens, indicating the SDK was added.

5. Add Unique IDs

Add unique IDs for license management
    1. Create a Java file in the same location where the mainActivity is located, and name it
    2. Include one string for the license key as follows:

6. Configure Build/Deployment Configurations

Configure build/deployment configurations

Configure build/deployment configurations (default APK or APK from app bundle)

  1. Add the following line of code to the file
  2. Save the changes made to the file.
  3. Go to Run/Debug Configurations.BUILD1.png
  4. Select app.
  5. Change Installation Options > Deploy from Default APK to APK from app bundle.
  6. Click OK.
  7. Run the Project on a real device to test the configuration.


  • Run the application on a real device to test (it does not work on an emulator)
  • Google prefers publishing with the Android App Bundle on Google Play. To learn more, see about About Android App Bundles.

Articles in this section

Was this article helpful?
0 out of 0 found this helpful


1 comment

Please sign in to leave a comment.

  • pressure gauge app for android