mike

# Aug 15 2011 - 1:08 AM

Hey Kegbotters!

As you probably don't know, making it easier to get going with Kegbot has been a big goal of mine for the past few years. It still takes way too much effort to get a Kegbot online: you need to (1) assemble hardware, (2) bring up a kegbot backend, and (3) build and run the kegbot core/frontend.

I'd like to give you an update on each of these three areas.

Assembling Hardware
Geoff and I have put together an Arduino shield, and on Monday I should receive the first large production batch of them. A few of us have tested these (along with their breakout boards) for the past few months, and trust me, it makes it easier than ever to wire things up.

Of course, it will still take some effort to get that board assembled -- but Kegbot is a DIY/hobby project at its heart, and I think this makes for a great balance (and makes that first successful pour that much more satisfying..) In the very short term I'll sell these directly to interested kegbotters (more details real soon), but in the long term I'm looking to set up a one-stop Kegbot parts shop.

Running a Backend
This hasn't visibly improved in a while, but there have been several subtle changes under the hood in support of it. Most significantly, Kegbot now has a JSON/REST API for recording drinks and various other operations. This API effectively decouples the core from its backend, and is stabilizing rapidly.

Old-timers will know we've always wanted to do "global leaderboards" and other fun features that only a centralized reporting system could provide. While there's nothing to announce yet, I'm experimenting with ways to run a single Kegbot backend as a hosted "software as a service"-style site. In addition to making those sort of global stats and information sharing possible, this would provide a turnkey kegbot site to those who have no desire to play sysadmin. More on this soon..

Running a Kegbot Core
The brains of running a kegbot, it hasn't evolved much in the past 5 or so years. Character LCDs were cool back in the day, but in the age of the iPhone and iPad it just doesn't cut it any more.

