How I made my shutter smart with a SONOFF MINI-ZBRBS
My office shutter has an electric motor and a regular up/down switch on the wall. I put a SONOFF MINI-ZBRBS, a small Zigbee shutter module, into the wall box behind that switch. The wall switch still works exactly as before, and now the shutter also opens and closes from a tile in ZigDash, at home and from anywhere.
How it works
A shutter motor has two power wires: one turns it up, the other turns it down. The wall switch sends live to one of them. The MINI-ZBRBS sits in between: the motor's two wires go to its outputs (Lout1 and Lout2), and the old switch goes to its inputs (S1 and S2). When you press the switch, the module drives the motor. When ZigDash asks over Zigbee, it drives the motor too.
The module also knows where the shutter is, so you can send it to 50% instead of only all the way up or down. And because it is mains-powered, it works as a Zigbee router that makes your network stronger.
What you need
- A SONOFF MINI-ZBRBS (Zigbee roller shutter switch). Zigbee2MQTT supports it as model
MINI-ZBRBS. - A shutter motor with its own limit switches: the usual tubular motor with four wires (neutral, up, down, earth) that stops by itself at the top and bottom. SONOFF rates the module for motors up to 1 A, and it stops the motor by itself after 2 minutes in one direction.
- A neutral wire in the switch box. The module needs neutral to power itself.
- Room in the box behind the switch. SONOFF recommends a box at least 60 mm deep.
- Lever connectors (I used a WAGO 221) and a few short pieces of wire.
- A Zigbee2MQTT hub at home. If you don't have one yet, see Hubs.
- ZigDash on your phone (Google Play or App Store). Controlling the shutter at home is free. Controlling it from anywhere uses ZigDash Pro's remote control: a one-time purchase, no subscription.
1. Wire the module
The module has six terminals, printed on it: N, L, Lout1, Lout2, S1 (up) and S2 (down). It has no earth terminal. This is how I wired mine:
| Terminal | Goes to | In my box |
|---|---|---|
| N | Neutral | The blue neutral wires, joined in a WAGO 221, with a short wire from there to N (see the note below on its colour) |
| L | Live | The live supply of the box |
| Lout1 | Motor: up (SONOFF calls it forward) | The motor's black wire |
| Lout2 | Motor: down (reverse) | The motor's brown wire |
| S1 | The switch's up output | One of the old switch's outputs |
| S2 | The switch's down output | The old switch's other output |
The old switch stays. Its common terminal gets live, as before. Its two outputs no longer go to the motor: they go to S1 and S2, and tell the module which way to drive. S1 and S2 are mains inputs, not low voltage: feed the switch's common from the same live, on the same breaker, as L.
Earth: keep the motor's yellow-green earth joined to the box's earth, as it was. It doesn't go to the module.
Up and down: wire colours are different in every house. Before you disconnect the switch, note which motor wire its up output fed, and mark it: that one goes to Lout1. If you get them the wrong way round, step 4 shows how to fix it.



Check that every screw terminal is tight. Leave the module outside the box for now, with its terminals facing away from you: you'll pair it in the next step.
2. Pair it with ZigDash
Pairing needs the module powered and its button pressed, so it's the one moment you work near a live box. Press only the button, with a plastic tool (the back of a pen), and touch nothing else. Rest the module on something that doesn't conduct, not touching the metal frame of the switch.
- In ZigDash, open Devices and tap Start pairing.
- Turn the breaker on. Press and hold the module's button for about 5 seconds, until its blue LED blinks slowly. It stays in pairing mode for up to 3 minutes.
- ZigDash shows the new device. Give it a name you'll recognise, like Office shutter.
- Turn the breaker off. Fold the wires in, put the module behind the switch, close the box and turn the breaker back on. Everything else is done from your phone and the Zigbee2MQTT web page.
3. Tell it what kind of switch you have
The module has to know how your wall switch behaves:
- A rocker that stays in up, off or down (like mine): mode
edge. - A push button that springs back when you let go: mode
pulse.
The easiest way is the Zigbee2MQTT web page: open the device, go to its Exposes tab and set external_trigger_mode to edge or pulse. (The module's button can do it too: a quick triple press steps to the next switch type and the LED blinks three times; you may need to repeat it. That means opening the box again, so I used Zigbee2MQTT.)
Then press the wall switch up, off and down: the shutter should move and stop as it always did. If it doesn't, the mode is wrong; set the other one.
4. Calibrate
The module learns how long the shutter takes to go all the way up and down. Without that, it can open and close, but it can't go to a position like 50%.
- In the Zigbee2MQTT web page, on the device's Exposes tab, set
motor_travel_calibration_actiontostart_automatic. - Let it run: the shutter goes all the way one way, then the other. Don't touch the switch while it does. When it's done,
motor_travel_calibration_statusshowsCalibrated.
(On the module itself, holding the button for more than 10 seconds, until the LED breathes, starts the same calibration.) If automatic calibration doesn't finish (with a weak motor, for example), SONOFF and Zigbee2MQTT both describe a manual calibration: you mark fully open and fully closed yourself.
Up and down swapped? Turn the breaker off, swap the wires on Lout1 and Lout2, then calibrate again. Zigbee2MQTT's invert_cover option only flips the position it reports; it doesn't change which way the motor turns.
5. A shutter tile in ZigDash
- On your dashboard, tap Add from a device and pick the shutter.
- The tile has Open, Stop and Close buttons, and a row of position presets (0, 25, 50, 100 by default). You can turn on a position slider in the tile's settings.
- From anywhere: with ZigDash Pro, turn on remote control and the same tile works away from home, with no port opened on your router and no monthly fee.
The wall switch and the app work side by side: the switch is still there for anyone who doesn't have the app, and the tile keeps working whether the shutter was last moved by hand or from the phone.