Token导航 LogoToken导航TokenDH.com
效率需要联网clawhub未标认证来源可访问clear审计通过

when-clock-skill当时钟技能

Agent Skill

when-clock-skill 用于处理音频、语音、转写和声音素材相关任务,适合在 OpenClaw 中需要整理音频流程、转写内容或生成配音素材时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

4,260

周安装

174

GitHub Stars

公开资料未说明

下载量

1,364
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:when-clock-skill(当时钟技能)
来源仓库:https://github.com/master-gong/when-clock-skill
安装命令:
openclaw skills install when-clock-skill
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install when-clock-skill

简介

when-clock-skill 用于控制 WHEN 语音 LAN 时钟设备,支持语音报时、天气预报、闹钟设置和倒计时功能。

  • 适用于智能家居或本地设备集成场景,需配合特定硬件使用。
  • 通过 clawhub 安装后可在 OpenClaw 中调用,参数需按设备型号和协议规范填写。
  • 使用前请确认设备连接状态和网络配置,部分功能仅限特定语音版本支持。
  • 涉及定时任务时建议测试触发机制,避免因网络延迟导致执行异常。

SKILL.md

name
when-clock-skill
description
>
version
2.0.0
triggers
tools

when-clock-skill (OpenClaw Skill Description)

1. Skill Overview

  • Entry script: when-clock-skill.py
  • Runtime: Python 3.9+, standard library only, no pip required
  • Target devices: WHEN / WHEN Voice clock (LAN HTTP, auto-detected)
  • Config file: config.json in script directory (fill devices array with id and clock_ip)

2. Invocation Format

python when-clock-skill.py --mode <mode> --device-id <device_id> [options...]
--device-id defaults to default (for backward compatibility with single-device config).

3. Mode Quick Reference

ModeDescriptionRequired ArgsDevice Support
chimeVoice time announcementWHEN Voice only
weatherVoice weather broadcastWHEN Voice only
get_alarmQuery all alarmsBoth
set_alarmAdd new alarm--alarm-timeBoth
edit_alarmModify alarm (partial update)--alarm-indexBoth
delete_alarmDelete alarm--alarm-indexBoth
set_timerCountdown timer (single alarm)--timer-offsetBoth

4. Mode Details

4.1 chime — Voice Time Announcement (WHEN Voice only)

Announces current time. WHEN devices do not support this mode.

python when-clock-skill.py --mode chime --device-id device1
python when-clock-skill.py --mode chime --device-id device1 --volume 20

Optional: --volume 1~30 (uses device current volume if not specified)

Output:

{"ok": true, "mode": "chime", "action": "voice_announce_preview", "result": "success", "status": 0, "message": "succ"}

4.2 weather — Weather Broadcast (WHEN Voice only)

WHEN devices do not support this mode.

Note: Weather broadcast currently only supports China region. More regions will be added in future updates.
python when-clock-skill.py --mode weather --device-id device1
python when-clock-skill.py --mode weather --device-id device1 --volume 20

Output:

{"ok": true, "mode": "weather", "action": "voice_weather_preview", "result": "success", "status": 0, "message": "succ"}

4.3 get_alarm — Query Alarm List

python when-clock-skill.py --mode get_alarm --device-id device1
WHEN device alarm entries do not include volume field.

WHEN Voice output example (with volume):

{
  "ok": true,
  "mode": "get_alarm",
  "alarm_count": 2,
  "alarms": [
    {"index": 1, "mode": "Workday", "time": "07:30:00", "ring": "Reveille", "ring_duration_level": "2min", "volume": 20},
    {"index": 2, "mode": "Weekly", "time": "09:00:00", "ring": "Weather(1x)", "ring_duration_level": "30S", "volume": 15, "active_days": ["Mon", "Wed"]}
  ]
}
alarms[].index is the --alarm-index value needed by edit_alarm / delete_alarm.

4.4 set_alarm — Add New Alarm

# Once (default)
python when-clock-skill.py --mode set_alarm --device-id device1 --alarm-time 07:30

# Workdays
python when-clock-skill.py --mode set_alarm --device-id device1 --alarm-mode workday --alarm-time 08:00

# Weekly on specific days
python when-clock-skill.py --mode set_alarm --device-id device1 --alarm-mode weekly --alarm-week 1,2,3,4,5 --alarm-time 08:10

# WHEN Voice - full params
python when-clock-skill.py --mode set_alarm --device-id device1 --alarm-time 07:30 --alarm-ring 5 --alarm-delay 6 --alarm-volume 20

# WHEN - ring only 1-6
python when-clock-skill.py --mode set_alarm --device-id device1 --alarm-time 07:30 --alarm-ring 3

Optional params (use config.json alarm_defaults if not specified):

  • --alarm-mode: once/weekly/workday/restday/off, default once
  • --alarm-week: required for weekly, e.g. 1,2,3,4,5 or Mon,Wed,Fri
  • --alarm-ring: ring ID (WHEN Voice: 1~50, WHEN: 1~6 beep1-beep6)
  • --alarm-delay: duration level (0-based, 0~11)
  • --alarm-volume: volume 1~30 (WHEN Voice only)
Maximum 10 alarms per device.

Output:

{"ok": true, "mode": "set_alarm", "action": "add_alarm", "result": "success", "status": 0, "message": "succ", "alarm_count": 3, "added_alarm": {"mode": "Once", "time": "07:30:00", "ring": "Reveille", "ring_duration_level": "2min", "volume": 20, "active_days": []}}

4.5 edit_alarm — Modify Alarm

Only specified fields are updated; other fields keep original values.

# Change time only
python when-clock-skill.py --mode edit_alarm --device-id device1 --alarm-index 1 --alarm-time 07:45

# Change time and volume (WHEN Voice)
python when-clock-skill.py --mode edit_alarm --device-id device1 --alarm-index 2 --alarm-time 08:30 --alarm-volume 25

# Change to workday mode
python when-clock-skill.py --mode edit_alarm --device-id device1 --alarm-index 1 --alarm-mode workday

--alarm-index is required (use get_alarm to check indices first).

Output:

{"ok": true, "mode": "edit_alarm", "action": "update_alarm", "result": "success", "status": 0, "message": "succ", "alarm_count": 3, "updated_alarm": {"index": 1, "mode": "Once", "time": "07:45:00", "ring": "Reveille", "ring_duration_level": "2min", "volume": 20, "active_days": []}}

4.6 delete_alarm — Delete Alarm

python when-clock-skill.py --mode delete_alarm --device-id device1 --alarm-index 2

--alarm-index is required.

Output:

{"ok": true, "mode": "delete_alarm", "action": "remove_alarm", "result": "success", "status": 0, "message": "succ", "alarm_count": 2, "removed_alarm": {"index": 2, "mode": "Once", "time": "09:00:00", "ring": "Weather(1x)", "ring_duration_level": "30S", "volume": 15, "active_days": []}}

4.7 set_timer — Countdown Timer

Takes current local time + offset, writes as a single-shot alarm to device.

# 5 minutes later (uses config default ring/volume)
python when-clock-skill.py --mode set_timer --device-id device1 --timer-offset 5m

# 1 hour 30 minutes later
python when-clock-skill.py --mode set_timer --device-id device1 --timer-offset 1h30m

# 90 seconds, custom ring and volume (WHEN Voice)
python when-clock-skill.py --mode set_timer --device-id device1 --timer-offset 90s --alarm-ring 5 --alarm-volume 20

--timer-offset format: 5m, 1h, 1h30m, 90s, 1h30m20s. Plain number treated as minutes.

Output:

{"ok": true, "mode": "set_timer", "action": "add_timer", "result": "success", "status": 0, "message": "succ", "alarm_count": 3, "timer": {"offset": "5m", "offset_seconds": 300, "trigger_at": "14:35:00", "ring": "Reveille", "ring_duration_level": "2min", "volume": 20}}

5. Ring Tone Reference

WHEN Voice (50 tones, common)

IDNameIDName
1Weather(1x)2Weather(2x)
3Weather(3x)4Beep-1
5Reveille6Rest Call
43Morning44Evening
49Chinese-style music-150Chinese-style music-2

WHEN (6 tones)

IDName
1beep1
2beep2
3beep3
4beep4
5beep5
6beep6
Full WHEN Voice list in config.json alarm_defaults_note.ring_id_name.

6. Important Conventions

  • Alarm index (--alarm-index) is 1-based, starting from 1
  • Ring ID (--alarm-ring) is 1-based, internally converted to device 0-based
  • Volume range 1~30, sent as volume-1 (WHEN Voice only)
  • WHEN device has no volume parameter, ring fixed to beep1-beep6
  • Maximum 10 alarms per device
  • config.json devices array must have valid id and clock_ip, or script exits with code 2
  • Check success: prefer ok == true, fallback to status == 0
  • Errors to stderr, normal JSON to stdout

7. Exit Codes

CodeMeaning
0Success
1Device returned failure status
2Argument / config / response format error
3HTTP error
4Network error

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

74.42%
按下载量换算1,015

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills