#iot hackathon fever!

The first Internet of Things Hackathon is taking place shortly (May 25th) between Milan and Trento, Italy. The event is part of the Hack Reality 2 organised by WhyMCA.

The #iot hackathon is quite special because:

1) It is the first Internet of Things hackathon

2) It is the first hackathon to take place in two different geographical locations at the same time

3) In Trento, It will take place in  bar!

Topics of interest for projects include Web & Mobile, Automotive, Internet of Things, Wearable Devices, Smart Cities, M-Payments, Home Automation.

Participants (need to register here) will have the opportunity to play with Flyport WiFi modules by openPicus, dozens of sensors and actuators from Seeedstudio, the Cloud service provided by IoTango and build creative projects that will communicate over the Internet. The main goal is to motivate people from Milan and Trento to work together for building iot hacks. Great prizes for the winning teams include 750€, 500€ and 320Amazon gift cards!

Register here for the event!

More info.

QS Europe 2013: QS + IoT + Motivation

QuantifiedSelf Europe conference is taking place this May (11-12) in Amsterdam. It is a big community meeting for makers and users interested in self-tracking tools and technologies! The program consists of talks and breakout sessions.

I will be chairing the ‘Internet of Things’ breakout session. The main objective is to drive discussions with the audience about IoT and QS convergence. Some of the topics to be included for discussion are listed here:

  • IoT basics
  • How IoT drives self-tracking
  • How can QS be improved though IoT and IoS
  • IoT driving motivation for better tracking

Any thoughts on material to include for discussion are more than welcomed. Please drop a message or send an email.

I am also running a short survey about QS, IoT and motivation here. Any input is welcomed, results will be presented at the conference and on this blog as well.

I will also present the results from my own self-tracking experiment and especially how the Fitbit hack has helped me to reach my goals.

Btw, the blog post about the Fitbit hack has reached great visibility. The hack has been already featured in articles on The Huffington Post and The Wall Street Journal!


IoT Day talk: IoT basics, current status, future

IoT Day has passed and from what it looks it was a great success! More than 18 events have been organised allover the world, with great talks, demos and big participation (judging from the tweets and the photos posted!).

I have been in Trento, Italy, presenting at the first IoTItaly event. Organisation was made by CREATE-NET and we had a great group of speakers (including Adrian McEwen from GNL team, Claudio Carnevali from openPicus, Matteo Collina, WhyMCA hackathon organisers, etc.).

About 50-60 people have attended and led to great discussions about IoT, technical aspects, business exploitation and the future of IoT!

My presentation about IoT basics, current status and the future can be found here:


More information about the event here.


Preparing for the 2013 Internet of Things Day

On April 9th we ‘celebrate’ the Internet of Things Day! Established last year for the first time, the International IoT Day proved to be a great success with many contributions from IoT fans.

This year we hope to have even more contributions and events around the world. You don’t need necessary to make a hacking event or make a workshop (though it sounds very challenging), a small-large gathering of people and discussing about IoT can do great for an event!

You can find more information about events on 2012 IoT day here, as well as register your event for 2013 IoT Day here. Website brought by The Council and Postscapes.

I am preparing a workshop event as well, it will be lively broadcasted (details will follow) and people will be able to participate online. Drop me a comment if you are interested into participating and/or have an idea to discuss during the event!

Combining QuantifiedSelf with IoT for effective motivation

This post is about combining QS (a Fitbit activity tracker), with IoT (using activity information retrieved online to control a Belkin Wemo switch) for effective motivation.

Let me explain briefly how and why:

I got this Fitbit tracker mostly out of curiosity for it as a gadget, and for experimenting with the Fitbit API. Initially I have been using it quite often – and that made me walk more and climb up more stairs than usual, to meet my daily goals and earn some badges – but quickly I got bored of it and started neglecting its usage and became less active.

So then I thought, badges earning is not working for me,  there must be a way to force myself to become more active. There are great platforms for motivating people to keep healthy and exercise more, but obviously in my case I needed something more drastic. At the same time I had been playing with a Belkin Wemo switch and have found a way (using some good online resources) to control it outside the iOS app. 

And this is how I came up with the idea of ‘punishing’ myself when I am not active enough by turning off automatically the switch that powers something important. I don’t watch TV, and I thought first of the DSL router but then there would be no connection to the Wemo to turn it back on. So I thought of connecting the fridge to the Wemo switch.

