# MAC Layer Protocols for Internet of Things: A Survey
## 2 Short Range MAC Layer Protocols
### Z-Wave  
Z-Wave was developed and is overseen by the company Zensys to provide wireless communication between devices with a focus on residential automation. Monitoring and controlling of lighting, ambient temperature and security through sensors and actuators by tablets, smartphones or computers are some applications in its portfolio. Z-Wave devices are arranged in mesh network topology. They can send and receive messages from any device that is connected to the network [59; 60]. The protocol is a proprietary standard based on the ITU G.9959 specification that operates in the Industrial, Scientific, and Medical (ISM) radio frequency band. Z-Wave transmits on 868.42 MHz (Europe) and 908.42 MHz (United States) frequencies working with FSK and Gaussian Fase Shift Keying (GFSK) modulations. With low transmission rates of 9.6 Kbps, 40 Kbps and 100 Kbps, it employs symmetric AES-128 encryption. The MAC layer uses the CSMA-CA technique for a medium access  
Figure 12: WirelessHART Protocol Stack. control technique and, based on ITU G.9959, has the following characteristics: a capacity of 232 unique network identifiers that allows the same quantity of nodes joying the network; collision avoidance mechanism; back-off time when collision occurs; reliability guaranteed by receiving acknowledgments; frame validation and retransmission mechanisms. A power saving mechanism is achieved due to a sleep mode with a dedicated wake-up pattern [61; 62]. Figure 13 depicts the Z-Wave protocol stack. The Z-Wave basic device classes are the following: Portable Controller, Static Controller, Slave, and Slave with Routing Capabilities. Different classes provide the device with a certain role in the Z-Wave network. Inside a Basic Class, Generic and Specific device classes are used to achieve the wanted functionality in the control network. In the Z-Wave protocol, the unique identification of the devices is used through a 32-bit ID. This ID value cannot be changed as it is written in the device chipset by the device manufacturer. A Z-Wave network has only one primary controller device at a time. Each of the 232 nodes of this network can also be a repeater for forwarding data to its neighbors, mediating a connection. Battery-powered nodes do not enjoy this facility. In an environment with a certain level of device drift or even when a device is removed from the network for some reason, the network topology may change. Changing network topology can lead to problems in packet forwarding and packet routing in the network. To minimize this effect, routing tables should be kept up-to-date, optimized and any new topology detected; Z-Wave supports the discovery and suitability of the new network topology. This is possible by keeping the routing table up-to-date on each device and showing all neighboring devices [61; 63]. When a node changes its position or is removed from the network, a topology failure can start an automatic topology and healing procedure to detect the new topology and define the best routes to update the routing tables. This mechanism is subjected to unauthorized modification of routing table attacks by rouge nodes [64]. The transfer (or transport) layer management functions are: communication between two neighbor nodes, packet acknowledgment, low power network nodes awake (Beaming), and packet origin authentication. This layer controls the _Beam_ frames used to wake-up battery powered Z-Wave devices, as each primary controller device of a cluster can handle up to 232 nodes. All nodes can act as a packet repeater, except those devices that are batteries powered. This is Z-Wave mesh topology formed [65]. Z-Wave data security is based on AES and on the cipher block chaining message authentication code (CBC-MAC). However, standards and rules for command classes, device types and timers are missing. These characteristics are only acquired in the new advanced security framework (S2) determined by the Z-Wave Alliance and developed in conjunction with the cyber security community.