**6. Advanced smart home**

In this section, we focus on the integration of smart home, IoT and cloud computing to define a new computing paradigm. We can find in the literature section [11–14] surveys and research work on smart home, IoT and cloud computing separately, emphasizing their unique properties, features, technologies, and drawbacks. However, our approach is the opposite. We are looking at the synergy among these three concepts and searching for ways to integrate them into a new comprehensive paradigm, utilizing its common underlying concepts as well as its unique attributes, to allow the execution of new processes, which could not be processed otherwise.

**Figure 3** depicts the advanced smart-home main components and their interconnectivity. On the left block, the smart home environment, we can see the typical

devices connected to a local area network [LAN]. This enables the communication among the devices and outside of it. Connected to the LAN is a server and its database. The server controls the devices, logs its activities, provides reports, answers queries and executes the appropriate commands. For more comprehensive or common tasks, the smart home server, transfers data to the cloud and remotely activate tasks in it using APIs, application programming interface processes. In addition, IoT home appliances are connected to the internet and to the LAN, and so expands smart home to include IoT. The connection to the internet allows the end user, resident, to communicate with the smart home to get current information and remotely activate tasks.

To demonstrate the benefits of the advanced smart home, we use RSA, a robust asymmetric cryptography algorithm, which generates a public and private key and encrypts/decrypts messages. Using the public key, everyone can encrypt a message, but only these who hold the private key can decrypt the sent message. Generating the keys and encrypting/decrypting messages, involves extensive calculations, which require considerable memory space and processing power. Therefore, it is usually processed on powerful computers built to cope with the required resources. However, due to its limited resources, running RSA in an IoT device is almost impossible, and so, it opens a security gap in the Internet, where attackers may easily utilize. To cope with it, we combine the power of the local smart home processors to compute some RSA calculations and forward more complicated computing tasks to be processed in the cloud. The results will then be transferred back to the IoT sensor to be compiled and assembled together, to generate the RSA encryption/decryption code, and so close the mentioned IoT security gap. This example demonstrates the data flow among the advanced smart home components. Where, each component performs its own stack of operations to generate its unique output. However, in case of complicated and long tasks it will split the task to sub tasks to be executed by more powerful components. Referring to the RSA example, the IoT device initiates the need to generate an encryption key and so, sends a request message to the RSA application, running in the smart home computer. The smart home computer then asks the "prime numbers generation" application running on cloud, to provide *p* and *q* prime numbers. Once *p* and *q* are accepted, the encryption code is generated. In a later stage, an IoT device issues a request to the smart home computer to encrypt a message, using the recent generated RSA encryption key. The encrypted message is then transferred back to the IoT device for further execution. A similar scenario may be in the opposite direction, when an IoT device gets a message it may request the smart home to decrypt it.

To summarize, the RSA scenarios depict the utilization of the strength of the cloud computing power, the smart home secured computing capabilities and at the end the limited power of the IoT device. It proves that without this automatic cooperation, RSA would not be able to be executed at the IoT level.

A more practical example is where several detached appliances, such as an oven, a slow cooker and a pan on the gas stove top, are active in fulfilling the resident request. The resident is getting an urgent phone call and leaves home immediately, without shutting off the active appliances. In case the relevant IoTs have been tuned to automatically shut down based on a predefined rule, it will be taken care at the IoT level. Otherwise, the smart home realizes the resident has left home [the home door has been opened and then locked, the garage has been opened, the resident's car left, the main gate was opened and then closed, no one was at home] and will shut down all active devices classified as risk in case of absence. It will send an appropriate message to the mailing list defined for such an occasion.

**33**

**Figure 4.**

*Advanced smart home composition.*

*Smart Home Systems Based on Internet of Things DOI: http://dx.doi.org/10.5772/intechopen.84894*

tants, switches, locks, energy and water meters.

and the connection and data flow among its components.

**smart home**

level ultrasonic sensors.

**7. Practical aspects and implementation considerations for IoT and** 

Smart home has three components: hardware, software and communication protocols. It has a wide variety of applications for the digital consumer. Some of the areas of home automation led IoT enabled connectivity, such as: lighting control, gardening, safety and security, air quality, water-quality monitoring, voice assis-

Advanced smart home components include: IoT sensors, gateways, protocols, firmware, cloud computing, databases, middleware and gateways. IoT cloud can be divided into a platform-as-a-service (PaaS) and infrastructure-as-a-service (IaaS). **Figure 4** demonstrates the main components of the proposed advanced smart home

The smart home application updates the home database in the cloud to allow remote people access it and get the latest status of the home. A typical IoT platform contains: device security and authentication, message brokers and message queuing, device administration, protocols, data collection, visualization, analysis capabilities, integration with other web services, scalability, APIs for real-time information flow and open source libraries. IoT sensors for home automation are known by their sensing capabilities, such as: temperature, lux, water level, air composition, surveillance video cameras, voice/sound, pressure, humidity, accelerometers, infrared, vibrations and ultrasonic. Some of the most commonly used smart home sensors are temperature sensors, most are digital sensors, but some are analog and can be extremely accurate. Lux sensors measure the luminosity. Water

Float level sensors offer a more precise measurement capability to IoT developers. Air composition sensors are used by developers to measure specific components in the air: CO monitoring, hydrogen gas levels measuring, nitrogen oxide measure, hazardous gas levels. Most of them have a heating time, which means that it requires a certain time before presenting accurate values. It relies on detecting gas

*Internet of Things (IoT) for Automated and Smart Applications*

remotely activate tasks.

the smart home to decrypt it.

devices connected to a local area network [LAN]. This enables the communication among the devices and outside of it. Connected to the LAN is a server and its database. The server controls the devices, logs its activities, provides reports, answers queries and executes the appropriate commands. For more comprehensive or common tasks, the smart home server, transfers data to the cloud and remotely activate tasks in it using APIs, application programming interface processes. In addition, IoT home appliances are connected to the internet and to the LAN, and so expands smart home to include IoT. The connection to the internet allows the end user, resident, to communicate with the smart home to get current information and

To demonstrate the benefits of the advanced smart home, we use RSA, a robust

asymmetric cryptography algorithm, which generates a public and private key and encrypts/decrypts messages. Using the public key, everyone can encrypt a message, but only these who hold the private key can decrypt the sent message. Generating the keys and encrypting/decrypting messages, involves extensive calculations, which require considerable memory space and processing power. Therefore, it is usually processed on powerful computers built to cope with the required resources. However, due to its limited resources, running RSA in an IoT device is almost impossible, and so, it opens a security gap in the Internet, where attackers may easily utilize. To cope with it, we combine the power of the local smart home processors to compute some RSA calculations and forward more complicated computing tasks to be processed in the cloud. The results will then be transferred back to the IoT sensor to be compiled and assembled together, to generate the RSA encryption/decryption code, and so close the mentioned IoT security gap. This example demonstrates the data flow among the advanced smart home components. Where, each component performs its own stack of operations to generate its unique output. However, in case of complicated and long tasks it will split the task to sub tasks to be executed by more powerful components. Referring to the RSA example, the IoT device initiates the need to generate an encryption key and so, sends a request message to the RSA application, running in the smart home computer. The smart home computer then asks the "prime numbers generation" application running on cloud, to provide *p* and *q* prime numbers. Once *p* and *q* are accepted, the encryption code is generated. In a later stage, an IoT device issues a request to the smart home computer to encrypt a message, using the recent generated RSA encryption key. The encrypted message is then transferred back to the IoT device for further execution. A similar scenario may be in the opposite direction, when an IoT device gets a message it may request

To summarize, the RSA scenarios depict the utilization of the strength of the cloud computing power, the smart home secured computing capabilities and at the end the limited power of the IoT device. It proves that without this automatic

A more practical example is where several detached appliances, such as an oven, a slow cooker and a pan on the gas stove top, are active in fulfilling the resident request. The resident is getting an urgent phone call and leaves home immediately, without shutting off the active appliances. In case the relevant IoTs have been tuned to automatically shut down based on a predefined rule, it will be taken care at the IoT level. Otherwise, the smart home realizes the resident has left home [the home door has been opened and then locked, the garage has been opened, the resident's car left, the main gate was opened and then closed, no one was at home] and will shut down all active devices classified as risk in case of absence. It will send an appropriate message to the mailing list defined for such

cooperation, RSA would not be able to be executed at the IoT level.

**32**

an occasion.
