One other way would be to run the following on your Ubuntu PC to create an OCF server exposing the HeartRate BLE sensor: * node.js * iotivity-node (JS bindings) * noble (BLE module for node.js)
And adapt the code we have here [1] to look for the HeartRate GATT service [2] instead of the ESS (Environmental Sensing) service and obviously adjust all characteristics you retrieve. All other OCF clients in the network should then be able to see the HeartRate Sensor. Geoffroy [1] https://github.com/01org/SmartHome-Demo/blob/master/ocf-servers/js-servers/environmental_sensor.js [2] https://www.bluetooth.com/specifications/gatt/viewer?attributeXmlFile=org.bluetooth.service.heart_rate.xml From: iotivity-dev-bounces at lists.iotivity.org [mailto:iotivity-dev-boun...@lists.iotivity.org] On Behalf Of Abhishek Sharma Sent: Thursday, November 10, 2016 5:21 AM To: Sen Senthuran <ssenthuran at extremenetworks.com> Cc: iotivity-dev at lists.iotivity.org Subject: Re: [dev] BTLE sensor - Ubuntu PC Since the BLE sensor is not IoTivity device, SimpleClient can not directly communicate with it. Moreover BLE support for Linux is not maintained in IoTivity from long time. It works fine on Android though. What this means is Simpleserver (Linux) ---BLE----> SimpleClient (Linux) is not guarunteed to work. For your prototype here is what you can do: BLE Sensor ------- BLE -------> SimpleServer (Linux) ------- IP -------> SimpleClient (Linux / Android / Tizen) You will have to modify SimpleServer to simulate Sensor as an IoTivity resource. Also if it is not just a prototype, you will have to follow OCF spec. --------- Original Message --------- Sender : Sen Senthuran <ssenthuran at extremenetworks.com<mailto:ssenthuran at extremenetworks.com>> Date : 2016-11-10 04:57 (GMT+5:30) Title : [dev] BTLE sensor - Ubuntu PC Hi, I am new to IoTivity. Please give any hint of how to connect a BLE sensor from a Linux machine using IoTivity framework. System BLE Heart Rate Sensor (blackbox) Ubuntu 4.4 with bluez 5.37 (can run IoTivity simpleclient/server)