Welcome to Jetson ORIN NANO SUPER repository
当製品の日本語版マニュアル資料は、こちらからご取得ください。
7. Scheduled Tasks
OpenClaw Scheduled Tasks Tutorial
Before starting, please complete the [01-Hardware Configuration], [02-openclaw API-KEY Configuration], [03-openclaw Model Switching], [04-AI Voice Interaction Configuration], [05-Three Dialogue Solution Configuration Tests] under the
Prerequisitesdirectory. If you are currently only using TUI / whatsapp, you can skip04for now. This article assumes the basic environment has been prepared and only expands on "fixed-time automatic script execution" part of the content.
1. Tutorial Objectives
This article demonstrates through "AI-generated script + Linux scheduled execution" how OpenClaw upgrades from immediate dialogue to automated peripheral applications. After completing this tutorial, readers can:
Understand the basic implementation approach of OpenClaw scheduled tasks
Distinguish the scenarios suitable for
HEARTBEATandcronrespectivelyDescribe automation requirements through three methods: whatsapp, TUI, and voice code
2. Hardware Preparation
OpenClaw mainboard
DHT temperature and humidity sensor
OLED display
RGB light strip / RGB light bead module
[Optional] CSI camera[Optional] AI voice module + speaker
Description:
The core of this tutorial is "scheduled execution", not requiring all peripherals to be connected simultaneously
Connect the corresponding hardware first for the type of automation task you want to do
3. Test Scheduled Task Basic Capability
Before starting this project, please complete one openclaw tui basic dialogue self-check; if you haven't done it yet, see [05-Three Dialogue Solution Configuration Tests]. After passing, enter scheduled task specific testing.
It is recommended to test in the following order:
First enter OpenClaw TUI
Let OpenClaw generate a simple script
Run the script manually in terminal, confirm functionality is normal
Terminal input:
openclaw tuiIt is recommended to first try the following type of requirements:
Help me write a script to display current temperature and humidity on OLED, save to desktop
Generate a script that reads temperature and humidity and prints results every time it runs
Write a script to make RGB light green for 3 seconds then turn off
After the script is generated, first run it manually, for example:
xxxxxxxxxxpython3 /home/jetson/Desktop/your_script.py4. Three Solutions for Communicating with OpenClaw
| Solution | Suitable Scenarios | Advantages | Recommended Positioning |
|---|---|---|---|
| Remote description of automation requirements | Suitable for first clarifying "what to do on schedule" | Used to generate scripts and confirm requirements | |
| TUI | Local creation and debugging of scheduled tasks | Easiest to jointly debug scripts and cron | Preferred implementation solution |
| Voice code | Voice description of automation scenarios | Closer to desktop assistant experience | Suitable for demonstrating "one sentence generates automation" |
If optional AI voice module + speaker are selected, whatsapp dialogue, tui, whatsapp dialogue need to broadcast OpenClaw's reply content. You can run the following program in terminal. AI voice module dialogue does not need to run repeatedly
Modify whether to enable broadcast parameter
xxxxxxxxxx/home/jetson/voice_to_openclaw/.env
xxxxxxxxxxENABLE_TTS=true #This parameter controls whether to broadcast. After modification and saving, run the following program in terminalTerminal input
xxxxxxxxxxcd ~/voice_to_openclawsource .venv/bin/activatepython -m src.openclaw_session_tts
4.1 whatsapp Solution
For whatsapp connection steps, please directly refer to [05-Three Dialogue Solution Configuration Tests]. This section is more suitable for describing requirements, for example:
Help me create a scheduled task: make RGB lights up red every minute as a remind, then turn off the light.

4.2 TUI Solution
If you have completed the TUI self-check in Chapter 0, directly enter terminal text dialogue:
xxxxxxxxxxopenclaw tuiThen you can directly enter project-related commands, for example:
Help me create a scheduled task: read temperature and humidity every minute and display on OLED

4.3 Voice Code Solution
xxxxxxxxxxRequires optional AI voice interaction module + speaker
For voice module installation, environment configuration, and basic wake-up process, please directly refer to [04-AI Voice Interaction Configuration]. After waking up, you can directly say control content, for example:
Help me create a scheduled task: read temperature and humidity every minute and display on OLED

If you want to stop the scheduled task, you can say in the current dialogue session: stop the current scheduled task for me

You can use the command
cron listto view current scheduled tasks

5. Project Implementation
Note: The following are all dialogue demonstrations using openclaw tui method. You can also choose whatsapp or voice method to complete.
5.1 Scenario One: Hourly Temperature and Humidity Sampling
Experimental Objective
Let the device automatically read temperature and humidity once per hour, and record results or synchronize to screen.
Effect Description
This is the most basic and common scheduled task scenario. It can later be further expanded into logs, dashboards, environmental alerts, or plant care projects.
Example Instructions
Help me make a scheduled task: read temperature and humidity every minute and display on OLED
5.2 Scenario Two: Timed Status Reminder
Experimental Objective
At a fixed time, use RGB or OLED to make a clear reminder.
Effect Description
This type of task is suitable for water drinking reminders, class reminders, patrol reminders, status switching reminders. It does not emphasize continuous running, but emphasizes triggering a clear action at a certain time point.
Example Instructions
Help me make a scheduled task: make RGB light red every minute to remind, then turn off
5.3 Scenario Three: Timed Patrol Script
Experimental Objective
String multiple peripheral actions together to form a periodically executable small automation task.
Effect Description
For example, read temperature and humidity once per hour. If status is abnormal, light alert, and display results to OLED. This type of task is already close to a complete small project, and is also the most obvious place where "AI-generated script" combines with "scheduled execution".
Example Instructions
Help me make a scheduled task: read temperature and humidity once per minute, light red when abnormal, and prompt on OLED