# Wireless Sensor Networks for Smart Homes:
## 1 Introduction  
In the last few years, technological progress in the wireless communication, energy consumption, and chip miniaturization have facilitated the growth and the deployment of original applications based on Wireless Sensor Networks (WSNs) [1; 2; 3; 4; 5]. Several works have been published in the research fields related to WSNs, and many architectures [6; 7; 8] and protocols [9; 10; 11] have been produced. Typical WSNs are not complicated monitoring systems, whose applications embrace environment monitoring [12], infrastructure security [13], industrial sensing [14] and intelligent transportation systems [15]. In these WSNs, sensors collect the demanded information, frequently according to a fixed temporal schedule, and transmit it to the sink, which interfaces with a server or a computer. The nodes of a WSN are typically battery-powered and equipped with low-performance processors and small memories to decrease the power requirements. The power consumption represents a crucial problem in WSNs. For instance, a battery-operated sensor device that wakes up once every few minutes to examine an environmental parameter requires to spend as little power as possible to lessen the battery replacement. In several instances, nodes can be disposed of in harsh conditions, such as underwater or underground, where the battery replacement could be a tricky procedure. Accordingly, the extension of the network lifetime is a critical issue. In general home automation, WSNs serve several home device controllers, such as HVAC, lights, doors, and more [16; 17; 18]. The open problem, in the contemporary transition period, is to adopt those new home automation technologies into already built and furnished houses, minimizing the annoyance during the installation phase. For this reason, the power management is a crucial factor, and despitethe vastness of smart homes literature [19; 20; 21; 22; 23; 24; 25], it is still challenging to state that the batteries life issue has been solved. Recently, two classes of parallel procedures have been utilized to face up the problem related to energy consumption, i.e., power management and energy scavenging methods [26]. The above techniques gain the energy from the monitored environment, e.g., employing photo-voltaic cells [27], vibration or motion-driven micro-electromechanical devices [28], thermoelectric converters [29], or particular radio frequency receivers [30]. Other approaches move intelligence and analytic capacities into the network to achieve better utilization of the limited energy resources at IoT nodes, with fewer transmissions leading to less network load and a higher data yield. This solution is known as edge mining, or data mining that takes place on wireless, battery- powered, smart sensing devices that sit at the edge of the IoT network [31; 32; 33]. The application of this method reduces the transmissions number but, at the same time, involves various overheads leading to a small additional increase in devices lifetime. On the contrary, power management methods rely on hardware and/or software solutions that momentarily disable those components which are unused or underused. In particular, since the radio part is frequently the most power-hungry characteristic of a WSN node, the appropriate control of the duty cycle is significant to extend the battery life. For instance, the amount of consumed power could be significantly diminished through energy-efficient routing schemes [34; 35] to find, among all the possible communication paths, which one lessens the energy consumption. Besides, the nodes can be grouped through a clustering algorithm. In this way, the data obtained by the nodes of a cluster can be aggregated and lessened by the cluster head before being sent, with a consequent energy saving [36; 37]. At the data link layer, a Medium Access Control (MAC) protocol can implement energy-efficient methods for managing multiple accesses to the wireless channel. The differences among the existing MAC protocols are moved by the variety of WSN in which they are applied.