Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
Showing results for 
Search instead for 
Did you mean: 

What do you need to send data with an iOS device to the IoT Services?






How to Send Data with the IoT Sensor App by itelligence AG?


Create a device model via IoT Service Cockpit

  1. Open the IoT Service Cockpit.

  2. Choose the Message Types tile.

  3. Create a new Message Type by clicking ( + ).

  4. Enter a name, e.g. "iOS Data".

  5. Change the Data Type for timestamp to long.

  6. Enter the following fields depending on the device you are targeting (all fields are optional):

    • iOS Device: timestamp (long) / accX (double) / accY (double) / accZ (double) / altitude (double) / locLat (double) / locLong (double) / pressure (double)

    • TI Sensor Tag: timestamp (long) / sensorGyroX (double) / sensorGyroY (double) / sensorGyroZ (double), sensorAccX (double) / sensorAccY (double) / sensorAccZ (double) / sensorBarometric (double)

    • ublox OLP: timestamp (long) / sensorTemp (double) / sensorGyroX (double) / sensorGyroY (double) / sensorGyroZ (double)

  7. Copy the displayed Message Type ID to your Clipboard.

  8. Go back to the IoT Service Cockpit.

  9. Choose the Device Types tile.

  10. Create a new Device Type by clicking ( + ).

  11. Enter a name, e.g.: "iOSDevice", "TI CC2650" or "OLP 425" (depending on your available hardware).

  12. Add the Message Type that was previously created (here: "iOS Data").

  13. Copy the displayed Device Type ID and Device Registration Token to your Clipboard.


You can now start sending data with a client using the created Message Type and Device Type.


Download and configure IoT Sensor App


  1. Install on your mobile device: IoTSensor on the App Store (iOS only)

  2. Configure the app with by calling the following custom URL on your device:

    • iot-create://&/accountName&/[Account ID]&/name&/[Connection Name]&/dataCenter&/[Data Center]&/deviceName&/[Device Name]&/deviceTypeID&/[Device Type ID]&/deviceReg&/[Device Registration Token]&/messageTypeID&/[Message Type ID]

    • Parameters:

      • [Account ID] => your account ID, e.g., "p1234567trail" (remark: not your user name)

      • [Data Center] => your account data center, e.g., "hanatrial" / "hana" / "us1.hana" / "us2.hana" / "ap1.hana"

      • [Connection Name] => any name for a connection, e.g., "myConnection"

      • [Device Name] => any name for the device, e.g., "iPhone Michael" / "Sensor Tag 1"

      • [Device Type ID] => the Device Type ID you copied previously to your clipboard

      • [Device Registration Token] => the Device Registration Token you copied previously to your clipboard

      • [Message Type ID] => the Message Type ID you copied previously to your clipboard

    • Sample: iot-create://&/accountName&/p000000trial&/name&/myTrialConnection&/dataCenter&/hanatrial&/deviceName&/iPhoneMichael&/deviceTypeID&/f807b43597e44cf1fc4b&/deviceReg&/ce89c5cfe7fdb25b381eff51136b97&/messageTypeID&/9208dd4b8cc54bc1fb1b

  3. Once the custom URL is launched the app starts and account will be configured.

  4. Press on Registration.

  5. The "Device" gets registered and is ready to send Data. Press OK.

  6. The "Connection" is now coloured red.


Select Device and Send Data


  1. Press on Sensor.

  2. Select a device (vor BLE device connection press refresh).

  3. The device is not connect. Go back by pressing Select Source.

  4. Press Back. (Sensor and Connection are coloured red.)

  5. Press Record Button.

  6. Data is sent according to sending interval (values that are not defined in the message type are ignored.)


Where do I see my Incoming Data?


IoT Message Management Cockpit


You can see your incoming data immediately via the MMS Cockpit.

  1. Open the IoT Service Cockpit.

  2. Choose the Send and view messages, or perform other actions tile. (The MMS Cockpit opens.)

  3. Choose the Display stored messages tile. (All tables of incoming data are listed.)

  4. Select the table that is named after the Message Type ID that you created previously ("T_IOT_<MESSAGE TYPE ID>").

  5. Press refresh to update the table. The latest values are on top.


OData Consumption


The Message Management Service exposes the tables via OData as well (Documentation: SAP HANA Cloud Platform Internet of Things (IoT) Services).


  1. Open any browser.

  2. Copy the targeted table name to your clipboard. (see previous step)

  3. Enter the URL as follows:

  4. Remove the parameter "?$format=json" in case you want to consume the OData API in application, e.g., HTML5 Applications.


You can now start to consume the data in other applications.



How to write your own iOS App?



Additional Material?



Questions and Feedback?

We highly appreciate your questions or feedback. Please add your comments below.