
What a device can do
A Zigbee device describes what it can do as endpoints, clusters, attributes and commands. This lesson opens a light's On/Off cluster, presses On and reads the attribute back.
The question
A controller that has never seen a particular light can still turn it on. It can do that because the light describes itself in a fixed vocabulary, and the controller reads the description. The vocabulary has four words: endpoint, cluster, attribute and command.
Endpoints
Endpoint 0 is the device object, which every device has and which deals with the device itself. Application endpoints are numbered 1 to 240, and each is a separate function. A device with a light and a button in one housing can carry both on different endpoints.
Clusters, attributes and commands
A cluster is a group of related things, and it has a numeric identifier. On/Off is cluster 0x0006. Inside it an attribute holds a value, and a command asks for something. The OnOff attribute is 0x0000, and the commands are Off 0x00, On 0x01 and Toggle 0x02.
A cluster also has two sides. The light holds the state and obeys the commands, so it is the server of On/Off. A wall switch carries the client side, which sends them. A switch and a light match because their clusters match, and that is why a binding in the next lesson needs the same cluster on both ends.
A command asks. An attribute is what you read back. Send On, then read OnOff, and the pair tells you the request landed.
Values have units
The temperature cluster is 0x0402 and its MeasuredValue is in units of 0.01 degree Celsius. The number 2150 means 21.50 degrees. The unit and the scale are part of the definition, so a reading with neither is half a fact.
A label is not a promise
A box can list a feature, and a cluster list can name a cluster, while the product implements only part of it. The evidence is what the device reports when it is asked. A controller that shows a feature the device does not have will send commands that nothing answers, and the symptom looks like a flaky radio when it is a missing implementation.
The course returns to this on the ESP32 bench, where the endpoint you declare in code is the one the network sees. See the Zigbee, Thread and Matter chapter for how a chip declares them.
Common mistakes
- Treating endpoint 0 as the light. It is the device object. The light's function lives on an application endpoint.
- Reading a command as the state. On is a request. Read the OnOff attribute to know what the light did.
- Trusting the box. A listed feature is a claim. The reported clusters are the evidence.
Edit this page — content/fundamentals/zigbee/what-a-device-can-do.mdx
Discuss this article
Ask about this page. The answer stays here, on the page it belongs to, for whoever hits the same wall next.