5 min read

Smart blinds: control by the sun, the temperature and the time

Blinds that come down by themselves in strong sun and a warm room and go up by hand with one press. We start with one rule for one blind and an Aqara Roller Shade Driver E1 motor.

Level
Intermediate
Active time
60–90 minutes
Home Assistant required
Yes

In the afternoon the sun beats straight through the window and the room overheats, while the blind stays up because nobody is home. We want the blind to come down by itself when it is really needed, and to be able to raise it with one press without fighting the automation.

What we will get

A motorised blind that Home Assistant controls by three signals: time (for example sunset), the sun’s direction and height, and the room temperature. We start with one rule for one blind and add conditions one by one.

Project boundary: we don’t touch the electrical installation. The motor runs on a battery and attaches to the blind itself. It doesn’t detect obstacles and people, so we don’t let it run on its own where a child or an animal could get caught.

What we need

  • Aqara Roller Shade Driver E1: one blind motor. With several blinds we need one motor for each.
  • A roller blind that the motor can drive. According to the manufacturer the motor attaches to the blind’s chain; before buying we check the chain type and the blind’s weight in the product description.
  • Home Assistant with Zigbee (ZHA or Zigbee2MQTT) and the Sun integration, which is part of the standard configuration.
  • Optional: a temperature sensor in the room. Without it we work only with time and sun.

You need a Zigbee hub or Home Assistant with a Zigbee adapter.

Setup time: about an hour for the first blind. Then we let the automation run for a few sunny days and observe.

How it works

The sun is different for every window. That is why we don’t copy one time for all rooms. The entity sun.sun gives the sun’s height (elevation) and direction (azimuth). A positive height means the sun is above the horizon. The direction is in degrees clockwise from north, so a window facing south looks toward about 180°.

The logic is simple: if the room is warm, the sun is above a certain height and shines on our window, we lower the blind to a partly closed position. If we have raised the blind by hand, the automation doesn’t touch it until the next day.

How it is at our place

Marto’s Home Assistant has six Aqara Roller Shade Driver E1 motors in the bedroom, grouped in one entity cover.bedroom_blinds. The automation “Close the blinds on sun set” closes all the blinds in the bedroom zone one hour after sunset (trigger “sun”, event “sunset”, offset +01:00:00). There are no conditions.

By the beds there are buttons that toggle the blinds with one press. They are the manual way to override the automation. The rules by temperature and sun height are not set up at our place, so the example below is a guide, not a copy of our configuration.

Steps

  1. We add the motor to the Zigbee network (ZHA or Zigbee2MQTT) and name it after the room. We expect a new entity of type cover with a position from 0 to 100, where 100 means fully open.
  2. We set the blind’s end positions following the manufacturer’s guide. We check from Home Assistant that “open” and “close” reach the same ends.
  3. We create a Toggle helper (input_boolean) for the manual override, for example input_boolean.blinds_manual_override (an example name).
  4. We write down which windows get strong sun and at which hours. A rule for one window is enough to start.
  5. We create the automation from the example and replace the entity IDs with ours.
  6. Only after a few predictable days do we add a second condition, for example cloud cover or a higher temperature threshold.
# Example: add it in a new automation (Edit in YAML).
# All entity IDs and numbers are examples, replace them with your own.
alias: Blind down in strong sun and a warm room
triggers:
  - trigger: numeric_state
    entity_id: sensor.living_room_temperature
    above: 26
conditions:
  - condition: numeric_state
    entity_id: sun.sun
    attribute: elevation
    above: 20
  - condition: numeric_state
    entity_id: sun.sun
    attribute: azimuth
    above: 150
    below: 250
  - condition: state
    entity_id: input_boolean.blinds_manual_override
    state: "off"
actions:
  - action: cover.set_cover_position
    target:
      entity_id: cover.living_room_blind
    data:
      position: 30
mode: single

If we choose sunset instead of temperature, the trigger becomes trigger: sun with event: sunset and optionally offset, just like in the automation at Marto’s.

Checking the result

  • Normal case: on a sunny afternoon, when all the conditions are met, the blind comes down to the chosen position. In Developer tools → States we see the position change.
  • Edge case: we raise the blind by hand and turn on the manual override. The automation shouldn’t lower it again.
  • Missing data: if the temperature sensor is “unavailable”, the condition isn’t met and the blind doesn’t move. That way an error leads to a motionless blind, not to unexpected movement.

If it doesn’t work

  • The blind doesn’t react → the motor is out of range of the Zigbee network or the battery is weak → we check its state and charge the battery.
  • The automation doesn’t start → the trigger crosses the threshold only once while the temperature stays above it → we look at the automation’s traces (Settings → Automations → Traces).
  • The blind comes down at the wrong time → the window’s direction is different from the expected → we look at the actual values of sun.sun in Developer tools and correct the azimuth.

Limitations and switching off

  • We don’t know whether someone is standing by the window.
  • Cloud cover and the shade of neighbouring buildings are not taken into account unless we add a condition for them.
  • Without Home Assistant or the Zigbee network the automation doesn’t work. The blind can be operated by hand with the chain, and with a battery also with the button according to the manufacturer’s guide.
  • We switch off the rule with the manual override switch or stop it from Settings → Automations.

Sources and verification status

Checked against the Home Assistant documentation, 22.11.2026, and a read-only reading of Marto’s Home Assistant (see ha-evidence).

At home

Marto

Six Aqara Roller Shade Driver E1 motors in the bedroom, grouped in cover.bedroom_blinds. The blinds close one hour after sunset, and manual control is with buttons by the beds.

Need a hand?

We can set up and install everything in this project. In some regions we install it ourselves — ask us.

Contact us

Related projects

Blind automation kit AQARA Roller Shade Driver E1, Zigbee (RSD-M01)

58,90 €
View parts

What you need

Requires a Zigbee hub or Home Assistant with a Zigbee adapter.

Added to cart

Real Home Automations

Sign in to your account

With a code sent to your email

Continue with Google
or

By continuing, you accept the Terms and Conditions and the Privacy Policy.