Keurig Auto Fill with BS1 and Milone eTape

eod_punkeod_punk Posts: 146
edited July 2013 in Robotics Vote Up0Vote Down
Here is how I automated refilling my Keurig coffee pot with a BS1 and a 8" Milone eTape.
[video=youtube_share;f-w_Y_e3z-Y]

The BS1 polls the eTape using the "POT" command and opens a 12vDC solenoid through a PN2222 transistor if it is low. It also flashes the LED quickly while filling. To try and prevent an over fill and making a mess while it is filling the BS1 keeps count through the fill loop. If the count limit is reached it will close the solenoid and no longer automatically fill the reservoir untill the power is toggled, the LED is also toggled slowly. If you want to fill the reservoir before it is low you can just press the fill button and it will top off the tank. To get the water to the Keurig I tapped into my refrigerator water supply. I used all 1/4" push to connect fittings and a shut off valve at the T connection.


IMG_0245.jpg
IMG_0244.jpg
IMG_0243.jpg
IMG_0246.jpg


IMG_0250.jpg
IMG_0249.jpg
IMG_0248.jpg
IMG_0247.jpg

' {$STAMP BS1}
' {$PBASIC 1.0}

' -----[ I/O Definitions ]-------------------------------------------------

SYMBOL Pbtn   = PIN0
SYMBOL Led    = 1
SYMBOL Sensor = 2
SYMBOL Valve  = 3
SYMBOL scale  = 100

'-----[Variables]---------------------------------------------------------

SYMBOL level = B0
SYMBOL count = W1       '0 to 65535
SYMBOL CountLimit = W2

CountLimit=200 '0 to 65535

'-----[ Initialization ]-----------------------------------------------------
  'DEBUG CLS                    'Debug info for checking fill level.
  'GOSUB Var_Data
  GOSUB Get_Level
  'GOSUB Var_Data

  HIGH Led                     'Turn the LED on to inidacte power is on.

'-----[Main Code]---------------------------------------------------------

Main_Loop:
  GOSUB Get_Level
  'GOSUB Var_Data
  IF Pbtn=1 AND level>19  THEN Fill
  IF level>=38 THEN Fill
  PAUSE 100
  GOTO Main_Loop




' -----[ Subroutines ]-----------------------------------------------------

Get_Level:
  POT Sensor,scale,level       'Check Fluid level
  RETURN

Fill:
  HIGH Valve                   'Open solenoid valve to start filling.
  FOR count = 1 TO CountLimit  'If count limit is reached the tank maybe over filling.
    GOSUB Get_Level            'Check fill level
    'GOSUB Var_Data             'Debug values if needed.
    IF Level<=19 THEN close    'If full goes to the Close solenoid routine.
    GOSUB Flash                'Goes to the LED flashing routine.
  NEXT                         'Loop and add one to the counter.
  GOTO Alarm                   'Goes into error to prevent over filling the tank.

Close:
  LOW Valve                    'Close solenoid valve.
  HIGH Led                     'Turn the LED on to inidacte power is on.
  'GOSUB Var_Data               'Debug values if needed.
  GOTO Main_Loop

Flash:                         'This will flash the LED to indicate the solenoid is open.
  HIGH Led
  PAUSE 100
  LOW Led
  PAUSE 100
  RETURN

Alarm:                         'This will stop and flash a warning light in case of error.
  'GOSUB Var_Data             'Debug values if needed.
  LOW Valve
  LOW Led
  PAUSE 1000
  HIGH Led
  PAUSE 1000
  GOTO Alarm                   'If error occures the power to the Basic Stamp must be reset or powered off before it will work again.

Var_Data:                      'For Debuging Purposes.
  'DEBUG "level = ", #level
  'DEBUG " Count = ", #Count, CR
  RETURN
Keurig Auto-Fill.bs1 Keurig Button-Fill.bs1
1024 x 768 - 56K
1024 x 768 - 89K
1024 x 1365 - 131K
1024 x 1365 - 109K
1024 x 1365 - 127K
1024 x 1365 - 143K
1024 x 1365 - 100K
1024 x 1365 - 125K
There is no problem that can't be solved with a suitable amount of explosives!
EOD Memorial
Tagged:

Comments

  • 10 Comments sorted by Date Added Votes
  • doggiedocdoggiedoc Posts: 1,994
    edited May 2013 Vote Up0Vote Down
    Very cool Mr. Punk.

    I am pleased to see another BS1 project! Seems to be fewer and fewer these days.

    Doc
    Some times my mind seems to wander..... these days I just tag along.
  • davejamesdavejames Posts: 3,850
    edited June 2013 Vote Up0Vote Down
    ...very clever!
    Well-written documentation requires no explanation.
  • Chris SavageChris Savage Parallax Engineering Posts: 13,778
    edited June 2013 Vote Up0Vote Down
    Very nice project! Thanks for sharing!
    Chris Savage
    Engineering Tech, Parallax Inc.
    (916) 624-8333 x3005
    Website / Twitter / Google+
  • DracosIceDracosIce Posts: 1
    edited July 2013 Vote Up0Vote Down
    Great project! What part do you use for the Solenoid valve?
  • eod_punkeod_punk Posts: 146
    edited July 2013 Vote Up0Vote Down
    I used a ASCO Model #U8256A002V 24v solenoid that I had laying around from swapping parts with people.
    http://goo.gl/KX1Mq (Link to Grainger) I’m powering it with 12v with a pn2222a transistor.
    There is no problem that can't be solved with a suitable amount of explosives!
    EOD Memorial
  • WhitWhit Posts: 3,054
    edited July 2013 Vote Up0Vote Down
    @eod_punk,

    Great project - my Dad is hooked on his Keurig and we are always refilling it!

    Thanks also for the link to the EOD Memorial - learned something new...
    Whit+

    "In almost every robotic project I attempt, I am way over my head going into it..." - Carol Lynn Hazlett
  • Nick ErnstNick Ernst Posts: 138
    edited July 2013 Vote Up0Vote Down
    This is awesome....I think my Keurig has an appointment with destiny this weekend!
  • TtailspinTtailspin Posts: 1,246
    edited July 2013 Vote Up0Vote Down
    Great idea! They do need to be filled with water every morning...
    I fought hard against getting one of these coffee makers, I thought it was a gimmick first time I saw one in the store,
    We got had to use one for a weekend, Now I don't want to be without my Keurig.

    Thanks for sharing, and congrats on making 'project of the week'.


    -Tommy
  • ercoerco Posts: 14,412
    edited July 2013 Vote Up0Vote Down
    FANTASTIC! Love the BS1 and this is a great application. BRAVO!
    You'll find me in the new Robotics forum.
Sign In or Register to comment.