IN THIS ARTICLE
Subscribe to Our Newsletter
Tell me a bit about yourself Magnus; what’s your background?
I’m a Software Developer from Stockholm, Sweden. I’ve been working in the field of data integration since University, a little over 10 years. One of my greatest interests outside of technology is craft beer!
Where did you come up with the idea for an IoT Beer Tap?
We came up with the idea for an IoT beer tap during an after-work outing at our local pub called The Queen’s Head. We were planning to install a draft beer tap in our office canteen, and our Human Resources department demanded that we install a lock on the tap, to prevent misuse.
We realized that we could equip a draft beer tap with a cloud controlled valve that could only be operated by authorized users, and thus the beer bot idea was born. We started dreaming up additional features, e.g. individual volume tracking.
Why did you choose to use PubNub for your project?
We chose PubNub because it was really quick and easy to set up and get working! Its pub/sub pattern is a good abstraction for communicating with a number of different devices without having to care too much about infrastructure. The Beerbot architecture (more below) consists of a growing number of different hardware modules, and communicating through PubNub channels lets us easily add or remove new hardware without too many configuration changes.
What were some challenges you ran into while developing the hardware?
As for hardware challenges, at first we wanted to use really small Arduinos, but we quickly ran into problems with the small number of available GPIO pins. We eventually swapped out all components for larger ESP8266 Arduino with integrated WiFi. We also ran into several complications because some of our hardware components require separate power at different voltages. Because of this increased complexity, the circuits we designed didn’t always work at first.
Did you guys come up with the nickname “Biruino” while you were “testing” out your project?
The nickname Biruino is a portmanteau of biru + Arduino, where biru is Japanese for beer. The invention of this name was definitely influenced by beer consumption.
Can you talk about how the entire project fits together? Where does PubNub fit in?
As for how the system fits together, basically, each Biruino will either read a sensor or control a thing. Biruinos that read sensors will post the sensor values to PubNub (e.g. RFID scanned). These sensor values will be analyzed by our central controller logic, hosted in the cloud.
The central controller logic will act on the sensor value inputs by sending out commands. Biruinos that control things will listen to these commands and perform actions (e.g. open valve).
Here’s an architecture overview from our GitHub:
For example, a prospective beer drinker will swipe a RFID card at the ‘beer bot’, where the RFID biruino will post the UUID to PubNub. The central controller will pick up the UUID and confirm that the UUID is authorized in a user database.
The central controller will then post commands to the valve biruino (to open the valve), the LEDs biruino (to change the LED color to blue, to indicate open state) and the display biruino (to show a personalized welcome message).
When the beer drinker operates the manual tap handle to pour beer, the flow biruino will post the volume poured to the central controller. The central controller will register the volume poured to the current beer drinker’s quota.
Where can developers check out your code and get their drink on?
Developers can check out our code at https://github.com/