“Why don’t we make an internet-connected humidor?”
In the summer of 2016, I was in Seoul, Korea, representing myself as a guy who was looking to connect devices to the internet. Coming from the Arduino side of things, I was more of a ‘hardware’ guy. I was introduced to a python programmer, someone on the ‘software’ side, who was interested in similar work. We met at our mutual friend’s cigar bar, Burn in Hal, in Kyungridan, Itaewon. After some smoke and drink, my new friend asked, “why don’t we make an internet-connected humidor?”
It was kind of a joke. But in the end, it wasn’t. It would eventually become the home of my first internet-connected device, the Halmidor. And the technology behind this connected humidor would eventually become the basis for what today is the OhioIoT platform.
But, some other new skills needed to be developed as well:
- circuit design
- 3D printing
- XBee radios
- Raspberry Pi and linux
- lastly (enter the real world), getting my end device to talk to the humidifiers inside the humidor
It became a monster.
It shouldn’t be complicated, right? Don’t add too many features! Just get a basic system working. We did that… And then found out quickly all the reasons why a basic system would not cut it. You could graph your data in the app, so long as you didn’t have to restart your app. You could save your settings in variables, once again, so long as you didn’t restart the app. And so, it was time to write a database… By the way, what if the box lost radio communication? It did. Often. Any changes to the settings needed to be saved to EEPROM, so the setting would restore on boot up. Then we needed to code so that the database, the Halmidor, and app, would always be looking at the same information, no matter where the change was made.
It got worse.
What if an alert was fired, but the app wasn’t open? More databasing was needed to catch the alerts. Well, Was this mission creep? It was supposed to just be proof of concept. But if the user acknowledged getting the alert flag, and cleared it, another alert would fire if the box was still out of spec.
We needed a second flag, and screen functionality, to say whether or not we wanted to resume regular operation. On and on. The point is, it wasn’t really possible to just make an app that could turn something on or off through the internet. In practical reality, this was an operating business that cared about the humidity of its cigars. And the initial joke was demanding serious effort.
What I didn’t know was that in that process, what was forming was the groundwork for what would be the actual OhioIoT system for doing IoT. The problems that I was solving at that time actually apply to almost any other situation where people want to connect hardware to the internet. And so, a platform was being born.
Timeline To Today
August 2016 – The meeting at Burn in Hal where we decided to make a internet-connected humidor.
HALMIDOR: 1st ATTEMPT
September 2016 – It was an Arduino AND an Arduino Mega (yes, two computers to do one job), driving two LCD screens. It measured the humidity and reported it, but we couldn’t get it to talk to the humidifiers. So, I left Korea empty-handed.
Back to hardware development. This included 3D-printing a box. By the way, there is a learning curve in making boxes for your devices.
redesigning the box on AutoCad
preparing for 3D print
Arduino and Pi stuffed in a box… hey, it was my first project.
little red monster
HALMIDOR: 2nd ATTEMPT
April 2017 – This time, we got the box to talk to the humidifiers. But, we needed to work on the timing of pulses to the switch, to make the humidifier think that it should be on or off.
With a box that was talking to a humidifier, we finally had a internet-connected humidor. I went full-time on creating the web app.
Two wires to fire the switch, and two more for the photoresistor, which senses if the box is on.
With a box that was talking to a humidifier, I finally went full-time on creating the web app.
Spent weeks developing this
The Rasbperry Pi wouldn’t connect to the wifi. We never came to understand why. Instead, we started over on a breadboard, and made the Arduino talk to the Raspberry Pi through XBee radios. This allowed us to plug the Raspberry Pi directly into the ethernet upstairs. And, this would become my default starting point for IoT, as it eliminates the hassle of trouble-shooting wifi.
The version we eventually went with. XBee in the back corner, to talk to the Pi upstairs.
What a memorable night – sitting at dinner with my girlfriend and turning the connected humidor on and off – from our dinner table a mile away!
Anyway, more reliability issues surfaced. The box stopped working soon after I left for the U.S.
May 2017 – Back to work in the U.S.
I needed something more rugged than wires plugged into an Arduino. This time I learned about proto boards. And by the way, I recommend you don’t ever go this route. It’s awful. Go straight to PCB CAD design.
Fit check ? .. pass.
let’s fire this bad boy up
More 3D-printing hell.. Make sure you outsource this part for your project.
HALMIDOR: 3rd ATTEMPT
June 2017 – back in Korea
Some on-site tweaking of the code
In a little less than a year, and after three visits to Korea, the connected humidor was in operation.
September 2017 – Back to work in the U.S. again
I discovered the CAD aspect of Fritzing. Well, Fritzing is probably not the last CAD software you want to use, but it might be the first.
No more soldering up the proto boards. Now the wiring could come in the mail, already connected.
And, my 3D-printing skills were improving.
new model on the right – no wires!
June 2018 – Back in Seoul, delivering a younger, more powerful model
The little brother arrived.
Want to Talk to a Box in Korea? Who Doesn’t ?!
If you go to Halmidor.com, you can see the live data streaming from the device inside the bar in Korea. When the humidity is below the defined limits, you know that Hal’s staff has not replenished the water washers. But if it’s running high, you know that the air conditioners, which are sometimes required to dehumidify the air, are not on. Should you see the humidity spike down several times within an hour, you know that they are selling cigars, because someone keeps opening the door and letting in dry air.
I JUST took this screen grab. It’s Thursday night in Seoul (~10:45pm): [[[[ internet-connected humidor ]]]]]
You can see that in the last hour, they got two sales (red arrows). Also, you notice
that the status is “Off”, and the humidity is currently declining (yellow arrows).
You can even talk to the Halmidor without a login. If you click the SpeedTest button, a command will travel from your phone or computer, to a server in New Jersey, to a Raspberry Pi on the 2nd floor of the bar, in Seoul. That RPi will send a radio packet down to the end device inside the humidor (the “Halmidor”) on the first floor. The Arduino inside the Halmidor will acknowledge receiving the packet, which will then make it all the way back and round-trip time will report on your phone or computer. This is typically less than 1/3 of a second. Not bad, eh?
IN THE END
A conversation in a bar, turned into a connected humidor project, which got overly involved, and then resulted in the creation of the system that could eventually be sold to customers. What is selling as OhioIoT today is about 20 times as much code as the Halmidor, but the genetic make up is about 80% shared.
And, although I’m not a big cigar smoker, I certainly like to go back to Burn in Hal and hang out, reminiscing about the battles we went through to create OhioIoT’s first project.