Z-Wave – Basics of wireless technology for the smart home
House Radio

© Lead Image © file404, 123RF.com
Z-Wave connects components in the smart home and ensures that remote commands from the control station take effect on real household appliances. We look at how it works, its range, the security of the protocol, and some basics that every Z-Waver should know.
The door lock opens when the owner's mobile phone approaches the entrance. The light in the apartment switches on when the motion detector senses a being walking around and the light sensor determines that it is night. The garage door closes automatically when the car drives in, and a controller detects that the absent-minded driver once again forgot to press the close button on the garage gate before leaving through the back door, so the gate now closes itself.
These automatic actions are no longer a smart home fiction; they are available right now. However, before pressing the "Buy" button, house owners have to decide which method to use when sensors are picking up signals and report them to the controller, which then in turn initiates actions to control real physical household devices.
Simply Wireless
Not everyone is likely to build their own new home so they are able to route cables in the walls for all kinds of playful extravagances; wireless solutions work around these limitations for the common man. In the 1990s, hobbyists who had a knack for tinkering, mainly in the United States, began to switch lamps or even household appliances on and off with a technology called X10. Signals were transmitted either via power lines or wireless RF technology. But X10 did not offer reliable communication; it was often impossible to say with certainty whether a device had actually received a transmitted signal.
In the United States, where imperfection and unreliability are more easily accepted, the product fared quite well, but in Europe, it never caught quite on. Along with other wireless alternatives (e.g., ZigBee [1], EnOcean [2], and good old WiFi), the Z-Wave Protocol was launched in the 1990s [3] by a Danish company named Zensys. In 2008, chip maker Sigma Designs [4] acquired the rights to Z-Wave.
The industrial consortium Z-Wave Alliance, to which some 300 corporations with approximately 1,000 certified products belong today, guides the development and the certification of new products. Hobbyists can build small solutions for little money that they then can extend piece by piece to a professionally automated smart home with dozens of components.
Acknowledgement Needed
On a wireless Z-Wave network, the brains of the system are called controllers. They send commands to actuators, called slaves, which then initiate actions. As an example, a laptop with a USB stick like the one shown in Figure 1 acts as a controller and uses a wireless radio connection to control the mains switch in Figure 2, the slave, which turns electrical consumers such as a lamp or another computer on and off.


To set up new gadgets on the network, you will usually find a button to press on the device, for example at the side on the mains switch in Figure 2. This causes the device to advertise its presence on the network and any listening controllers, such as the USB stick in Figure 1, whom the user also switches to a special integration mode. The controller then picks up the beacon from the new gadget and teaches it its new name on the network, making sure that it knows which wireless commands it needs to pick off the air and respond to going forward.
The process is similar for deregistering a device from the network; the user typically has to confirm on the unit itself, usually by pushing a button, that the device is now leaving the collective.
Once integrated, the controller and slave rely on a handshake protocol in which the slave confirms the receipt of commands sent by the controller. When the slave's ACK reaches the controller, as shown in the top part of Figure 3, the controller knows that the slave has received and validated the packet with the command. It says nothing about whether the slave was able to execute the command or whether the desired effect has occurred. A subsequent status request sent by the controller to the slave can obtain clarity on the matter.

Until recently it was only possible to learn the details of the protocol by purchasing an expensive SDK from Sigma Designs, but the company finally released the Z-Wave specification online in September 2016 [3]. The Z-Wave Consortium still insists on the certification of new equipment, so nobody can simply dump new Z-Wave devices on the market. To certify a new gadget, you need to register as a commercial development partner. However, the specification allows hobbyists to write their own control software, for example for the controller in Figure 1.
Fault Tolerance
In the case of an unreliable wireless connection, it can happen that, as shown in the middle part of Figure 3, the command from the controller does not even reach the slave, or that the slave receives the command and sends an ACK, but it does not make its way back to the controller (bottom of Figure 3). In both cases, the controller simply assumes that the command failed and repeats the procedure up to two times. If the third attempt also fails, the controller reports an error and assumes that the connection to the slave is down.
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you've found an article to be beneficial.
News
-
The GNU Project Celebrates Its 40th Birthday
September 27 marks the 40th anniversary of the GNU Project, and it was celebrated with a hacker meeting in Biel/Bienne, Switzerland.
-
Linux Kernel Reducing Long-Term Support
LTS support for the Linux kernel is about to undergo some serious changes that will have a considerable impact on the future.
-
Fedora 39 Beta Now Available for Testing
For fans and users of Fedora Linux, the first beta of release 39 is now available, which is a minor upgrade but does include GNOME 45.
-
Fedora Linux 40 to Drop X11 for KDE Plasma
When Fedora 40 arrives in 2024, there will be a few big changes coming, especially for the KDE Plasma option.
-
Real-Time Ubuntu Available in AWS Marketplace
Anyone looking for a Linux distribution for real-time processing could do a whole lot worse than Real-Time Ubuntu.
-
KSMBD Finally Reaches a Stable State
For those who've been looking forward to the first release of KSMBD, after two years it's no longer considered experimental.
-
Nitrux 3.0.0 Has Been Released
The latest version of Nitrux brings plenty of innovation and fresh apps to the table.
-
Linux From Scratch 12.0 Now Available
If you're looking to roll your own Linux distribution, the latest version of Linux From Scratch is now available with plenty of updates.
-
Linux Kernel 6.5 Has Been Released
The newest Linux kernel, version 6.5, now includes initial support for two very exciting features.
-
UbuntuDDE 23.04 Now Available
A new version of the UbuntuDDE remix has finally arrived with all the updates from the Deepin desktop and everything that comes with the Ubuntu 23.04 base.