Developer

 View Only
last person joined: 2 days ago 

Expand all | Collapse all

IoT BLE advertisement reception

This thread has been viewed 72 times
  • 1.  IoT BLE advertisement reception

    Posted Mar 29, 2021 10:59 AM
    I am thinking about a tool tracking application built on Aruba devices.  We have thousands of Aruba access points around campus.  For now, they are beaconing so that low-power devices can figure out where they are, but I don't yet know how to receive advertisement beacons.  I started by reading This Document which was a great starting point, but I would like to have a more interactive way to learn.  I tried the HP DEV slack (which has an #aruba room) but it's not very active.  So, I'm hoping I can start the conversation here instead.

    We do not have nor do we plan to use Meridian.  The idea is to develop our own thing specifically geared toward our application.

    Advertisement and scan response frames for unknown devices are stored in raw format, that is, the payload for each frame type is stored as a hexadecimal string, along with the RSSI value. BD maintains a database of IoT devices with attributes populated for known or classified devices and complete advertisement or scan frames for unclassified devices.

    If I understand this correctly, then this means that on each access point runs a background daemon that collects advertisements (beacons) that it hears and stores them in a table, along with their RSSI.  In my case the beacons are going to be in Apple iBeacon format, including a type, UUID, major/minur user-defined IDs, beacon TX power, and RSSI.  The document I quoted above says "Other iBeacons" which I think means it understands them i.e. an iBeacon is a "known device."

    Transport Interval. The transport interval determines how often IoT or BLE data is sent from BD to BR. ArubaOS supports the following transport intervals:Asset tag RSSI data is sent every 4 seconds from each AP to MeridianAruba beacon management data is sent every 30 minutes

    If I understand this, the BR is the BLE Relay, another program that runs on each individual AP.  The BR collects the beacons it hears from the BD process, and, if configured correctly, it can push them somewhere of your choosing: either an HTTPS POST to somewhere, or over a websocket.  This has to be done on each individual access point, in my case that's thousands of them.  They then all individually will HTTP POST their 'heard beacons' tables to an endpoint of my choosing.

    This leads to some questions, based on my limited understanding of how this works.

    First, is the format of these messages defined somewhere I can see (a url etc.)?  I gather that if it is HTTP POST that it's JSON (what's the format?) and if it's via websocket it's protobuf (where can i find the .proto definitions?)

    Second, if I have this right, then I'll need to stand up a server that can handle a LOT of concurrent connections (7,500 access points).  Do I have that right?  Can these APs be configured to only send changes?

    Third, there is some notion of filtering.  That might be useful for me but I think to do that I would have to maintain a list of UUIDs and push them to every single access point.  Do I have that right?  I don't think I can use this but I still would like to know how it works.  It sounds like a useful way to limit traffic, but I might want to limit what users see what (i.e. have multiple whitelists).  Based on that, I think I need to have my own central server receive everything, then filter based on the individual user or client.

    Finally ... if I bought just one aruba access point for home (like an AP22) could I experiment with all of this without being tied to the full campus environment, Aruba Central, etc.?

    --Chris







    ------------------------------
    Christopher Piggott
    ------------------------------


  • 2.  RE: IoT BLE advertisement reception

    EMPLOYEE
    Posted Mar 29, 2021 01:02 PM
    Hi Chris,
    Thanks for posting this in our Dev community!  I've notified one of our IoT/BLE experts to take a look at some of the beacon specific sections.
    As for your last question, you can set an AP to act as an Instant Access Point (IAP), which wouldn't necessarily need a gateway to function.  IAPs do have different APIs available versus the Central managed APs (these utilize the Central API).

    For some information for the IAP APIs, you can check out the ArubaOS 8.7 REST guide here:
    https://support.hpe.com/hpesc/public/docDisplay?docId=a00101273en_us

    ------------------------------
    Alvin Castro
    ------------------------------



  • 3.  RE: IoT BLE advertisement reception

    Posted Mar 29, 2021 01:08 PM
    > you can set an AP to act as an Instant Access Point (IAP), which wouldn't necessarily need a gateway to function.

    Does this mean I could ask my IT department to borrow an access point and they could just set it into IAP mode so I could use it standalone?  Does it require a different firmware load, or is it just a configuration change?

    ------------------------------
    Christopher Piggott
    ------------------------------



  • 4.  RE: IoT BLE advertisement reception

    EMPLOYEE
    Posted Mar 29, 2021 04:05 PM
    Hi Chris,

    To begin with, each Aruba AP(all 5xx & 3xx series APs and 2xx series APs by attaching external USB dongles) listen to BLE devices in the environment once you configure and enable the radio profile on the controllers. You can then configure 'Transport Streams' on the controllers to transport the IoT/BLE telemetry data to a websocket server of your choice.
    Currently we do support HTTP/HTTPS servers as well to send the telemetry data to, but they are soon to be deprecated. So we recommend using websocket only.

    It is good that in your case, the BLE endpoints are going to be iBeacons since we support these and all the attributes like UUID, major/minor, RSSI, battery level etc can be understood and forwarded fully by Aruba controllers.

    All the northbound communication towards the websocket happens through the controllers and not through individual APs.

    We have dedicated guide for JSON and Protobuf specifications:
    https://asp.arubanetworks.com/downloads;search=iot

    For filtering, you can set filters in the Transport Streams to just listen to iBeacons and ignore rest of the BLE devices. There are a few other filters based on RSSI values, distance and movement as well. You can also set UUID and major/minor values.

    AP22 is Aruba Instant On AP which doesn't support IoT features. If you can grab one of the 5xx series APs or 3xx series IAP, then you could configure them as standalone AP and test the IoT features independently without them being tied to Campus or Central.

    Refer to the 'IoT Basic Setup Guide' to configure the radio and transport profiles on your Aruba device:
    https://asp.arubanetworks.com/downloads;search=iot

    ------------------------------
    Nikunj Naresh Shah
    ------------------------------



  • 5.  RE: IoT BLE advertisement reception

    Posted Mar 29, 2021 06:01 PM
    Thanks, that is all extremely helpful!!!  One follow up question to begin with:

    Currently we do support HTTP/HTTPS servers as well to send the telemetry data to, but they are soon to be deprecated. So we recommend using websocket only.

    OK that's fair.  I can't get to some of those documents because I don't have a support contract (others at my university do, though, so I'll have to ask them).  However, I gather that the websocket interface uses protobuf format exclusively.  That isn't a problem for me.  What's more of a problem is how long-lived these websocket connections live.  Do the devices stay connected indefinitely?  If that's the case, then from a scaling perspective I'll have to have a websocket able to handle 'n' concurrent connections - either 7500 (if it's per AP) or num_controllers (which I don't know what that number is).  Initially it seemed to me that having a large number of controllers sending me updates every 300 or 600 seconds is only a few connections per second (average) which is a pretty low overhead server.  I'm wondering what the server load implications (especially number of concurrent connections) are using websockets.





    ------------------------------
    Christopher Piggott
    ------------------------------



  • 6.  RE: IoT BLE advertisement reception

    EMPLOYEE
    Posted Mar 31, 2021 04:16 AM
    Hi Chris,

    I have created some documentation for a small IoT-Utilities Android App you could use to learn and get used to the Aruba IoT integrations capabilities.
    This also includes a chapter about Aruba IoT concepts that might help you.

    Starting with AOS/Instant 8.8 we add some apHealthUpdate messages though the web socket that keep the connection up. They are sent every 120 s if I am not wrong. As previously stated every Aruba controller configured with an iot transport profile will establish a web socket tunnel. In an Aruba Instant setup every AP will establish a web socket tunnel. There is also an option to use an HTTP web proxy server for the server connectivity.

    If you use BLE telemetry the traffic should be moderate, depending on the reporting interval you set. BLE telemetry reports are a summary of what every APs see. This can be even further filtered using device class filter or even per UUID and so on when using iBeacon.
    Using BLE data forwarding is another story, here all BLE advertisements and scan responses are forwarded. This creates much more traffic depending on your environment. But this can also be filtered by device class.

    I think you don't need a service contract to get to the Aruba IoT server API documents and the protobuf schema. You just need to register an HPE Passport account to sign in to the Aruba Support Portal. Let us know if you can't access the protobuf schema with an HPE passport account.

    I hope that helps.

    Regards,

    Jens

    ------------------------------
    Jens Fluegel
    ------------------------------



  • 7.  RE: IoT BLE advertisement reception