coffeewater

command module
v0.0.0-...-0c6518e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2020 License: Apache-2.0 Imports: 12 Imported by: 0

README

coffeewater

Tired of filling the water in your single-cup coffee machine? Have a Benjamin to spare (~$100), and an afternoon to kill? This is just what you need!

coffeewater is the code behind CoffeBot, a tiny computer and some plumbing parts to automate an annoying and repetitive task.

Roughly what you need

You need the following basic components:

  1. A single-cup coffee machine.
  2. A computer with a few GPIO pins, such as a Raspberry Pi.
  3. An HC-SR04 compatible ultrasonic range sensor.
  4. A solenoid controlled water valve.
  5. A few bits of plumbing and wire to connect everything together.

How it works

CoffeeBot uses an ultrasonic range sensor mounted inside the top of the coffee machine's water reservoir to read the water level. When the water level falls below a certain point, it triggers a solenoid valve to open and begin filling the reservoir. To feed water into and out of the value, you must attach the water valve between a nearby sink's plumbing and the reservoir. CoffeeBot's code includes several safety measures to ensure it won't accidentally flood your kitchen, and to ensure you never have to fill the reservior by hand again!

Bill of materials

Here's the precise set of materials, with links, that you need to assemble a CoffeeBot of your very own. Do take note that you may have some of these items already (such as a few resistors, or an old USB charger to power the Pi), or that you may be able to find them cheaper at a local plumbing supply store or big-box hardware store (such as a faucet supply line). You may also be able to easily substitute some less expensive plastic plumbing parts, such as for the brass Sink Tee and Threaded Coupling I have linked to below. You could cut costs more aggressively by dropping down to a Pi Zero and replacing the Perma-Proto hat with a spare piece of perfboard.

Description Cost
Rapsberry Pi Model 3 A+ $25.00
A cheap SDCard $8.99
Rapsberry Pi case $5.00
Perma-Proto Model A+ Hat $4.95
Rapsberry Pi power supply $7.50
HC-SR04 Ultrasonic Distance Sensor $3.95
Solenoid Water Valve $6.95
Water Valve Power Supply $8.95
5.5x2.1mmm Barrel Power Supply Jack $0.97
TIP120 Transistor $2.50
Kickback Protection Diode $1.50
Faucet Supply Line $5.22
Sink Tee $8.46
1/2" Threaded Coupling $6.88
1/2" MIP Adapter to 1/4" OD push fit adapter $3.98
1/4" OD PEX water tubing and adapters $14.87
Supplemental

If you don't have a pile of resistors and a few optoisolators lying around, you might need to order some. You should order a bunch of these if this kind of project sounds fun, because you'll inevitably find uses for these cheap components.

Description Cost
an optoisolator $0.39
some resistors $14.99
some breakaway headers $4.95
some female/female jumper wires $1.95
~10 feet of >=4 conductor wire $3.30

You could do without the headers if you just solder everything together, but it's much easier to work with on the future if you can disconnect each of the pieces. You could also use roughly any wire with at least 4 conductors to hook up your HC-SR04, such as an old CAT5 patch cord or some alarm or thermostat wire.

Perma-Proto Board Layout

TODO: Describe how to lay out the parts on the perma-proto board, and what each one does.

Wiring assembly

TODO: Describe how to wire the 3 parts together.

Software Setup

TODO: Describe how to setup coffeewater to be run by systemd.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
closevalve simply sets a GPIO pin to low and exits.
closevalve simply sets a GPIO pin to low and exits.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL