Raspberry PI 3 B + microcomputer as a central control unit in intelligent building automation management systems

This article aims to show the possible savings in electricity costs in smart building installations with the use of new version of Raspberry Pi 3 model B + as the control unit in intelligent building automation systems. It presents a comparison of the consumption of electricity in two units used in the central control systems, i.e. a small Windows-based computer and a Raspberry microcomputer. The power consumption of these units was measured during the rest period and during standard operations in the intelligent installation system. The conducted measurements proved that the use of the new updated version of Raspberry Pi 3 model B + as the central control unit in intelligent building management systems is more economical and energy-saving.


Introduction
The research was aimed at showing the possibility of saving electricity in intelligent building installations due to the use of the updated Raspberry Pi model 3B + version applied as the central unit.The main objective of the research was to check the power consumption when standard activities were performed.Two units were used in the research, i.e. a small Windows-based computer and a Raspberry microcomputer.To conduct the study, a PC computer with the lowest energy consumption was selected and its results were compared with those of the new version of Raspberry Pi model 3B +.

Fig. 1. Raspberry Pi 3B + microcomputer module
The Raspberry Pi 3B + module is a miniature equivalent of a full-fledged personal computer in a miniaturized form.The external dimensions of the microcomputer are only 86 x 54 mm [11].This miniature case holds all the components necessary to use the microcomputer as an ordinary personal computer [10].The most important point of the device is the 64-bit Broadcom BC2837 ARM-8 quad-core processor with the integrated Cortex -A53 graphics.The operating memory in model 3B + has been increased to 1GB and a MicroSD card is used as the hard disk, which is inserted into the device reader.Such a solution allows each user to adapt the card's capacity to the current needs and the way the microcomputer is used.The memory card installs one of many dedicated operating systems adapted to perform specific tasks, such as an office computer, home multimedia center, mini game console, smart TV, smart home center, computer programmer and many more.An additional memory module for storing data may be attached − a USB stick (pendrive) or external USB hard drives.The primary source of power for the Raspberry Pi 3B + model is the microUSB connector.The nominal supply voltage is 5W; however, as the technical data indicate, the maximum power that a microcomputer can take is about 6W [4].Still, it should be remembered that the microcomputer also powers all peripherals connected to it.The desktop power consumption during the running state without any applications is about 3W of energy.It is, therefore, incomparably less than in the case of PCs or other multimedia devices [9].Five-volt power supply and very low power consumption make this microcomputer an ideal solution for all projects where continuous operation or long battery life is required [5].
The central control units were placed in the existing intelligent house installation as central units of the intelligent building automation system.Initially, no devices were attached to the system.They were gradually integrated into the system to allow central units servicing successive devices to measure the power consumption.Finally, the installation allowed for controlling lighting, electrical sockets and elements connected to them, ass well as monitoring the conditions in the apartment (temperature, humidity, flooding, motion).The Domoticz software was chosen and installed on the central units as it allows for operating all devices.The executive modules were based on AtMEGA 2560 microcontrollers and, controlled by them, semiconductor and mechanical relay modules.All sensors were also connected directly to the AtMEGA microcontroller [7].
Lighting control is possible both by means of monostable buttons placed in the wall where installation connectors are usually placed and with the help of an application available for almost all hardware platforms or websites [2].The control of electrical sockets is carried out only through an application or a website.Readings from all sensors are sent to the Domoticz software on an ongoing basis, where they are interpreted arbitrarily, which enabled creating statistics and taking actions based on the values of the read parameters [3].
The use of motion sensors allowed for taking programmed actions after detecting motion in a given room.Such an opportunity allows one to turn on the light in the lobby for a pre-programmed time when motion is detected, for example, when entering through the entrance door or going to the bathroom or kitchen [7].After the programmed time expires, the light automatically switches off without the need to press any buttons.In the case of other sensors, no action is taken after motion detection, only the date and time data provided by the motion sensor are saved.

Fig. 2. Applied CPU (PC)
As the other central unit, a miniature PC computer located in a case was used.Similarly as in the case of Raspberry Pi, the Domoticz system was installed in this unit and all the devices in the system were connected to it.An additional advantage of using the Raspberry Pi model are its outputs / inputs (GPIO).The general purpose input / output GPIO is a type of interface intended for communication between peripheral devices and the microprocessor [7].The Raspberry Pi 3B + model has a GPIO interface consisting of 40 Goldpin pins in two rows of twenty about 2.54 pitch raster (pin spacing).Each of the pins can be configured as an input or output in the control programme, with some pins performing additional functions [8].As in the case of pins 3 and 5 (Figure 3), they can act as ordinary inputs and outputs but, at the same time, they serve as communication pins for the I2C interface.Similarly, the pins of UART, SPI and PWM interfaces have been led out.The above pins can be used to directly control home automation devices without the need of supplying additional drivers.

Fig. 3. Description of GPIO raspberry Pi 3B + pins 2 Description of the conducted research
The research was conducted in several stages.The first was the installing the central unit, setting it and launching at home by the automated management system which uses it.First, a PC was used, and then a Raspberry Pi 3B + model.Afterwards, all devices and their controllers were disconnected from the system so that the consumption of power by the central unit could be measured.Each measurement lasted one hour during which the system performed specific operations identical for both central units.The values of electricity consumption were recorded every ten seconds and the final result was the arithmetic mean taken from the received data.To measure the power consumption of the system itself, the central units remained active, but did not control any devices.After an hour measurement of the power consumption with disconnected devices, a light controller based on the AtMega 2560 microprocessor was attached.During the one-hour measuring cycle in one of the rooms, the light was lit and turned off sixty times.It should be remembered that the logic part of the controller was powered from the central unit, whereas light was supplied directly from the electricity network.The resulting arithmetical mean was also derived from the received data.
The next step was to disconnect the light controller and turn on the plug-in controller.Again, the measurement lasted one hour, during which one of the switches was turned on and off sixty times.The next tested driver was the temperature sensor driver.During an hour measurement, the sensors read the temperature in twenty-second intervals in five rooms and sent it to the central unit, which recorded the received temperatures in the database.Such a frequent reading had been set only for research purpose.During normal use, sensors read temperature every five minutes to reduce energy consumption and not to take up communication channels unnecessarily.After doing the measurements with the temperature sensor, it was disconnected and the motion sensor controller was switched on in its place.During an hour measurement, all motion sensors were activated ten times.The received data allowed for calculating the arithmetic mean and the results were was put in the chart below.Then, the driver was disconnected and the flood sensors were switched on.Electricity consumption was again measured for one hour.During the measurement, the sensors were activated six times.The last step of the first stage of measurements was to measure the consumption of electricity during the operation of the entire system with all devices connected to the central unit.All the device drivers were powered only from the central system unit.The measurements were carried out again for one hour, during which time the installation performed identical operations as in the previous steps.

Fig. 4. Electricity consumption of the examined central units [W]
The second stage involved measuring the same parameters with a different central unit.Now the, updated version of Raspberry Pi 3 model B + was used.The Domoticz software was reinstalled and the unit was configured as the central control panel of the intelligent building automation system.All measurements were done in the same way as in the previous stage.The operations performed by the devices also remained unchanged.All the obtained values were put in the chart presented above.
The graph above shows that the energy consumption of successive controllers and devices was very similar in both cases.However, the difference in electricity consumption is clearly noticeable.After a closer analysis, it can be said that this difference does not depend on the connected devices but on the central unit of the system itself.Despite considerable differences in the hardware configuration of both control panels and different methods and communication speeds, controllers in particular devices did not affect power consumption.What was clear, therefore, was that the type of chosen central unit did not cause any changes in the consumption of electricity.The tests did not show any differences in the reaction time of the devices or in the operation of the system.Accordingly, it may be said that an appropriate selection of the central unit can, therefore, help reduce the consumption of electricity in the intelligent building automation management system.

Conclusions
The research was aimed at showing a possibility of saving electricity in smart building installations with the use of the new version of Raspberry Pi 3 model B + as a central unit in intelligent building automation systems.Multi-stage tests showed differences in electricity consumption between the tested units, with the use of the Raspberry Pi microcomputer saving as much as 28 KWh per year.However, the use of a particular unit does not affect the speed of devices operation in any way or the comfort of using the system.As it can be noticed, using an appropriate unit as the system's central unit, allows for reducing electricity bills.Choosing the right solution depends primarily on the power consumption of the central unit itself.Using the new version of Raspberry Pi 3 model B + in this function is much more profitable and allows one to lower electricity bills.Additionally, what makes the Raspberry Pi model effective as the system's central unit are its small dimensions and trouble-free operation for a long time with no need for user intervention.