Skip to main content
Mault

Hardware build guide

Build the card sorter

01 / Set up

Set up your build

Choose how you're building the sorter. The parts list, wiring and assembly steps below follow these choices, which are saved in this browser.

Would rather not source every part yourself? The Mault shop sells kits with everything except the 3D-printed parts. You'll still need to print those yourself.
01

Where are your parts from?

02

Controller board

Set by the kit. Choose "Sourcing my own" to change it.
03

ESP32 mounting

04

Sorting modules

Each module adds two bins. With the catch-all at the bottom, that's 7 bins.
3
Module 1
Bin 2
Bin 1
Module 2
Bin 4
Bin 3
Module 3
Bin 6
Bin 5
Bin 7catch-all, all 3 bottoms open

Each module has an IR sensor and three servos: a bottom paddle that acts as its floor, a side paddle gate and a left/right pusher. A card falls through every open bottom paddle until it lands on a closed one, then that module's pusher sweeps it into the left or right bin. With every bottom open it drops into the catch-all.

02 / Parts

Bill of materials

Quantities follow your module count: 3 modules × 3 servos plus 1 feeder servo, and 4 IR sensors. That uses 10 of the PCA9685's 16 channels, and one PCA9685 runs up to 5 modules. Check off each part as you gather it. Checkmarks are saved in this browser.

Building forMault kitESP32-S3Breakout board3 modulesChange
0 of 35 parts0%
Kits don't include a power supply. You'll need your own regulated 6V supply rated for at least 3A to power the servos.

Electronics

QtyPartNotesBuy
1ESP32-S3-WROOM-1 N16R8 board with GPIO screw-terminal expansion adapterRuns firmware/main/main.ino; USB connection to the host computer for Web Serial. The board plugs into the adapter for screw-terminal wiring. Sold as a 2-pack, so you get a spare.
1Adafruit PCA9685 16-channel 12-bit PWM/servo driverI²C servo driver, drives every servo in the sorter
9SG90 micro servo, positional (180°) (0.09 s/60° at 4.8 V, 8 µs dead zone)3 per module × 3 modules: bottom paddle, side paddle gate, pusher
Avoid Tower Pro SG90s. They don't hold their calibrated positions reliably in this sorter.
1MG90S servo, 360° continuous rotationFeeder, drives cards out of the hopper into module 1

Sensing

QtyPartNotesBuy
4Reflective/obstacle IR sensor module (3-pin: VCC, GND, digital OUT)One at the gate of each module (1-3), plus one in the hopper throat

Power

QtyPartNotesBuy
16V regulated power supply, 3ADedicated servo power into the PCA9685 V+ terminal. Never power the servos from the ESP32-S3's onboard 5V. 5.5mm x 2.5mm barrel plug, center positive.
1USB-A–to–USB-C cableESP32-S3 dev board ↔ host computer. Plug it into the board's left USB-C port (labeled USB), not the right one (labeled UART or COM).
1DC barrel jack or screw-terminal pigtailAdapts the PSU output to the PCA9685's V+ / GND terminal

Structural

QtyPartNotesBuy
-PLA or PETG filamentQuantity per your slicer's estimate for the model above
620mm ID 26mm OD 3mm Width O-RingFitted onto the feeder roller for grip on the card face
49.2mm ID 14mm OD 2.4mm Section O-RingFits onto the hopper idler roller
13D-printed Servo Controller Plate (Plate 7)Printed once, regardless of module count
23D-printed Bins (Plate 10)card bin large, card bin medium and card bin small. Catch the cards the pusher ejects to each side
13D-printed End Bin (Plate 11)end card tray. Used alongside the Bins to complete the bin assembly

Fasteners & wiring supplies

QtyPartNotesBuy
24M3×6 screw14 attach each bin base to the housing; 8 attach the base panels to the base; 2 mount a camera or phone bracket
8M3 nutPaired with the base panel M3×6 screws
2M3 washerIncluded in the M3 screw kit. Used with the M3×8 screws that mount the hopper idler roller
2M3×8 screwMounts the hopper idler roller
1M3×25 screwAdjusts the hopper idler roller tension with the spring
17/32" x 11/16" springTensions the adjustable wall against the card stack
59M2×6 screw (17 per module, +4 for the board mount, +3 for the servo driver board, +1 for the feeder)Per module: the paddle and pusher arms, plus 6 to fix the bottom and side paddles to the housing. The rest mount the ESP32-S3, the PCA9685 and the feeder.
6M2×8 screw2 per module (3 modules), to mount the pusher. M2×10 works fine if you don't have M2×8 on hand.
10Servo horn screw (Included with servos)Secures each horn to its servo shaft
1 packJumper WiresFor the IR sensors and servos. If one is too short, join two and wrap the joint in electrical tape so it can't pull apart.
2Wago connectorsOptionalSplices power and ground to each IR sensor without twisting/soldering wires together
~50Dupont ConnectorsOptionalThese are only needed if you're making your own custom length wires.
1Dupont CrimperOptionalThese are only needed if you're making your own custom length wires.

