Code Monkey home page Code Monkey logo

kegbot-android's Introduction

Kegbot Server

This is Kegbot Server, a backend and web interface for monitoring and managing kegged beverages.

Official repository: https://github.com/Kegbot/kegbot-server/

Quick start

Super quick start instructions:

$ docker-compose up
$ open http://localhost:8000/

For much more detail, see the complete Kegbot Server documentation.

Documentation and Help

Related Projects

  • Kegboard: Firmware and schematics for the Kegbot controller board.
  • Kegbot Android app: Kegtap, the Kegbot manager app for Android.

License

All code is offered under the MIT license, unless otherwise noted. Please see LICENSE.txt for the full license.

kegbot-android's People

Contributors

ddrboxman avatar jeremy-d-miller avatar loganakamatsu avatar mik3y avatar patfreeman avatar rplankenhorn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kegbot-android's Issues

Usernames with period in them cause userlist to not show

We noticed that when we imported our users into the DB, of which all usernames are of the format firstname.lastname, the user list would not show up in the App via the Beer me or by scanning a new token and trying to assign it to a user. Once we removed the usernames with a . in them, the list came up.

We also notice that when trying to manually register a username, it won't allow a period in it there either. Older versions seemed to have let us do this.

Recent users tab is confusing

It's too subtle, a lot of people get confused.

Options:

  1. Just get rid of it. Handle recent drinkers elsewhere (like a shotcut from the home screen event list) as desired.
  2. Blend with all drinkers, eg by sorting or prefixing.

Favoring choice 1 for now.

Warn on USB Permission issue

Deal with the following class of exception by showing an alert:

