Before You Start

The goal is a clean, robust scale with no exposed wiring, suited to brewing environments.

Tools

Screwdrivers, drill, enclosure-safe drill bits, wire cutters, and a wire stripper.

Wiring

Flexible wire, jack connectors, PG7 cable glands, and an RJ9 cable for the platform.

Safety

Work with power disconnected. Check 12V polarity before connecting the Dial or the valve.

Software

After assembly, use the software guide to flash the firmware and calibrate the scale.

Wet environment: this project is intended for a garage brewery, but the electronics still need protection. Close the enclosure, use cable glands, and prevent liquid ingress.

Shopping List

M5Dial product photo from AliExpress

M5Dial

The M5Stack Dial provides the ESP32, Wi-Fi, round screen, and rotary encoder. It keeps wiring low and gives the brewer a physical interface that remains usable with wet hands.

VEVOR scale product photo from AliExpress

VEVOR Postal Scale

Compact, 25 kg max, with an RJ9 connector that makes integration easier.

RJ9 cable product photo from AliExpress

RJ9 Cable

The RJ9 cable avoids hard-wiring the scale load cells. It provides a simple connection between the weighing platform and the Unit Weight I2C weight reader.

Optional Spunding Valve

Add these parts only if you use keg filling.

Unit Relay product photo from AliExpress

Unit Relay

The Unit Relay switches the optional 12V solenoid valve for keg filling while keeping the control signal separate from the valve power path.

Spunding valve product photo from AliExpress

Spunding Valve

The spunding valve is only required for keg filling. It remains the mechanical pressure regulator while the scale controls the filling stop by weight.

Solenoid valve product photo from AliExpress

Solenoid Valve

The normally closed solenoid valve gives the controller a safe way to stop filling. If power is lost, the gas path closes.

1/4 adapter product photo from AliExpress

1/4 Adapter

Connects the spunding valve to the solenoid valve.

Enclosure and Wiring

PG7 cable gland product photo from AliExpress

PG7 Cable Gland

The cable gland provides strain relief for the RJ9 cable and helps keep splashes away from the electronics inside the enclosure.

Jack connectors product photo from AliExpress

Jack Connectors

Jack connectors make power and optional valve wiring easier to disconnect for service or transport.

12V 3A power supply product photo from AliExpress

12V 3A Power Supply

The 12V supply powers the build and shares the same voltage family as the solenoid valve used by the keg-filler option.

Hardware Assembly

Prepare The Enclosure

Position the M5Stack Dial so the screen and rotary encoder remain accessible. Then mark the required exits: 12V power, RJ9 scale cable, and valve output if the keg filler is installed.

  1. Drill the M5Stack Dial opening to 45 mm using a hole saw.
  2. Drill one 13 mm hole for the PG7 cable gland that carries the RJ9 cable connected to the VEVOR weighing platform.
  3. Drill one 8 mm hole for the power jack, and another one for the spunding valve jack if needed.
  4. Insert the Units inside the enclosure and secure them with double-sided tape.

Scale Platform Wiring

Route the RJ9 cable into the enclosure through a cable gland, then connect it to the Unit Weight I2C weight reader.

Unit Weight to RJ9 cable wiring diagram: A+ green, A- red, E- black, E+ white
RJ9 scale cable wiring on the Unit Weight I2C terminal block.
Unit Weight Terminal RJ9 Cable Wire
A+ Green
A- Red
E- Black
E+ White
Simple integration: keep the RJ9 connector when possible. It lets you replace or disconnect the platform without redesigning the mechanical assembly.

Connect The Unit Weight I2C To The Dial Port A

Connect the red Port A on the M5Stack Dial to the Unit Weight I2C Grove connector with the HY2.0-4P cable. This port provides the 5 V supply and the I2C bus required by the weight reader.

Grove Wire M5Stack Dial Port A Unit Weight I2C
Black GND GND
Red 5V 5V
Yellow G13 / SDA SDA
White G15 / SCL SCL
Before power-up: use the red Port A, not Port B. Check that the connector is fully seated and that the Unit Weight I2C responds at I2C address 0x26.

Distribute The 12V Supply

The 12V 3A power supply is the main input. Use jack connectors for a clean power entry, then distribute power to the modules that need it.

  1. Clearly identify positive and negative on the jack input.
  2. Keep a common ground for modules that communicate with each other.
  3. Insulate connections with heat-shrink tubing or suitable terminal blocks.

Add The Relay And Solenoid Valve

For keg filling, the relay drives the normally closed 12V solenoid valve. If the system loses power or restarts, the valve returns to the closed position and filling stops.

  1. Mount the relay inside the enclosure, away from any possible liquid ingress.
  2. Route the valve output through its own cable gland.
  3. Install the valve on the gas path associated with the spunding valve, not on the beer line.
Unit Relay to 12V solenoid valve wiring diagram: 12V positive to COM, NO to valve positive, valve negative to 12V negative, NC unused
Relay wiring that powers the valve only while filling is active.

Connect The Unit Relay To The Dial Port B

Connect the black Port B on the M5Stack Dial to the Unit Relay Grove connector with the HY2.0-4P cable. This port provides the 5 V supply and the relay control signal.

Grove Wire M5Stack Dial Port B Unit Relay
Black GND GND
Red 5V 5V
Yellow G2 DIN
White G1 NC
Before power-up: use the black Port B for the relay. The red Port A remains reserved for the Unit Weight I2C.
Next step: open the Software Installation Guide, flash the M5Stack Dial, configure Wi-Fi, and run calibration. Final weighing accuracy depends heavily on calibration quality and on the mechanical stability of the platform.