Optional

QtyPartNotesBuy
1Logitech C920 webcamThis is the one I use. Any webcam works as long as you can manually adjust focus, brightness, etc. (auto-adjusting can throw off scans)
1Anker PowerConf C200 webcamRecommended alternative to the C920. Also lets you manually adjust focus, brightness, etc.
11/4"-20 camera mount screwStandard tripod-mount thread, screws into a webcam or phone mount's socket
0-25Hopper sled weightsDrop into the weighted hopper sled to press the stack down so cards feed more reliably. Add up to 25
2M10 washerOptional extra weight for the hopper weight
1 packServo extension cablesOnly needed for more than 3 sorting modules, where the stock servo leads won't reach the servo driver board
2Ball bearingsFor the bearing feeder base (Plate 4 "Alternative Feeder Base"), so the roller spins more smoothly
1 packNeodymium magnets (5×2 mm)Disc magnets, 5 mm across and 2 mm thick

Some "Buy" links are Amazon affiliate links. We may earn a small commission on qualifying purchases at no extra cost to you.

03 / Assembly

Assembly

Work through the phases in order, structural work first. Checkboxes are saved in this browser, so you can close the tab mid-build and pick back up later.

Stuck on a step? Join the Discord if you need help.

Building forMault kitESP32-S3Breakout board3 modulesChange
0 of 39 steps0%
Phase 01

Print the structural parts

Every printed part of a 3-module sorter, colored by what to print. The key lists how many of each you need, numbered by plate in the print file. Change the module count or board in the setup above and the model and counts update.

Drag to rotate, scroll to zoom, right-drag to pan. Hover or tap a part in the key to show only that part.

Optional: Plate 2 "Alternative Horns" has loose fit and snug fit versions of every servo horn, for servos whose shafts fit the standard horns too tightly or too loosely.

If roller servo horn (MG90S) fits your feeder servo too tightly or too loosely, print roller servo horn, roller servo horn (loose fit) or roller servo horn (snug fit) from Plate 2 "Alternative Horns" instead. Using the optional ball bearings? Print Plate 4 "Alternative Feeder Base" (feeder base (flat, bearing version) and feed roller (bearing version)) in place of the feeder base and roller.

A single purple 3D-printed sorting module frame: an open box with four pegs on top and tabs on its sides for joining modules.A short yellow module frame next to a tall yellow module stacked on a purple base support, showing how the printed frames fit together.
Glue the pins into the supports. Dry-fit the base pieces and sorting modules with the pins first, then once everything lines up, super glue each module alignment pin into place.

Optional: Plate 13 "Optional - Regular Bin Holders" has fixed wings (bin wing left, bin wing right and bin wing end) to use instead of the folding wings on Plates 7, 8 and 9.

The finished sorter: a black tower of stacked sorting modules with the card hopper on top, surrounded by white bins holding sorted cards.
Phase 02

Assemble the modules

Leave every horn off its servo shaft in this phase. You fit the paddles and pusher arms to their horns now, but the horns only go onto the servos in the app's setup wizard (Wire and calibrate), once each servo has moved to the right position.

The linkages are labeled LEFT and RIGHT, matching the left and right of the platform.

This paddle is the module's floor. It opens to drop a card to the next module.

Bottom paddle parts laid out on a cutting mat: a long pink paddle plate, a servo horn adapter, a short link arm and two screws.The bottom paddle assembled: the link arm is screwed between the paddle's hinge bracket and the servo horn adapter.The bottom paddle mounted on a pink module plate, its link arm connected to a blue SG90 micro servo, with the servo cables running off to the side.

One servo drives both side paddles, so they open and close as a pair.

Side paddle parts laid out: two long pink paddle plates, two link arms, a double-ended servo horn adapter and four screws.Both side paddles joined by their link arms to the central servo horn adapter, forming one linkage.The side paddle linkage mounted on the module plate and driven by a blue micro servo, with its cables looped at the top.
Pusher parts laid out: two L-shaped pusher arms, two straight link arms, a triangular servo horn adapter and five screws.The pusher assembled: both L-shaped arms are linked through the straight arms to the triangular servo horn adapter.A module plate with all three mechanisms fitted: the pusher arms, the side paddle linkage and the bottom paddle, each connected to a blue micro servo.
An IR sensor board clipped upright into its holder on the pink module plate, next to the servos and linkages.

These give the roller grip on the card face. Space them evenly along the roller's length.

The black 3D-printed feeder roller with six rubber O-rings seated in its grooves, three near each end.

The horn is the small piece that fits the servo shaft. Neither roller part has "servo" printed on it.

