Searching...

Matching results

    Getting started with 3rd Party Hardware

    As soon as you have an IP stack and the capability to do HTTP calls, you can use our HTTP API for devices. It doesn’t give you all the fancy device management and application management features but it’s really simple to use and it does the job for simple data exchange.

    Follow this tutorial to connect your device with AirVantage.

    Which 3rd party devices are supported?

    Raspberry Pi
    Beaglebone Black
    Others*
    *) If your hardware has a mqtt library.

    Any issues ?

    If you encounter any issue to set up your device, don’t hesitate to use the developer forum to benefit from the developer community experience.

    Step 1: Connect your device to AirVantage

    The first step consists in declaring your system and your application on AirVantage.

    Create an account

    • Register for an AirVantage Platform account .
    • You will received an email when your account is up.

    Register your system

    What is a system? A system represents:

    • Gateway/module which supplies the connectivity
    • SIM card which give the network access (if any)
    • Some applications running in the hardware (gateway/module/ any host like micro controller or processor)
    1. Go to Inventory > Systems
    2. Click on the “Create” button above the table, a dialog is displayed:
      1. “System” field: Specify an optional name for your system.
      2. In the “Details” screen, create a new gateway and enter the identifier of the device in the “Serial Number” field.
      3. You don’t need to create or use a subscription

    Search your application

    1. Click on Search application glass icon
    2. In the new dialog box, select the My Applications tab
    3. Search your application using its name (Generic Greenhouse)

    If you want to know more about how to declare an application on AirVantage and what it means, have a look at the Application Howto .

    Associate your application with your system

    1. Click on the application to select it.
    2. Click on the padlock and configure the password.
    3. Click on “Create”
    4. In the grid, select the newly created system and click on the “Activate” action

    Step 2: Design your application

    In this step, we are going to send data using the MQTT API for devices. There’s a huge choice of libraries on the web for many types of hardware and languages. Choose the one best suited to your hardware.

    You can use REST API for devices as well. As soon as you have an IP stack and the capability to do HTTP calls, you can use our HTTP API for devices. It doesn’t give you all the fancy device management and application management features but it’s really simple to use and it does the job for simple the data exchange. Read the following article to learn how to use the REST API for devices to easily enable the communication with AirVantage from your embedded application.

    You’re ready to implement your embedded application. Some samples are available:

    • Using MQTT with BeagleBone Black in Javascript, see this tutorial .
    • Using MQTT with a raspberry Pi in c, see this tutorial .
    • If you don’t find you device in this list, have a look to this generic tutorial .

    Step 3: Test your application

    Finally test your application by using this tutorial .

    Step 4: Define a dashboard and rules

    Once your system communicates correctly and data values are stored in AirVantage, you may want to automatate the analysis by using rules and show them in a dashboard. Have a look at this tutorial to learn how to define a rule and design your operational dashboard.

    Step 5: Use the API

    Once your system communicates correctly with AirVantage and data values can be browsed and displayed, you may want to get them in your specific application. Have a look at our AirVantage API to learn how to use this API to build powerful applications.

    Sample code

    • Using MQTT with BeagleBone Black in Javascript, clone it on github .
    • Using MQTT with an OpenPicus in c, clone it on github .
    • Using MQTT with Raspberry Pi in C, clone it on github .
    • Using MQTT with ST Nucleo (mbed) in C, clone it on github .
    • Using REST with Raspberry Pi in python, clone it on github .
    TOP