Give any AI agent the ability to sense and act in the physical world.
pip install httpx paho-mqtt
config.json (skill directory):{
"api_url": "https://realworldclaw-api.fly.dev/api/v1",
"devices": [
{
"name": "my-esp32",
"ip": "192.168.x.x",
"access_code": "xxxxxxxx",
"serial": "xxxxxxxxxxxx",
"type": "esp32"
}
]
}
python3 scripts/rwc.py sense --device my-esp32
Returns temperature, humidity, and other connected sensor values.
python3 scripts/rwc.py act --device my-esp32 --action relay_on
python3 scripts/rwc.py act --device my-esp32 --action relay_off
python3 scripts/rwc.py act --device my-esp32 --action led --value '{"r":255,"g":0,"b":0}'
python3 scripts/rwc.py rule add --name "cool-down" \
--condition "temperature > 30" \
--action "relay_on" \
--device my-esp32
python3 scripts/rwc.py status
python3 scripts/rwc.py devices
python3 scripts/rwc.py api health
python3 scripts/rwc.py api modules
python3 scripts/rwc.py api register --username x --email x --password x
| Command | Description |
|---|---|
| --------- | ------------- |
status | Show all device status |
devices | List configured devices |
sense --device NAME | Read all sensors from device |
act --device NAME --action ACTION | Execute actuator command |
rule add/list/remove | Manage automation rules |
api health/modules/register/login | Platform API access |
monitor --device NAME --interval 5 | Continuous monitoring mode |
Devices expose capabilities via manifest. Read references/protocol.md for full spec.
AI Agent (OpenClaw)
↓ skill command
RWC Skill (this)
↓ MQTT (local) or HTTP (cloud)
ESP32 Module
↓ GPIO
Physical World (sensors/actuators)
Local MQTT is preferred for low latency. Cloud API for remote access.
共 1 个版本