The white feeder module frame with a blue servo mounted on top, driving the O-ring roller inside the frame.

Same as the feeder roller, these give it grip on the card face.

The roller should be stiff once mounted. It should not free-roll.

The black card hopper: an open rectangular frame with a spring-loaded screw at the top and the O-ring roller along its bottom edge.
Required: don't skip the feeder ramp. The feeder doesn't feed cards reliably without it.
The black feeder riser seen from above, with the O-ring roller across the middle, an IR sensor beside it and the servo at one side.

This one tells the feeder when the hopper is empty. Placement matters more than the module sensors.

Inside the black feeder housing, a blue IR sensor board sits just below the O-ring roller, facing up toward the cards.
Phase 03

Wire and calibrate

Everything hangs off one I²C bus (PCA9685) and 4 digital input pins (IR sensors). The ESP32-S3's onboard supply powers the PCA9685's logic side. Its V+ servo rail must come from the external supply, and that supply's ground must be tied back to the ESP32-S3's ground.

Wire colors vary between parts and suppliers, so don't rely on the colors in the diagram or photos. Trace each wire from its pin label and make sure it ends up at the correct place.
Use a 6V 3A power supply for the servos. Anything higher can burn out the servos or the servo control board.

The PCA9685's header pins point straight out to the side. You may need to bend them 90° upward so they clear the panel and stay easy to reach when wiring to the ESP32-S3. Use the table below.

I²C bus

PCA9685 pinESP32-S3-WROOM-1Wire in diagram
SDAGPIO8
SCLGPIO9
VCC (logic)3.3V
GNDGND

Wire PCA9685 VCC to the ESP32's 3.3V pin, not 5V. The I²C pull-ups follow whatever powers the PCA9685, and feeding 5V into an ESP32 GPIO can damage it. The PCA9685 chip itself runs its logic fine at 3.3V, so this costs nothing.

Wire channels in the side of the base, with zip-tie points, keep the cables tidy.

PCA9685 channel map

Ch.Assignment
0Module 1, bottom
1Module 1, paddle
2Module 1, pusher
3Module 2, bottom
4Module 2, paddle
5Module 2, pusher
6Module 3, bottom
7Module 3, paddle
8Module 3, pusher
9Unused, available for additional sorting modules
10Unused, available for additional sorting modules
11Unused, available for additional sorting modules
12Unused, available for additional sorting modules
13Unused, available for additional sorting modules
14Unused, available for additional sorting modules
15Feeder (continuous rotation)

The sensors share power and ground: join the 4 power wires into one and the 4 ground wires into one, using Wago connectors, a breadboard or solder. You'll set each sensor's range in a later step.

IR sensors

All 4 read active-LOW (pin goes low when a card is present) using the ESP32-S3's internal pull-up. Wire the sensor's digital OUT straight to the pin, no external pull-up resistor needed.

SensorPinSignal wire in diagram
Module 1 gateGPIO4
Module 2 gateGPIO5
Module 3 gateGPIO6
Hopper throatGPIO16

Power these sensors' VCC from the ESP32's 3.3V pin if the module supports it, not 5V. Their digital OUT tends to swing up to whatever VCC they're fed, and 5V on OUT risks damaging the GPIO it's wired to. Check your specific sensor's datasheet accepts 3.3V.

Skipping the common ground is the #1 cause of servos that twitch but never move correctly.

Servo power

FromToWire in diagram
External 6V PSU, +PCA9685 V+ via barrel adapter +
External 6V PSU, −PCA9685 GND via barrel adapter −

The wizard opens the first time the sorter connects, and any time from the help (?) menu on /app/calibrate. A horn fitted off-center biases the whole linkage. The exact positions get fine-tuned in the next step.

For the pusher's left and right positions, swing the arm toward the inner wall but stop before it touches, about 15-16% away from neutral. The pusher doesn't need to hit the wall to fling the card, and pressing against it strains the servo. The app warns you past 16%.

Check it by pulling the card back to about 2 inches (5 cm): the LED should go off again. If it stays on, back the screw off a little. A sensor set too far reaches past the card path and reports cards that aren't there.

If a sensor doesn't trigger, or triggers with nothing in front of it, repeat the previous step for that sensor.

Getting a better calibration
  1. Remove the rear shim if you have one.
  2. Turn the screw clockwise until two cards fit in easily.
  3. Place 2 cards between the feeder roller and the top roller, lying flat on the hopper.
  4. Slide the top card back and forth while turning the screw counterclockwise, until the top card spins the top roller.
  5. Refit the rear shim.
  6. Load some cards.
  7. Test the feed.
  8. If more than one card comes out, turn the screw counterclockwise 1/8 of a turn.
  9. Test 5-10 cards.
  10. If more than one card still comes out, repeat from step 6 as many times as needed.
Phase 04

Load and run