ThingseeWiki

Thingsee IoT Platform Technical Documentation

User Tools

Site Tools


howto:receive_iot_data_to_an_azure_iot_hub_endpoint

How to setup Thingsee Azure IoT Hub Connection

Azure is one of the most common data integration points to where Thingsee data is forwarded. To get the data forwarded to an Azure IoT hub, the following information is required

  • Hostname
  • DeviceId
  • SharedAccessKey

Note that the Thingsee Operations behaves as a single device towards Azure IoT Hub so that you need to define a static DeviceId e.g. “thingsee” that is used by every Thingsee gateway and sensor device. The actual device identifier comes within every Thingsee Message (JSON) in a tsmTuid-property.

It is possible to make the integration so that tsmTuid is mapped to DeviceId, but that would require repopulation of all sensor devices to Azure and would make bundled Thingsee Messages a bit trickier to handle.

What we need from you to make the integration happen

Just let us know your Azure IoT Hub connection string

HostName=xxxxxxxx.azure-devices.net;DeviceId=xxxxxxxxxxx;SharedAccessKey=xxxxxxxxxxxxxxx

After that is done, you should start receiving following JSON arrays (example) to you Azure IoT Hub. Please be aware that the messages come always as JSON arrays, and you need to parse the objects preferably by tsmId-field so that you know what properties to expect. See Thingsee Messages.

[
{
    "tsmId": 12101,
    "tsmEv": 10,
    "hall": 0,
    "hallCount": 0,
    "tsmTs": 1520416221,
    "tsmTuid": "XXXX03X2Z80562557",     // unique sensor device id
    "tsmGw": "XXXX00EFS80560445",      // unique gateway device id
}
,
{
    "tsmId": 1110,
    "tsmEv": 10,
    "batl": 100,
    "tsmTs": 1520416221,
    "tsmTuid": "XXXX03X2Z80562557",
    "tsmGw": "XXXX00EFS80560445",
}
,
{
    "tsmId": 12100,
    "tsmEv": 10,
    "airp": 101364.599,
    "lght": 6,
    "temp": 21.3,
    "humd": 21.7,
    "tsmTs": 1520416221,
    "tsmTuid": "XXXX03X2Z80562557",
    "tsmGw": "XXXX00EFS80560445",
}
,
{
    "tsmId": 1111,
    "tsmEv": 10,
    "accx": -1024,
    "accy": 64,
    "accz": -192,
    "tsmTs": 1520416221,
    "tsmTuid": "XXXX03X2Z80562557",
    "tsmGw": "XXXX00EFS80560445",
}
]
This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information
howto/receive_iot_data_to_an_azure_iot_hub_endpoint.txt · Last modified: 2019/02/27 11:48 by tmuvee