All I needed then was a service to monitor my Fitbit account and my activity that would also turn on/off the switch. For this I built a webscript that checks my daily activity through the Fitbit API. Every evening it will check for the total steps tracked by the Fitbit device. If my activity is below some threshold it gives me a warning email first. Then it checks again within 1 hour and if the threshold is still not met it shuts down the Wemo. It will recheck every 1 hour then and will turn on the switch in case I have made enough steps!

I have used webscript.io because Lua is very simple and webscript guys have done great work integrating libraries that simplify oauth authentication and communication over HTTP. Regarding the communication with the Wemo switch there are two options. Basically, the Wemo talks uPnP (though the service XML is not properly formatted and therefore no uPnP app is able to detect it within your network), so all it takes it to make a POST request to the Wemo IP and port 49153 sending the appropriate XML service file as part of the request data.

Update: This is how actually a direct request to Wemo switch looks like (in Lua code):

function controlWemo(status, port)
local response = http.request {
url = '',
method = 'POST',
headers = {
SOAPACTION = '"urn:Belkin:service:basicevent:1#SetBinaryState"'
data = '<!--?xml version="1.0" encoding="utf-8"?-->'..status..''

return response

One option is to send a request directly to the switch using dyndns and port forwarding at the home router or (more preferably for me) use a Pub/Sub service like Pusher and a device at the local network (like a powerplug, a beagleboard or a RaspberryPi) that listens for events from Pusher and sends the command to the Wemo switch.

The network communication looks like the following:

To read data using the Fitbit API, user must authorise the web application (webscript in this case). The API is based on OAuth for authenticating external applications and the webscript url must be also registered as a Fitbit application. When registering your Fitbit application, you receive an app token and secret (to be used in your code). More information about the Fitbit API can be found here.

Based on the Twitter sample webscript that demonstrates usage of Oauth, I have created 2 scripts. The first one directs to the Fitbit site for granting access to the second script that retrieves my activity data and talks to Wemo switch. The code for the first one is the following:

local CONSUMERTOKEN = '39-------------0e' --your apps Fitbit token
local CONSUMERSECRET = 'bf6b---------------3cb' --your apps Fitbit secrer

-- get a request token
local response = http.request {
url = 'http://api.fitbit.com/oauth/request_token',
params = { oauth_callback =
'http://fitbit.webscript.io/callback' },
auth = { oauth = {
consumertoken = CONSUMERTOKEN,
consumersecret = CONSUMERSECRET

local ret = http.qsparse(response.content)

-- store the token's secret for use in the callback
storage['secret:'..ret.oauth_token] = ret.oauth_token_secret

-- redirect the user to login at Fitbit
return 302, '', {

The second webscript is the callback to the previous one (to my example http://fitbit.webscript.io/callback) which is the endpoint you have registered to Fitbit as the URL the user is redirected to when successfully authorised the webscript. The code for both scripts can be found here.

This is what I consider a true IoT example. It involves two different devices from different vendors, exchanging information and acting smartly (well not very smartly but it’s a start) for my benefit.

Cosm.com Android logger update

The Cosm.com Android logger app has been updated. There have been major bug fixes that allow better functionality, proper feed updates and eliminate crashes devices. So, simply install the new app, type in your Feed ID, use the QR scanner to enter a Cosm key (make sure it has update and create rights), select a time interval and watch your mobile phone’s resources being logged on the Cloud!












Special thanks to ‘sci.fi’ for helping with the bugs, beta testing and suggesting future features!

Using the TI BLE SensorTag

I just received my Bluetooth Low Energy SensorTag from TI and wanted to share my experience with it. Overall it looks like a great sensing device coming at an amazing price (25$ – free shipping- probably it is more of a promotion than an actual product).

SensorTag features 6 sensors in total (temperature, humidity, pressure, accelerometer, gyroscope and magnetometer) and it comes with a single cell coin cell battery (CR2032). Specs mention a  quiescent current consumption of 8uA, allowing years of battery life!

The device itself is quite small allowing it to be carried in your pocket.











Setting it up and pairing it with an iPhone device is easy and straightforward.

TI provides a free iOS app (TI BLE Sensor Tag) which visualizes on your phone all the sensor information polled form the device. However connecting some times (or most of the times actually) requires that the device is waken from the sleep mode by clicking on the side button. I find this pretty annoying since you cannot rely on polling data from the device at long intervals (longer than its ‘active connection’ period is set to), but that’s probably a general issue with most Bluetooth devices. On the good side, once you click the wake-up button on SensorTag, the app finds the SensorTag and connects to it right away.

Here are some screenshots form the TI app:











An interesting (free) 3rd-party app that utilizes the TI SensorTag is ‘Comfort Guide – SENSiBLE’ by Sensirion AG (btw SenorTag is based on Sensirion SHT21 humidity sensor), that combines humidity and temperature data illustrating environmental conditions to the user in an understandable manner:








Wonder how you can write your own iOS app to read sensor data? No problem, the TI app includes also its own code as a sample of how to connect with SensorTag and read data from the available sensors (this one goes beyond open source, it’s integrated open source, or embedded open source!!):


10 key questions – and some answers – about IoT

Quoting from here, answers express my own opinion.

“The IoT SIG recently ran a thought leadership event on the theme of ‘People-centred design and the Internet of Things’. The group identified ten key questions for the future of IoT which were explored and developed through the course of the day.

A full report of the meeting can be found here.

Ten key questions for the future of the IoT

  1. How can we establish and negotiate technological priorities? In a world of limited bandwidth, the growth in connectivity will challenge our current networks capacity to cope with data. We need a better way of understanding which services should be prioritised –how can we make sure vital medical data isn’t slowed by audiences streaming Eastenders? Answer: There is huge research behind prioritisation and QoS, some of it already integrated in coming standards like 6LoWPAN and CoAP, we have the technology, we need to identify the needs and deploy it appropriately. When we reach the point that medical data is streamed together with movie (as an example) data from the same property, then existing solutions (hopefully) will emerge. 
  2. How can we take a lifelong perspective on services and objects? We currently design for beginnings – getting people connected and tied into a system. How can we make sure people end relationships with service providers as easily? As more big-ticket items become connected (cars, fridges etc) and are sold on to new owners and users, this becomes increasingly important. Answer: Time will show; user needs will drive eventually the requirements and design specifications of products and services!
  3. How can we balance aspirations for the IoT with the reality of what it will be able to deliver? There are strong tensions between the aspirations and our vision of a technological future and the pragmatics of our everyday lives. There is a mismatch between a consumer’s ideal world and the lived world. Answer: Yes it is difficult to deal with that, though most of the IoT enthusiasts can deal with technical glitches, less interoperability and unfriendly interfaces (like always discovering a bluetooth device before using it). Rest of the users (i.e. the majority) will probably receive and use products and services that have overcome such issues). 
  4. Who represents who? Who stands up for, educates, represents and lobbies for people using the IoT or connected products? Is this the role of people-centred designers? Answer: Good question, too many stakeholders in the beginning, few will survive..
  5. Who are the people using it? How do we define the communities, circles or tribes that use each product and their relationship to each other? Answer: That’s a wrong I think, IoT should not be intended for a specific group of users, it should be able to penetrate every market and every aspect of life.
  6. What can we learn about the IoT from taking a historical analysis of the web? How can technological change inform technological future? Answer: Past cannot teach a lot, so many different circumstances, present can only show some different perspective of things.
  7. What is value of an agile approach? How can rapid prototyping or lean approaches help us to drive new product developments and how do they fit with a people-centred methodology. How can government nurture disruption, and is it their role? Answer: Rapid prototyping and lean approaches will at least demonstrate the use cases of IoT, facilitate initial distribution of devices and services, assist in collecting initial feedback from users and help formalize IoT requirements for success!
  8. How can we track “Things” and what will this tell us about their use? Answer: Tracking is not difficult, interpreting data was, is and will be in the near future the main challenge. Semantics is the answer, but we are a bit far from a good solution.
  9. What  are the new interfaces and dashboards that will help people to interact with the IoT? How important will the distinction be between things that have a screen and don’t have a screen? Answer: What is really the difference? Information dissemination matters, and web is ubiquitous! Interfaces will surely change to accommodate processed information and controls!
  10. Do we create value and value chains that reward creators or just users? We know that established value chains are being disrupted. Services like Fixmytransport.com have become successful by identifying new consumer needs. We should ask, where’s the pain? But how to ensure that creators are rewarded for these developments. “