Monday, March 23, 2015

Smart Helmet – Using Eclipse Kura

We are more from application development using eclipse frameworks [RCP, EMF, GEF etc]. This was our very first venture in field of embed technologies and IoT. During my client visit I got opportunity to attend Eclipse Conference – Ludwigsberg Germany  where in I came to know about Iot and also very much impressed by presentation of Iot from Dr Andy Stanford-Clark.
When we came to know about Iot challenge we thought it would be a great opportunity to learn in field of Iot and started with ground ‘0’.


Keeping this challenge in mind, we shortlisted few problems in the field of traffic management and accidents. In India the two wheeler accidents are at high rate which has resulted in loss of human life due to lack of immediate response.
According to a survey 1,39,091 persons were killed during the year 2012, out of which 23% constituted for Two wheeler related incidents

There are multiple solutions to address the problem, currently we are presenting one such possible approach using the framework and technologies of Eclipse Iot .


The objective of the solution is to detect impact of the accident or fall occurred using the accelerometer mounted on the helmet. This information will be transmitted  to the receiver via wireless to Raspberry mounted or installed in the vehicle, which would process data to determine and notify the incident to user [via mobile  or  buzzer alert]. If there is no response from the user within specified time frame it would collect the current Geo location using the GPS receiver and  processes it further to identify the nearest help center [eg hospital]  and sends the notification via email or tweet and an alert is sent to the traffic grid for traffic diversion

Overview of Smart Helmet

Overview

Illustration of Smart helmet work flow

workflow

HardWare Components Used :

Framework and Technology Used : 

  • Eclipse Kura
  • Eclipse Paho – Client [Javascript and Andriod]
  • MQTT
  • Pi4J
  • Python Groove
  • Twitter - Dev
Note : Due to hardware constraint, the feature is constructed by connecting accelerometer to raspberry pi directly not via RFID

Technical Overview

The setup of hardware and software is inspired by the Iot Greenhouse tutorial

Hardware Configuration

Grove Pi is mounted on Raspberry Pi



connected hardware with actuators and sensors


Hardware setup 
  • Connect accelerometer to Raspberry Pi via Grove Pi [I2C]
  • Connect USB based GPS receiver to Raspberry Pi
  • Connect the Grove buzzer to Pi [GPIO2]

Software Realization for the stated solution

Solution is realized by different OSGI bundles using Eclipse Kura framework
  • Bundle responsible for actuator and sensor tracking in our case is accelerometer and buzzer
  • Bundle responsible with scheduler for smart helmet tracking based on different events
    • Accepts the data from osgi configurable options like  profiling , impact deviation and search area range
    • Based on push event from client, tracking is started  [starts vehicle impact monitoring]
    • Impact detection  [ checks  for the variation in accelerometer value .For the demo purpose  check is performed on the previous and current value for any deviation, there are lot algorithm available to detect the real world impact ]
    • In case of impact detected notification is sent to Kura data service
    • Notification object is decorated with latitude, longitude and altitude of current impacted location
  • Bundle  responsible to send and receive service using eclipse kura data service 
    • Service collects the smart vehicle configuration data profiling , impact deviation and search area range and sends to tracker
    • Collects the message from the subscribed topic and filters. Based on the filtered topic it triggers the actuator for tracking via tracker bundle
    • Publishes the notification/alert message to client
Smart Helmet configuration via Eclipse Kura providing required settings

Smart helmet settings

Glimpse of smart helmet operations

GPS output

Acquiring Geo location Data

Accelerometer data and Impact information logged by KURA

Sensor data logged

Publish of events via Kura data service

publish of topics to clients

Receive of events in Eclipse Paho base clients

POC was created to verify the send and receive of the events from different clients using Eclipse Paho

MQTT - Javascript

javascript client


MQTT - Android




To conclude it was good learning of various technologies of  Iot, this is just a POC which we       had to realize with time and project constraints. This has lot of scope for futhur enhancement.


About Us

Myself "Byre Gowda" and "Pavan Nagaraja" would like to convey our gratitude for our organization on providing an opportunity to work on Iot.