Building instructions
To use CocktailPi you need to build your own machine. CocktailPi controls a relay board (or stepper drivers / valves) that switches the pumps, which pump the different liquids into the glass. You can build the machine however you like – the only requirement is a Raspberry Pi (NanoPi, BananaPi etc. are not supported).
Not every component below is required; pick what fits your setup. Pay special attention to the power supply: pumps and power supply must match, and you may need voltage converters.
Once your hardware is ready, continue with the installation.
INFO
The blueprints and parts are suggestions only and are provided without warranty.
Blueprints
Click on a blueprint to see it in full resolution. The Fritzing source files (.fzz) can be downloaded here: basic, reverse pumping, complex.
Basic setup
A minimal setup. Pumps cannot run in reverse.

Basic setup with reverse pumping
Two additional relays reverse the voltage of the pumps. This allows the software to run pumps backwards, e.g. to pump leftover liquid from the hoses back into the bottles.

Complex setup
An example of what can be connected: I²C GPIO expanders (up to 8), a voltage director, and a mix of DC and stepper pumps.

Which pumps to use?
CocktailPi supports DC pumps, stepper pumps and valves – see Choosing pumps for a comparison.
Hardware list
The components are suggestions and not all of them are required. Most parts are available on both AliExpress and Amazon.
Basic hardware
| Qty | Part | Where to buy | Notes |
|---|---|---|---|
| 1 | Raspberry Pi | Amazon | Pi 4 or 5 recommended with a touchscreen |
| 1 | Relay board | Amazon | one channel per DC pump |
| 8 | Dosing pumps | Amazon, AliExpress | |
| 8 | Diodes | reverse current protection, one per pump | |
| 1 | Power supply | adjustable 0–24 V: Amazon | must suit your pumps and their power consumption |
| or higher voltage + buck converter: Amazon | this converter only supplies 3 A – you may need more than one | ||
| Silicone hose | Amazon | ||
| Cables | choose a cable cross section suitable for the current |
Faster pumps
| Part | Where to buy |
|---|---|
| 12 V / 24 V dosing pump | Amazon, AliExpress |
Stepper pumps
| Part | Where to buy | Notes |
|---|---|---|
| Stepper motor pump | Amazon, AliExpress | works with 12 V, 24 V recommended |
| Stepper motor driver | Amazon, AliExpress | one per stepper motor |
| Stepper driver board (optional) | Amazon, AliExpress | one per driver |
Power supplies
| Part | Where to buy | Notes |
|---|---|---|
| 5 V step-down converter | Amazon | to power the Raspberry Pi |
| 12 V power supply | Amazon | for 12 V pumps |
| 12 V power stabiliser | Amazon | for battery operation |
| 24 V power supply | Amazon | |
| 0–24 V adjustable power supply | Amazon | |
| Voltage converter / buck converter | Amazon |
Other
| Part | Where to buy | Notes |
|---|---|---|
| 7" touchscreen | Amazon | |
| 16-pin I²C GPIO expander | Amazon | for more pumps |
| I²C relay board (1/2/4/8/16 channels) | AliExpress | |
| 16-channel relay board | Amazon | needs 5 V to trigger, the Pi's GPIOs use 3.3 V – use a level shifter |
| 2-channel relay board | Amazon | voltage director for reverse pumping |
| Rectifier diode | Amazon | when combining power supply and power stabiliser |
| LAN cable feed-through | Amazon | for the case |