The writing has been on the wall for a long time (see this post from '09): Kegbot should be ported to cheap, portable touchscreen devices. I credit and tip my hat to the Yelp dudes and their iPad "Kegmate" proof-of-concept from last summer with really kickstarting this one: there's just so much potential for cool stuff with an all-in-one touch interface device.

As time has allowed over the past many months, I've been building up a complete pykeg replacement as an Android app. This app functions as a basic data viewer, but its real job is talking to kegboard and processing and reporting pours.

I threw together a quick video preview, which you can view here:

http://www.youtube.com/watch?v=m4NNgrek8sc

My apologies for the poor camerawork; I had several test beers! You can see the new hardware, a few new features, and of course the app itself in that video.

The app still needs a little more testing and polish before I feel ready to release it (and the source), but I'm conducting a small private beta right now. Longer term, the python core will be deprecated in favor of this Java implementation. There's a zillion things I'd love to implement and just haven't had time for, so I'm excited about where this can go.

Well, that's about it for now. As usual I'd love to hear your ideas. Thanks for bearing with me! Cheers!
mike

PS: My internet access is going to be sporadic for the next couple of weeks, so apologies in advance if I am absent.

Edited by mike (Aug. 15, 2011 01:32:31)






goliathdrakken

# Aug 15 2011 - 1:08 PM

If the plan is to depreciate the pykeg core, does that mean that a USB host Android tablet will be required to run the kegbot core? I love the idea of using a tablet as a front end to the kegbot, however they are a pricey investment to make. It would be nice if the tablet doesn't have to be dedicated to kegbot use. Is the tablet serving the database in this design or is it served remotely? If remotely it would be nice to make the kegboard network capable, and able to communicate directly to the database, and eliminated the need for the tablet as a middle man. This would allow the tablet to be used solely as a front end. Then the tablet can be used elsewhere while still keeping the kegbot functional. Thoughts?

On another note, love the app. Looking forward to its release. Out of curiosity, is it developed using compatibility fragments so it will function on phones as well, with limited functionality of course?




mike

# Aug 15 2011 - 1:08 PM

goliathdrakken
If the plan is to depreciate the pykeg core, does that mean that a USB host Android tablet will be required to run the kegbot core?


Nope! Deprecate is a little strong; "maintenance mode" is more what I mean. I'll still maintain it, but I don't expect to introduce major new features myself (contributions are still welcome, etc). In a sense this has been the case for some time already..

And, thanks to the web API these needn't be the only core implementations. It'd be possible to write a core in <language of choice> or for <device of choice>, or to embed one on an ethernet-capable microcontroller..

goliathdrakken
It would be nice if the tablet doesn't have to be dedicated to kegbot use.


Understandable. I'm pretty certain that the cost of a capable tablet is dropping very rapidly, such that dedicating a device to your kegbot becomes more and more attractive. Especially when you consider all the other stuff you *don't* need to buy as a result: an LCD, some sort of ethernet device, amp/speakers if you want to use the sound features, webcam, etc. (Hey, mobile devices even have a built-in battery backup -- don't let the drinking stop because the power went out!)

It is true, the "lead" Android devices today command a slight premium today (eg $500 for a Xoom or Galaxy 10.1); but they will depreciate rapidly. Add scores of second-tier clones from the likes of Archos and others -- just visit xda-developers for an idea -- and Android becomes a very cheap platform for this sort of thing.

goliathdrakken
If remotely it would be nice to make the kegboard network capable, and able to communicate directly to the database, and eliminated the need for the tablet as a middle man.


People have wondered about this sort of design before (check the archives for consideration back in 2005), but this is a conscious design decision: I'm partial to the "dumb controller" design which makes the role of the specialized hardware as minimal and policy-free as possible.

For one, the development cycle is better when the richer features are done off-device. Things like authenticating to the backend, caching of drink data when the connection is down, policies for cutting off access, etc, are all more easily accomplished (and tested) outside of microcontroller land. (Try doing SSL on an arduino..)

Second, last I checked ethernet added $20+ to the BOM of a simple microcontroller board. Sure, a $80 board is still cheaper than a $200 tablet -- but if you planned on using a tablet for a fancy touchscreen UI anyway (cf kegdroid and kegmate), the cost is already sunk and effectively $0

That's just my preference, though, and I can understand the attraction of an all-in-one device. I'd love to see someone pull off a cheaper ethernet-only kegboard with the web API. I haven't turned a patch away yet

goliathdrakken
On another note, love the app. Looking forward to its release. Out of curiosity, is it developed using compatibility fragments so it will function on phones as well, with limited functionality of course?


Thanks! Good question -- yes (mostly). All of the main blocks are fragments, though I've not yet attempted to use it on a pre-Honeycomb device.. Definitely something I'd love to see happen. No reason you shouldn't be able to use this app to build a cheap core with a used phone, or just as a data browser..

cheers,
mike




hamachi

# Aug 15 2011 - 5:08 PM

awesome! can't wait to see this published. it'll be a perfect fit into what I'm thinking of doing




goliathdrakken

# Aug 15 2011 - 8:08 PM

mike
I'd love to see someone pull off a cheaper ethernet-only kegboard with the web API. I haven't turned a patch away yet

I've been meaning to get myself an arduino ethernet shield. Seems like a fun project to attempt. If only sparkfun did't have them backordered.

mike
Thanks! Good question -- yes (mostly). All of the main blocks are fragments, though I've not yet attempted to use it on a pre-Honeycomb device.. Definitely something I'd love to see happen. No reason you shouldn't be able to use this app to build a cheap core with a used phone, or just as a data browser..

Awesome, looking forward to the release then. I've been doing a lot of work with some apps that are phone and tablet friendly. Definitely want to make at least a phone data browser out of it.




wifigod

# Aug 16 2011 - 9:08 AM

Again, not cheap, but getting closer: http://www.androidtabletfanatic.com/android-tablet-news/pandigitals-cheap-nova-gingerbread-tablet-now-available-at-best-buy-for-170/

Might have to play with one next time I'm @ Best Buy. Can do a quick review on one if anybody's interested.....




goliathdrakken

# Aug 16 2011 - 10:08 AM

wifigod
Might have to play with one next time I'm @ Best Buy. Can do a quick review on one if anybody's interested.....


The first problem I see with this tablet is the lack of a USB host port. Thus it will not be able to provide a connection to the kegboard.

On second thought, it would be nice to make a kegboard that works on the Arduino ADK. Then the only requirement for the Android device is that it runs 2.3.4 or higher, or (3.1 or higher for tablets). This would allow for use of tablets that aren't $500.




wifigod

# Aug 16 2011 - 12:08 PM

goliathdrakken

The first problem I see with this tablet is the lack of a USB host port. Thus it will not be able to provide a connection to the kegboard.


Good Catch! Didn't even think to look, just assumed. :-(

goliathdrakken

On second thought, it would be nice to make a kegboard that works on the Arduino ADK. Then the only requirement for the Android device is that it runs 2.3.4 or higher, or (3.1 or higher for tablets). This would allow for use of tablets that aren't $500.


That does sound neat, but the ADK is $90, plus you still need another $80 for the shield (which I assume would still be compatible? I haven't used a Mega yet, so I'm not 100% on that), PLUS an android (that you'd have to keep connected to the ADK while using the keg) device; it just starts to get expensive and the requirements go up a decent amount.

What could be neat is having his code (BTW, Mike, amazingly cool of you to continue to offer the source on the 'droid app!) be one fork; if there's interest, keep developing the current fork; AND if there's interest from developers, start developing an ADK fork. If that were to happen, it would be my assumption that we would eventually consolidate the "core" DB stuff to either a web service and/or installable server pack (if you don't want external hosting or make your own tweaks). Then we can have all of the front end apps we desire, all using the same JSON/REST feeds for the information to send/receive either by cable, wifi, or ethernet.

mike
The app still needs a little more testing and polish before I feel ready to release it (and the source), but I'm conducting a small private beta right now. Longer term, the python core will be deprecated in favor of this Java implementation. There's a zillion things I'd love to implement and just haven't had time for, so I'm excited about where this can go.


Couple more questions/comments: first, app looks pretty slick, I do like the beer presentation and the feed (assuming, didn't zoom video) on the right! Second, do you know anything about SL4A? It allows for scripting (believe Python is the 'standard') and direct access to some libraries. Not sure if it would make the conversion easier, or if a rewrite was probably needed anyway. Basically, I hate Java and would love to see parts of it avoided if possible, lol. Meh, perhaps it's time for me to download the latest Eclipse and resurrect my CS160 Java 'skills' from 6 years ago. Lastly, are there any hard set requirements? You mentioned you haven't tested anything pre-honeycomb, but it sounded like at least Gingerbread was a go; any native resolution it's being built around? Some tablets are 800x600, some are 1024x768, the Zoom is 1280x800 I believe. Sorry if I'm naive, on the "fragments" nomenclature, I've never even seen the ADK development site, let alone looked at the spec. (iOS/Apple user/owner....but definitely always looking to expand my horizons)

And finally, anybody heard of this one? The E-Lectio 7: http://www.amazon.com/gp/product/B004ZW5PKY/ It has OTG, but the display is an abysmal 800x480. It is now my mission to find a sub-$200 tablet that would fit perfect with this new Kegbot I'm planning out.






goliathdrakken

# Aug 16 2011 - 1:08 PM

wifigod
That does sound neat, but the ADK is $90, plus you still need another $80 for the shield (which I assume would still be compatible? I haven't used a Mega yet, so I'm not 100% on that), PLUS an android (that you'd have to keep connected to the ADK while using the keg) device; it just starts to get expensive and the requirements go up a decent amount.


Actually the link I posted is an all in one package, it is a mega with the USB host built in, so if you want to do Android accessory prototyping using an Arudino, its definitely the way to go.




wifigod

# Aug 16 2011 - 5:08 PM

goliathdrakken

Actually the link I posted is an all in one package, it is a mega with the USB host built in, so if you want to do Android accessory prototyping using an Arudino, its definitely the way to go.


I was assuming the shield would still be needed (as it's currently needed WITH an Arduino, which could be the Mega), is that not the case? The parts in the kegboard-mini list didn't seem like they were replacing the Arduino at all, so I assumed it was the Arduino + $60 in parts + $20ish? for the board to populate the parts with....that then stacks onto the arduino. Perhaps I've assumed wrong on how the kegboard-mini and kegboard-coasters are being utilized. I'll have to read more forum posts (I don't think they're documented in the wiki or documentation beyond the parts lists).

Am I just confoozled?

Edited by wifigod (Aug. 16, 2011 17:50:29)