KS KS Smart System
GitHub

Open source · Free · Self-hosted

Change your smart home by editing a script — no reflashing, no soldering iron

KS Smart System makes your ESP32 and ESP8266 nodes controllable from a single .kst script. Wire the hardware once. After that, every switch, sensor, and transmitter is a line you can rewrite live over encrypted MQTT — no firmware uploads, no multimeter.

Runs on ESP32 / ESP8266 · Mosquitto MQTT · Python interpreter · Arduino framework

Today, changing your smart home means changing your firmware

Add a sensor. Move a switch. Adjust one timing rule. With most DIY setups you are back at the desk with a USB cable, flashing micro-controllers one by one — and reaching for the soldering iron when the wiring changes. KS Smart System separates the hardware from the behavior, so the second part never sends you back to the bench.

Wire once. Then live in the script.

Think of .kst as a programming language for your home. You stop thinking in volts and pins and start thinking in switches, sensors, and transmitters — the primitives that define your system.

01

Set up the nodes

Flash KS_NODE to your ESP32/ESP8266 devices once and give each a unique index. From here on, the hardware stays put.

02

Describe behavior in .kst

Write the rules of your system in a script. The interpreter delegates instructions to nodes, reads their responses, and applies the values you defined.

03

Rewrite it live

Push a new script through the admin channel and the running system changes — no restart, no re-flash, no trip back to the soldering iron.

What you get

No more reflashing for every tweak

Once your nodes are up, you make changes in the script — not in firmware. No USB cable per device, no multimeter, no soldering iron for a behavior change.

Edit the system while it runs

An admin MQTT topic lets you send commands and swap the working script in real time, without restarting the whole system. The same channel is the seam for building an API on top.

Private by default, yours to keep

Free and open source. Communication runs over encrypted MQTT with a self-signed certificate out of the box. Your home runs on your hardware — no required cloud account, no vendor lock-in.

Point an AI agent at it experimental

A dedicated admin unit exposes the system to AI agents. Integration has been tested with Hermes and OpenCode and local models like Gemma 3 and Nemotron 3 Nano. It is early — switching works today, with more agent-driven control on the roadmap.

What's inside

Mosquitto MQTT carries every message. Each node sees only its own topic; the interpreter sees them all, plus an admin topic for live control.

AAU · Python

The interpreter

Reads your .kst script, delegates instructions to nodes, and applies the values they send back. It holds the admin topic for real-time changes.

KS_NODE · Arduino

The node firmware

Runs on ESP32 and ESP8266 micro-controllers. Set your values in node.hpp, upload once, and the node listens on its own topic.

AU · Python

The admin unit

A standalone app that talks to the interpreter over the admin channel. Runs as a CLI or a TCP server, and is the entry point for AI integration.

Watch it set up, step by step

Build a home you can rewrite

It's free and open source. Clone the repo, flash your nodes, and start describing your system in script.

Get the code on GitHub Follow the install tutorial