Open and close blinds and awnings at sunrise and sunset

Open and close blinds and awnings at sunrise and sunset

How it works

A cover motor has two windings, one for each direction. A Shelly 2PM Gen4 in cover mode feeds one winding at a time from its two outputs, so the motor only ever runs one way, and your up and down buttons keep working through its inputs.

Once it has calibrated how long the motor takes to run end to end, the Shelly knows where the cover is and can send it to any position from 0% (closed) to 100% (open). Schedules can follow sunrise and sunset for your location, with an offset before or after, or run at a set time of day.

  1. 01

    Your phone

    Open, close or set a position from the app, or let a schedule do it.

  2. 2PM Gen4 Smart Relay 02

    Shelly relay

    Drives the motor one way at a time and knows where the cover is.

  3. 03

    Your blinds or awnings

    Open at sunrise and close at sunset, with your buttons still working.

Check your motor first

This suits standard 230 V cover motors with their own limit switches, set correctly before the Shelly goes in. Shelly recommends only motors with electronic or mechanical limits.

  • 230 V
  • Limit switches set

What it looks like on your phone

Step by step

How you'll set it up

Add the device to Wi-Fi from your phone, or straight from a browser.

  1. Check the motor's limits

    Run the blind, shutter or awning fully open and fully closed with its existing switch or remote and make sure it stops by itself at both ends. The Shelly relies on those limits, so set them before it goes in.

  2. Fit the Shelly behind the switch

    Mains goes to L and N. One motor winding goes to O1, the other to O2, and the motor's common returns to neutral. The up and down buttons connect to S1 and S2.

    Wire map 2PM Gen4
    • Active (supply) L
    • Neutral and motor common N
    • Motor winding O1
    • Other motor winding O2
    • Open button (optional) S1
    • Close button (optional) S2
    Circuit overview
    LN230 V~ 50 HzM1Motor2Open button3Close buttonO1LLO2S1S2NShelly 2PM Gen4
    1Motor2Open button3Close button
    Active (supply)Neutral / 0 VSwitched loadSwitch signal / dry contact

    In Australia, fixed 230 V wiring is licensed-electrician work. Use these diagrams to plan the job and brief your electrician.

    Showing the whole circuit

    Shelly 2PM Gen4

    100%
    LN230 V~ 50 HzM1Motor2Open button3Close buttonO1LLO2S1S2NShelly 2PM Gen4
    1Motor2Open button3Close button

    Select a terminal to follow its wiring.

  3. Add the Shelly in the app

    Add the relay in the Shelly Smart Control app and name it after the window, such as Living room blind.

  4. Switch it to cover mode

    Open Device settings, expand Device profile, choose cover and tap Save. The main screen now shows Open and Close buttons, and the Shelly needs calibrating before it can set a position. In the web interface, open Settings, choose Cover under Device profile and click Save settings.

  5. Calibrate the motor

    Clear anything in the cover's path. In Device settings, expand Calibration and tap Start calibration. The Shelly runs the motor to both ends and learns how long it takes. If it opens when you tap Close, turn on Reverse directions and calibrate again. In the web interface, open the cover's settings and click Start beside Calibration.

  6. Open it at sunrise

    Open Schedule and tap Add schedule. Pick the days and tap Next. Under Choose time interval, choose Sunrise / Sunset and set an offset if you want one, such as 30min After Sunrise for a later start on weekends. Tap Next, then Add local action, choose Open Cover (or Move Cover to specific position for a partly open start) and save the schedule. In the web interface, click Create Schedule, select the days, tick Use sunset or sunrise offset and choose After sunrise with your offset, add the Open Cover action and click Save.

  7. Close it at sunset

    Add another schedule for every day at Sunset, with the action Close Cover. For a west-facing window, add one at a set time in the early afternoon that moves the cover to 20% to keep the heat out.

  8. Check the schedules

    Schedule now lists each one with its days, action and time: Open at Sunrise on weekdays, Close at Sunset every day, and the later weekend start. Schedules in the web interface shows the same list.

Frequently asked questions

Should I use the Shelly app or Home Assistant?

If you don't run Home Assistant, use the Shelly app: it needs no hub, and the schedules are stored on the relay. If Home Assistant already runs your home, put the blinds there, so they sit alongside your other automations.

Will my wall buttons still work?

Yes. The buttons connect to the relay's S1 and S2 inputs, so they still open and close the cover. Pressing the same button while it's moving stops it, and pressing the other one reverses it.

Will it work with my motor?

It suits a 230 V AC motor with separate open and close wires and its own limit switches, which covers most wired roller blinds, shutters and awnings. A motor that is only controlled by its own radio remote, with no switch wiring, isn't wired this way.

What if something is in the way?

Turn on obstacle detection in the cover's settings. If the cover meets an obstacle while it's moving, the Shelly stops it or reverses it to the end, whichever you choose. It's still worth keeping schedules to times when the window or doorway is clear.

Will it pull the awning in when it's windy?

Not on its own. The Shelly runs on time and position, and it has no wind sensor, so retract the awning from the app or the wall button when the weather turns.

Can it tilt Venetian blind slats?

Yes. The 2PM Gen4 supports Venetian blinds and controls the tilt of the slats as well as the blind's position.

Can one relay run two blinds?

No. In cover mode the 2PM Gen4 drives one motor, so each blind, shutter or awning needs its own relay. They can share a schedule time, so a whole side of the house can close together.

Does it follow the seasons?

Yes. Home Assistant works out sunrise and sunset from its home location, so the times move through the year.

Will the schedules run if the internet drops?

Shelly relays keep time by syncing over the network, so the schedules need a working internet connection to stay on time. The wall buttons and control over your home Wi-Fi keep working without it.

Does it run while Home Assistant is down?

The wall buttons do: they're wired to the Shelly. The sunrise and sunset automations run in Home Assistant, so they wait until it's back.

Still need a hand?

We answer most messages within one business day. If your question is about an existing order, have your order number ready. It speeds things up.

Contact us