One of the biggest problem in a start-up is ………… coffee shortage, right?
Fortunately, the IoT is now a true reality, and it’s open a new wide range of possibilities.
In this article, I will show you how you can easily create your own connected coffee rack to send you alert when your stock is depleting so that you will never run out of coffee again!
Part 1: Activate your XkitFirst, if you just received your Thinxtra Xkit, you have to activate it on the Sigfox network. Don't worry, it's very simple...
Part 2: Make the scaleThe idea is to built something which looks like that:
The electronic scheme is really simple, just few wires:
Then, to give a voice to this coffee rack, we will plug the Thinxtra Xkit shield onto the Arduino board.
Here is my prototype with the Xkit, the HX711 and the Load Cell:
You can find my code on this GitHub repository: https://github.com/Thinxtra/Connected-Coffee-Rack
Please note that you have to used the HX711 and Xkit libraries:
Part 5: Power supplyTo power supply the Arduino, two possibilities:
- USB Cable
- 9V Battery
Note that you have to adjust the jumper configuration for each case.
I chose IBM Bluemix for this project.
There is a very good tutorial to help you set up your Sigfox callback directly into IBM Bluemix: http://www.thinxtra.com/download/6058/
Callback configuration in the Sigfox backend
My custom payload:
int1::uint:16:little-endian int2::uint:16:little-endian int3::uint:16:little-endian int4::int:16:little-endian
The body (in JSON):
{
"deviceid" : "{device}",
"time" : "{time}",
"snr": "{snr}",
"station":"{station}",
"latitude":"{lat}",
"longitude":"{lng}",
"rssi":"{rssi}",
"avgSnr":"avgSnr",
"seqNumber":"{seqNumber}",
"data": {
"datadecoded" : "0",
"Temperature" : "{customData#int1}",
"Pressure" : "{customData#int2}",
"Photo" : "{customData#int3}",
"Weight" : "{customData#int4}"
}
}
And my final dashboard in IBM Bluemix, integrating some of the other sensors of the Xkit (Temperature and Luminosity here):
You can then set directly in IBM the number of coffee capsules you can have in coffee rack (min/max) and configure some triggers to send e-mail/SMS when the minimum value is reached.
ConclusionAs you can see, it's very simple and fast to create connected things with the Sigfox connectivity and the Thinxtra Xkit. So...Enjoy!
Comments