07-26 13:26:11.375 E/UsbManager( 5769): exception in UsbManager.openDevice
07-26 13:26:11.375 E/UsbManager( 5769): java.lang.SecurityException: User has not given permission to device UsbDevice[mName=/dev/bus/usb/002/002,mVendorId=9025,mProductId=67,mClass=2,mSubclass=0,mProtocol=0,mInterfaces=[Landroid.hardware.usb.UsbInterface;@41b1a0b0]
07-26 13:26:11.375 E/UsbManager( 5769):     at android.os.Parcel.readException(Parcel.java:1425)
07-26 13:26:11.375 E/UsbManager( 5769):     at android.os.Parcel.readException(Parcel.java:1379)
07-26 13:26:11.375 E/UsbManager( 5769):     at android.hardware.usb.IUsbManager$Stub$Proxy.openDevice(IUsbManager.java:366)
07-26 13:26:11.375 E/UsbManager( 5769):     at android.hardware.usb.UsbManager.openDevice(UsbManager.java:265)
07-26 13:26:11.375 E/UsbManager( 5769):     at com.hoho.android.usbserial.driver.UsbSerialProber$2.getDevice(UsbSerialProber.java:64)
07-26 13:26:11.375 E/UsbManager( 5769):     at com.hoho.android.usbserial.driver.UsbSerialProber.acquire(UsbSerialProber.java:115)
07-26 13:26:11.375 E/UsbManager( 5769):     at com.hoho.android.usbserial.driver.UsbSerialProber.acquire(UsbSerialProber.java:95)
07-26 13:26:11.375 E/UsbManager( 5769):     at org.kegbot.core.KegboardManager.acquireSerialDevice(KegboardManager.java:255)
07-26 13:26:11.375 E/UsbManager( 5769):     at org.kegbot.core.KegboardManager.runInBackground(KegboardManager.java:212)
07-26 13:26:11.375 E/UsbManager( 5769):     at org.kegbot.core.BackgroundManager$1.run(BackgroundManager.java:38)
07-26 13:26:11.375 E/UsbManager( 5769):     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
07-26 13:26:11.375 E/UsbManager( 5769):     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
07-26 13:26:11.375 E/UsbManager( 5769):     at java.lang.Thread.run(Thread.java:856)

Add setting to disable camera shutter sound

Currently, I use the same Android tablet for Kegbot as my SqueezePlayer / Jukebox - so it is connected to my multi-room audio which is always on in my basement. Every time a pour occurs, the shutter sound is quite loud if the system is being used to listen to music, and is particularly annoying when ghost pours occur and we're trying to watch TV or a movie.

Calibration + Solenoid Compatibility

As far as I can tell it is not possible to use the tap calibration if you have a solenoid attached to the line (apart from wiring it open while calibrating). My apologies if there is a way that I missed.

Configure kegboard name in app

The app reports meter and sensor data as coming from "kegboard".

For a multi-tap, multi-tablet environment, instances should be differentiated by board name.

Allow dismissing update notification

I opened the app today and it opened a notification that an update was available. Pressing the notification takes you to the market, but no update available. I had to force close Kegbot to get the notification to go away. Would be nice to be able to dismiss it.

Beer Me! Screen Blank

You don't see any users when you hit Beer Me! anymore. You can't pick users now...

Calibration Wizard improvements

I had a couple of ideas as I was testing the flow meter calibration wizard.

  1. Display the test pour ml value in addition to the oz value. I was measuring my pours in a measuring cup which has more accurate marks for ml vs oz.
  2. Be able to set the test pour volume via ml.
  3. A "Reset test pour" button. It'd be nice to be able to pour multiple test pours without having to exit the calibration wizard and re-enter.

Background activity

When I have it set not to run Kegbot Core, there is constant activity going on in the background, most importantly once the app is closed. Looking at the logs about every 5 seconds it looks for a serial device in addition to hitting about 5 api endpoints for data updates. I think this behavior is expected while the app is open, but once closed/paused I think the services should stop. Since its not enabled to run the core, there is no need to be updating in the background, there are no taps connected.

Add Ability to use Remote Camera for Pour Picture

It would be a nice feature to allow the definition of a remote webcam / IP Cam URL to use to take the picture when a pour occurs.

This would allow the use of cameras that capture the person actually ordering the drink on the other side of a bar for instance, or a venue picture during a party.

Blend photos into main UI

Suggestion from IRC:

< moto125> Another thing that i was wishing for was for it to be more picture centric on the frontend. Only people that go to the webpage ever see those pictures

Related to issue #8, we could shuffle though random/recent photos.

Support daydream / screen saver mode

Do something interesting while the screen is idle. Open for suggestions, idea include:

  • Scroll through recent pictures (see issue #21)
  • Scroll through taps/stats (see issue #8)
  • Random beer labels / images
  • (chime in with others)

Thermo Sensor data not being sent from Tablet

So I have a new setup running and the flow meters and relays are all working as they should through the system. However, the thermo data isn't getting back to the server from the tablet.

On my first setup, the thermo sensors auto populated in the DB when the tablet was first setup and ran core... this time it didn't... I hooked the kegboard up to the server and ran pycore and saw all the thermo sensor data coming through so they're working... so then i manually created the Thermo sensors in the DB using the raw names I was seeing in the pycore monitoring (for example kegboard.thermo-da00000400dadc28), but I'm still not getting anything from the tablet running Core to the server. The Thermo logs are empty and obviously no temp is shown on the tablet or the server...

I've tried restarting everything, re-running the setup on the tablet, heck even removing the app completely from the tablet and re-downloading it from the Play store, but it just doesn't want to send the thermo data...

Not sure what to do next... here's the bug report from the Android App if it helps... I notice it's not listing the thermo device under the taps as it has them assigned in the DB, but maybe it's not supposed to... I guess I don't know much about the App.

Kegbot bugreport.

--- Kegbot core ---

Package info:

versionName=1.0 beta 29
versionCode=29
packageName=org.kegbot.app
installTime=Fri Mar 08 10:43:08 CST 2013
lastUpdateTime=Fri Mar 08 10:43:08 CST 2013
installerPackageName=com.android.vending
signature=06D936CB1BB9FB1A6BD4FC80105BDD79A5AF137F

Core info:

mStarted=true
deviceId=7B6D49007973F210
gcmId=
enableFlowAutoStart=true
allowManualLogin=true
allowRegistration=true
cacheCredentials=true

TapManager

numTaps=2 
mFocusedTap=[Tap meterName=kegboard.flow0 name=Left Tap mlPerTick=3.378570079803467]
All taps:

  meterName=kegboard.flow0 
  mlPerTick=3.378570079803467 
  relayName=kegboard.relay0

  meterName=kegboard.flow1 
  mlPerTick=3.378570079803467 
  relayName=kegboard.relay1

FlowManager

numActiveFlows=0 
totalFlowsProcessed=1
Recent flows:

  id=1 
  ticks=0 
  strval=Flow id=1 finished=true tap=[Tap meterName=kegboard.flow0 name=Left Tap mlPerTick=3.378570079803467] user=root ticks=0 volume_ml=0.0 
  timeSeries=0:0 2107:0

SyncManager

KegboardManager

HardwareManager

AuthenticationManager

ConfigurationManager

SoundManager

BluetoothManager

--- System logs ---

--- (end of bugreport) ---

mike
Mar 08, 2013 - 10:03 AM
Email the bugreport to [email protected] (which should be the default recipient, did you change it?)

sundogit
Mar 08, 2013 - 10:03 AM
I just sent the file over bluetooth to my machine so that I could see what it had in it in case I saw something that would help me figure it out. I'll send it.

mike
Mar 08, 2013 - 11:03 AM
Actually, is there nothing in "System logs"? If so, e-mail won't be any different..

I'll try to repro later today..

sundogit
Mar 08, 2013 - 11:03 AM
Hmm... what System Logs? As in on the server?

mike
Mar 08, 2013 - 11:03 AM
Hmm... what System Logs? As in on the server?
The "System logs" block of the text you pasted above. I assumed (wrongly) that you scrubbed it; it should have lots of data. Probably your device's version of android isn't making them available; sigh..

sundogit
Mar 08, 2013 - 11:03 AM
Ah I see now. Yep I'm dense.

I suppose a rooted Xoom might give those logs?

mike
Mar 08, 2013 - 11:03 AM
I suppose a rooted Xoom might give those logs?
Probably not worth the trouble..

In Android Settings, do you see a "Developer options" section, and within it, "Take Bugreport"? If so, please grab that and send it to the same address (after repo'ing the problem).

If you do not see "Developer options", try following these instructions to reveal it (groan): http://timgray.blogspot.com/2012/11/enable-developer-mode-on-your-jelly.html

If neither work, we can try something else.

Also, if you are running the kegbot server in the foreground (ie with runserver), there should be some logs for each http request, so we can see what's going on from that side. If you have those, send them along.

sundogit
Mar 08, 2013 - 12:03 PM
Nope don't have the option and the reveal didn't work either. It's running 4.0.4 and i don't think that the take bug report was put in until 4.1.x?

The server is normally running via supervisor but I'll fire it up in the foreground and capture what's going on.

sundogit
Mar 08, 2013 - 1:03 PM
Posting the errors here too in case anyone else would ever come across it.:

[08/Mar/2013 15:12:01] "POST /api/thermo-sensors/kegboard.thermo-da00000400dadc28 HTTP/1.0" 401 5739
[08/Mar/2013 15:12:02] "POST /api/thermo-sensors/kegboard.thermo-0900000400c37c28 HTTP/1.0" 401 5739
[08/Mar/2013 15:12:05] "POST /api/thermo-sensors/kegboard.thermo-2600000400922f28 HTTP/1.0" 401 5739
Is there a place to put in the API key that I missed?

mike
Mar 08, 2013 - 1:03 PM
What version of Django are you using (run kegbot-admin.py version)

If it's 1.5, can you please try: pip install Django==1.4.5?

sundogit
Mar 11, 2013 - 11:03 AM
(kb)root@keg:~# kegbot-admin.py version
1.4.4

sundogit
Mar 13, 2013 - 8:03 AM
So should I upgrade to 1.4.5? Or... is something else going on?

sundogit
Apr 10, 2013 - 12:04 PM
Mike?? Hello??? still having this problem...

mike
Apr 10, 2013 - 12:04 PM
The forum is not meant to be a bug tracker, and your last message would be a poor bug report.

Please open up an issue on github.com/Kegbot/kegbot .

Include the kegbot server and app versions you are using, which should be the latest.

sundogit
Apr 10, 2013 - 12:04 PM
OK I can do that - you were just responding to every post here with ideas and suggestions so I just thought you were going to continue doing that.

I'll copy everything that we've both said here and put it all into a new bug report.

And for the record, I did upgrade to 1.4.5.

Add option to disable taking pictures for pours

My tablet is set up somewhat awkwardly for taking pictures since it is on the same counter top as the keg tower. When pouring for people on the other side of the bar, I don't really want to take a picture of me or whomever is bar-tending.

Would be good to disable pictures for pours all together.

User Registration Password & Fields - Tablet

When registering a new user on the tablet it asks for a password, but then once the user is registered it shows them as not having a password. If the password isn't actually set why don't we just remove it from the registration page. On that same note if a registration doesn't require email confirmation why ask for the email address.

Calibration Slider Bounds Can't Expand

When you calibrate, if your default setting is way off where you need to be, you hit a floor and a ceiling on the slider bar and can only adjust within a certain range.

There should be a way to expand the slider bar floor and ceiling values.

This is an awesome tool, btw!

Pour in progress: Missing User logo

The pour in progress screen is not displaying the drinker's logo. It only shows the default guest logo.

This screen should also list the drinker's name. Currently you can't tell if you are pouring a guest drink or under your user account.

No error text on user registration - tablet

When a user tries to register on the tablet without filling in one of the fields (username, password, email) it doesn't allow them to submit it but it doesn't say why it isn't submitting the registration.

Dense (all taps) display mode

On the home screen and pouring screen, show status for all taps, in a higher-density mode.

This should be a setting, since some might prefer one way over another.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.