HomeElectronics NewsThis ESP32 Turns Plain English Into Automation

This ESP32 Turns Plain English Into Automation

Describe a task in Telegram, and this ESP32 firmware can turn it into a hardware rule that continues running without an AI connection.

An ESP32 development board can turn plain-English instructions into hardware automation using WireClaw, an open-source firmware project available on GitHub. It allows users to configure sensors, LEDs, relays and automation rules through natural-language commands, reducing the need to write code for every task.

For example, a user can ask the system to switch on a fan when the temperature exceeds 28°C. WireClaw uses a large language model (LLM) to interpret the instruction and configure the corresponding rule. Once created, the rule runs on the ESP32 without requiring further requests to the AI model. This allows configured automation to continue even if the internet connection or AI service becomes unavailable.

The project describes itself as an AI agent for a low-cost microcontroller. However, the ESP32 does not run the large language model itself. Instead, the firmware communicates with a cloud-based model or a compatible local model server, while its rule engine handles the configured automation locally.

WireClaw supports ESP32-C6, ESP32-S3 and ESP32-C3 boards with at least 4MB of flash memory. The firmware is released under the MIT licence, allowing developers to inspect, modify and redistribute the code under the licence’s terms.

The project supports communication through Telegram, serial interfaces and NATS, providing different ways to interact with the hardware. Its examples demonstrate sensor monitoring, LED control, relay operation, persistent preferences and automated alerts.

The basic setup requires a supported ESP32 development board, a USB data cable and a Wi-Fi connection. External components such as an NTC thermistor, a current-limiting resistor and an LED can be added to experiment with sensor-based automation. A suitable relay module can control a low-voltage load, such as a small fan.

To communicate through Telegram, users need a bot token and the required chat details. For cloud-based AI processing, WireClaw can use an API key from a supported service, such as OpenRouter. Alternatively, users can configure a compatible local language-model server, including Ollama or llama.cpp, to avoid per-request cloud API charges.

The firmware can be installed using the project’s browser-based flasher, which supports compatible browsers such as Chrome and Edge through WebSerial. After flashing, the ESP32 provides a Wi-Fi access point for initial configuration. Users can connect to it and enter their network credentials, model settings and messaging details.

Developers who prefer to build the firmware themselves can use PlatformIO. The project’s GitHub repository provides the source code and documentation, including examples showing how to register sensors and actuators and create rules from natural-language instructions.

For instance, a user can register a temperature sensor, assign a relay to a fan and instruct the system to switch on the fan when the temperature exceeds a specified threshold. WireClaw stores configured rules in flash memory, allowing them to survive a restart.

The firmware also supports persistent memory for retaining information across conversations and reboots. A user could specify a preferred LED colour and later ask the system to use that colour. This feature is separate from the rule engine, which evaluates conditions and performs configured actions.

WireClaw can also integrate with OpenClaw, an AI agent that runs separately on another computer. The integration uses a NATS message server to allow the external agent to discover and control supported hardware through WireClaw. This provides a route to more complex automation without requiring WireClaw’s own language-model interaction to handle every hardware command.

According to the project’s README, the firmware uses approximately 196KB of RAM out of the stated 320KB and 1.3MB of 2.5MB of flash. The project also reports that the rule engine occupies around 6.2KB, while the language-model request buffer requires 20KB. These are project-reported figures and may vary with the firmware configuration.

However, WireClaw is intended for experimentation and general automation rather than safety-critical control. Rules are evaluated periodically, so the system should not be treated as a hard real-time controller. Network-dependent functions, including Telegram notifications, also require connectivity. Users should protect their API keys and bot tokens and restrict network services such as NATS to trusted environments.

Relay-based projects require additional care. Beginners should start with low-voltage loads and check the relay’s voltage and current ratings. Mains-powered appliances require properly rated, enclosed switching hardware and safe electrical installation.

For electronics students and makers in India, WireClaw offers a practical way to experiment with AI-assisted automation using ESP32 development boards and commonly used sensors. Engineering students can use it to build temperature-controlled fans, sensor-monitoring systems and Telegram-based alerts without writing all the automation logic from scratch. Those who want to avoid recurring cloud API charges can also experiment with a local language model running on a suitable computer, although this requires additional hardware and electricity. Starting with low-voltage devices makes the project more suitable for laboratory experiments and home prototypes.

For more information, click here.

Loading form…
Ananthu Ashok
Ananthu Ashok
Ananthu Ashok is a tech journalist and has a deep interest in embedded systems, open source, IoT, robotics and emerging tech.

SHARE YOUR THOUGHTS & COMMENTS

Latest DIY Projects

Electronics News

Truly Innovative Electronics

Electronics Components

Electronics Jobs