Scheduled Automation
Scheduled automation lets you build time-based rules that run automatically on your device. Instead of manually adjusting your setup at the same time every day, you define a schedule once and the system handles it for you.
Rules execute directly on your Raspberry Pi via the Node-RED scheduler, so they continue running even if your internet connection drops. The Pi checks active rules every 30 seconds and applies any commands that fall within the active time window.
What Can Schedules Control?
A schedule can contain one or more rules. Each rule controls one of three things:
Actuator — forces a relay, pump, valve, or other actuator on or off during the scheduled window.
Setpoint — writes a new target value to a PID controller input at the scheduled time. Useful for changing a temperature or humidity target at different times of day.
PID Enable / Disable — turns an entire PID controller on or off on a schedule. Useful when you want a control loop active only during certain hours.
How to Create a Schedule
- Open the Settings panel for your device and navigate to the Schedules tab.
- Click New Schedule.
- Give the schedule a descriptive name, such as "Daytime Grow Lights" or "Night Irrigation".
- Select your timezone from the dropdown. All start and end times are interpreted in this timezone, so setting it correctly is important.
- Add one or more rules using the Add Rule button.
- For each rule, choose what it controls (Actuator, Setpoint, or PID Enable), enter the target ID and room, set the action value, then configure the time window.
- Click Save. The schedule is saved to the cloud and automatically synced to your Pi within a few seconds.
You can enable or disable an entire schedule at any time using the toggle on the schedule card, without needing to delete it.
Configuring Rules
Repeat: Daily vs Weekly
Each rule has a repeat setting.
Daily means the rule applies every day of the week during the configured time window.
Weekly means the rule applies only on the specific days you select. You pick from Sunday through Saturday. This is useful for schedules that differ on weekdays versus weekends.
Start Time and End Time
Times are entered in 24-hour format (for example, 08:00 for 8 AM and 20:00 for 8 PM). The rule is active from the start time up to but not including the end time.
Midnight-spanning windows are supported. If you set a start time of 22:00 and an end time of 06:00, the rule will be active from 10 PM through 6 AM the next morning.
When the rule is active, the Pi applies its configured action (turning an actuator on, writing a setpoint value, etc.). When the time window ends, no explicit "off" command is sent — if you need the actuator to turn off at the end of a window, add a second rule with the opposite action that covers the remaining hours.
Configuring Actuator Rules
Set the rule type to Actuator and enter the actuator's ID and room. Then choose whether the actuator should be On or Off during the scheduled window.
Configuring Setpoint Rules
Set the rule type to Setpoint and enter the PID controller's sensor ID and room. Then enter the numeric target value to write. The value uses whatever units your sensor reports (for example, degrees Celsius for a temperature PID).
Configuring PID Enable / Disable Rules
Set the rule type to PID Enable/Disable and enter the PID controller's ID and room. Then choose whether the PID should be Enabled or Disabled during the window.
Use Case: Grow Light Lighting Schedule
A common use case for indoor growing is running grow lights for a set number of hours per day on a fixed cycle.
Create a schedule named "Grow Lights" with two rules:
Rule 1 — Type: Actuator, Target: your grow light relay, Action: On, Repeat: Daily, Start: 06:00, End: 22:00. This turns the lights on at 6 AM.
Rule 2 — Type: Actuator, Target: your grow light relay, Action: Off, Repeat: Daily, Start: 22:00, End: 06:00. This turns the lights off at 10 PM.
The result is a 16-hour photoperiod every day. If your grow cycle requires a different photoperiod — for example, 12 hours for flowering — simply adjust the end time of rule 1 and the start time of rule 2 to match.
Because the schedule runs on the Pi itself, the lights stay on the correct cycle even during cloud connectivity interruptions.
Use Case: Irrigation Timer
For an irrigation system, you may want short, frequent watering bursts rather than a continuous window. Use multiple rules to cover each burst window.
Create a schedule named "Morning Irrigation" with rules like:
Rule 1 — Type: Actuator, Target: your irrigation pump, Action: On, Repeat: Daily, Start: 07:00, End: 07:15. Waters for 15 minutes at 7 AM.
Rule 2 — Type: Actuator, Target: your irrigation pump, Action: On, Repeat: Daily, Start: 13:00, End: 13:10. Waters for 10 minutes at 1 PM.
Rule 3 — Type: Actuator, Target: your irrigation pump, Action: Off, Repeat: Daily, Start: 07:15, End: 13:00. Keeps pump off between morning and afternoon runs.
Rule 4 — Type: Actuator, Target: your irrigation pump, Action: Off, Repeat: Daily, Start: 13:10, End: 07:00. Keeps pump off overnight.
For more sophisticated irrigation that responds to soil moisture levels, combine scheduling with a PID controller — use a Setpoint rule to raise the humidity setpoint during daytime hours.
Troubleshooting
My schedule is enabled but nothing seems to happen
First, verify the schedule is enabled using the toggle on the schedule card. Then check that the rule's target ID and room ID exactly match the IDs shown on your dashboard. IDs are case-sensitive. If the IDs do not match, the Pi cannot find the target and silently skips the rule.
Also confirm that your device is online. Schedules run on the Pi — if the Pi is offline, rules cannot execute. The device status indicator in the dashboard header shows whether your Pi is connected.
My schedule fires at the wrong time
The most common cause is an incorrect timezone setting on the schedule. The timezone must match the physical location of your device. Open the schedule editor and verify the timezone selection. For example, if your Pi is in New York but the timezone is set to UTC, a rule starting at 08:00 will actually fire at 3 AM local time.
If the timezone looks correct, confirm your Pi's system clock is accurate. The scheduler uses the Pi's local time. If the Pi clock has drifted significantly, the rules will fire at unexpected times. The Pi should keep good time when connected to the internet via NTP.
My actuator does not turn off after the schedule window ends
Scheduled rules apply an action when the time window is active, but they do not automatically reverse the action when the window ends. The Pi simply stops applying the "on" command and will not send an "off" unless a separate rule is configured for that.
Add a complementary rule that covers the hours outside your active window and sets the actuator to Off. This ensures the actuator reaches the correct state for both the active and inactive periods.
I deleted a schedule but the actuator is still on
Deleting a schedule removes future rule evaluations, but it does not send a reset command to actuators that are currently in the state the schedule placed them in. After deleting a schedule, manually toggle any affected actuators from the dashboard to confirm they are in the desired state.
A PID setpoint rule does not seem to take effect
Make sure the PID controller is enabled. A setpoint rule writes a target value to the controller's input, but if the PID itself is disabled, it will not respond. You can enable the PID from the dashboard or use a separate PID Enable/Disable rule that is active before the setpoint rule fires.
Known Issues and Limitations
No one-shot (run once) schedules. The current scheduler supports repeating daily and weekly rules. There is no option to run a rule exactly once on a specific calendar date. As a workaround, create a weekly rule for the specific day, then disable or delete it after it fires.
30-second evaluation granularity. The scheduler runs every 30 seconds. Rules will not trigger at a precise second — there is up to a 30-second delay between when a window opens and when the command is first applied. For time-critical control loops, PID controllers are a better fit than scheduled rules.
No overlap resolution. If two rules target the same actuator or setpoint during overlapping time windows and specify different actions, the result depends on which rule is evaluated last. Avoid overlapping rules on the same target to prevent unpredictable behavior.
Schedules are not visible in the Node-RED editor UI. The scheduler subflow reads rules directly from Firebase RTDB at startup and on each evaluation cycle. You do not configure rules inside Node-RED — you configure them in the dashboard Schedules tab, and they sync to the Pi automatically.