Do-it-yourself smart home based on Raspberry Pi 3, step by step instructions

A smart home built on the basis of Raspberry Pi 3 is a multifunctional complex that allows you to control and manage all the elements of your pestle of residence, whether it is an apartment, a summer house or a private house. Under his “management” many elements work, ranging from light bulbs in rooms, ending with a heating system and launching systems that recognize the presence of a person.

The peculiarity of the system lies in the coordinated work of all components, reliability and comparative ease of setup.

Principle of operation

The Raspberry Pi 3-based smart home is popular due to its ease of assembly, including for people with no special experience. The basis of the whole system is a small motherboard, in which the manufacturer has laid a huge potential.

Initially, the company sold two complete sets of the device – models A and B. The first differed in the amount of memory in the size of 256 MB, and the second in twice its size.

Model A was on sale for some time, thanks to the availability of access to the global network, but after upgrading to version “B”, the first version was no longer needed. The new version was compact and featured four USB ports.

Building a smart home based on Raspberry Pi 3 depends on the preferences of the owner. Regardless of this, the principle of operation remains unchanged:

  1. The main function is performed by the server. This is a central device that collects information and performs the necessary calculations. The role of the main server is played by the Raspberry Pi motherboard, on which the WEB interface is installed. Its feature is the ability to communicate with a tablet, laptop or phone.
  2. The server is in relationship with the modules surrounding it. Contact is made using RS-485. To ensure the smooth functioning of the system, a special controller is installed in each room. Its task is to receive and analyze incoming information, followed by sending commands to executing devices (household appliances).
  3. Communication between the Raspberry Pi module and the controllers is provided using the UART port. A special conductor is connected to the latter to the RS-485 interface. It is worth considering that the latest models of the device already have such an interface (it is already in the database).
  4. The operating system is Raspberry. In combination with it, one of the available extensions, for example, Pimatic, works.

If desired, the smart home system can be assembled on an “open” type platform, for example, Fhem, openHAB, SHC. An equally popular option is to use the wiBulter platform.

Where is the Raspberry Pi 3 Model B used?

The scope of a smart home based on Raspberry Pi is limited only by the knowledge of the installer and the wishes of the owner of the house. The following options are available here:

  1. Application as a complete computer. If desired, you can connect a display and keyboard to the system, connect a mouse, and then use the received Windows PC. The latter is only possible for Raspberry Pi B, as well as models 2B or 3B.
  2. Gathering many small Raspberry Pi computers to get a PC with a large number of cores and high performance. To do this, you need to connect the required number of products into one server and find a convenient place to place it. You will also have to solve the issue of cooling the structure. The finished computer will not yield to even the most powerful CPU, purchased for a few hundred dollars, in terms of performance.
  3. Installing a console emulator on Raspberry, downloading game images, connecting a monitor and joystick. This is enough to turn the system into a gaming platform for entertainment.
  4. Connecting an 8-15 inch touch display, creating a wooden or metal case and installing Android OS. The result is a multifunctional tablet made on its own.
  5. Create your own lighting system for the street or home by setting up a Raspberry Pi smart home. If desired, only certain bulbs will light up, which allows you to surprise loved ones and loved ones.
  6. Arrangement of a wall organizer. All that is required is to connect a smaller version of the PC to the display, configure the OS and fix the structure to the wall.

The capabilities of a smart home on the Raspberry Pi allow you to use the design as a set-top box, home weather station, security system or tablet. The possibilities of application are almost unlimited.

See also:

Raspberry Pi 3 Model B Features and Specifications

The device is a compact computer that has the dimensions of a plastic bank card. The necessary equipment for operation is installed on the chip – CPU, RAM, HDMI connector, USB and composite output. There is also an Ethernet-connector, wireless communication and bluetooth.

The Raspberry Pi 3 Model B has four dozen basic input and output contacts. They are designed to connect peripheral devices that need to interact with the rest of the elements of the outside world. We are talking about switching with sensors and actuators operating from the network.

The base OS for a smart home on the Raspberry Pi 3 is Linux. The operating system is installed on a microSD memory card, which is installed in a special slot on the board.

Many previously worked only with Windows and are afraid of Linux. There is nothing unusual about this OS. It is easy to use and has a high level of security. If setup errors are made during installation, they can be easily corrected by restoring the image.

The Raspberry Pi 3 Model version is a more advanced version of the second model. The new board is fully compatible with the previous version, but features better performance and additional connectivity options:

  1. Wi-Fi 802.11n series and Bluetooth 4.1 have appeared.
  2. A processor with four cores is provided (type – ARM Cortex-A53). The operating frequency is 1,2 gigahertz. It is based on a single-chip chip such as Broadcom BCM

The CPU is based on the ARM v53 architecture. This allows you to use any operating system, such as Ubuntu or Windows 10.

The use of a 4-core chip guarantees an increase in product power by 50-60 percent (compared to the second model) and 1000 percent compared to the first Raspberry Pi.

Thanks to this feature, the mini PC opens up even more possibilities for creating complex smart home projects, which, against the backdrop of access to the Web, opens up almost limitless possibilities.

The new model Raspberry Pi 3 is endowed with 1 GB of RAM. Part of this memory is used by the graphics subsystem. As for the graphic part, a 2-core VideoCore IV CPU is installed here.

The system supports various standards such as OpenGL ES 2.0, VC-1, OpenVG, MPEG-2. Additional features – the ability to encode, decode and display full-screen HD video on the screen. Video options – 1080p, 60 FPS, H.264.

Periphery

The constant plus of the system is the ability to connect a TV or display using the HDMI output. The resolution can be changed in the range from 640*350 to 1920*1200. Composite type output has two modes of operation – NTSC and PAL. A 3,5 mm jack is provided for switching speakers and headphones.

Additional advantages of a smart home based on Raspberry Pi 3 are USB ports connected by an internal hub. If necessary, you can connect a mouse and keyboard.

Your device has an option to save CPU resources. For this, the Raspberry Pi 3 model has 15-pin connectors. Among them are CSI-2, used to connect the camera, and DSI for screen switching.

There are a number of low-level interfaces, namely supply pins (3 and 5 Volts, as well as ground), 40 ports for general input and output, selectable SPI, serial UART and I2C/TWI.

To connect to a smart home based on the Raspberry Pi 3 model B, Bluetooth 4.1, Wi-Fi 802.1 n and Ethernet (10/100 Mbps) are provided. In the latter case, the output is equipped on a conventional RJ-45 connector.

Feeding part and dimensions

The product is supplied with a voltage of 5 V, supplied from a special adapter through the power pins or microUSB connector. For reliability, it is better to use a source that has an I of 2 amperes or more. In this case, it becomes possible to connect more powerful products to the USB ports.

There is no hardware switch that provides voltage supply on the board. The mini PC is activated by plugging the cord into a power outlet, and the basic functions of the OS are used to turn it off.

The dimensions of the board are only 8,5 * 5,4 cm. It contains the necessary ports, some of which slightly protrude from the overall dimensions (by several millimeters).

See also:

Software

In a smart home based on the Raspberry Pi 3 Model B, there is no familiar hard drive, so the “OS” is installed on a portable medium (memory card). It must be prepared and delivered in advance.

If you have multiple memory cards, you can use different images for your smart home system. It is worth considering that a memory card is not included in the package, so you will have to buy it yourself. It is advisable to take a microSD with a capacity of 4 GB or more.

Basic parameters:

  • CPU: 64 bits 4 cores. Type – ARM Cortex-A53. Frequency – 1,2 GHz. Chip single-crystal BCM2837;
  • RAM – one gigabyte LPDDR2 SDRAM;
  • digital HDMI video output;
  • 3,5 mm audio output (4 pin);
  • USB 2.0×4 ports;
  • networking – Wi-Fi11n, 10/100 megabytes RJ45 Ethernet;
  • to connect the display – Display Serial Interface (DSI);
  • блютуз — Bluetooth 4.1, Low Energy;
  • for connecting a video camera – MIPI Camera Serial Interface (CSI-2);
  • slot for MicroUSD;
  • 40 I/O ports;
  • dimensions – 8,6 * 5,6 * 1,7 cm.

Benefits of Raspberry Pi 3 Model B

A smart home based on Raspberry Pi 3 Model B has a number of undeniable advantages:

  1. The presence of a large selection of interfaces that allow you to maximize the capabilities of the system. It has Bluetooth, Wi-Fi, HDMI and USB ports.
  2. Ability to connect a GSM modem to get in touch with an operator providing global network services.
  3. The presence of a powerful processor with four cores at 1,2 GHz, capable of solving serious tasks.
  4. Full compatibility of the new and previous version.
  5. Compactness. The device is small and weighs only 45 grams.
  6. Overclocking availability. If desired, an increase in system performance is available.
  7. Ease of application. Raspberry Pi 3 Model B programming can be done in different languages.

It is also worth highlighting a number of advantages of a smart home built on the basis of Raspberry Pi 3 Model B:

  1. The ability to secure the building by protecting it from floods, installing video surveillance, creating fire and security systems.
  2. Installation of systems that increase comfort. We are talking about electrical appliances, as well as special devices that control curtains.
  3. Possibility of installing a system that provides additional savings. Sensor mixers, motion sensors, as well as sensors that record the movement of a person or animals are used.
  4. Availability of installation of entertainment special systems. For example, you can connect a multi-room or home theater to a smart home on Raspberry Pi 3 Model B.

To complete the picture, it is worth considering a number of disadvantages that are typical for a smart home on the Raspberry Pi 3 Model B:

  1. The installation of such devices is suitable for large mansions located outside the city limits and having a large area.
  2. To install, you need to know the features and rules for the use of each of the elements. In extreme cases, it is advisable to have a qualified specialist at hand, ready at any time to help in a matter of interest.
  3. Over time, a smart home built on Raspberry Pi 3 Model B will become obsolete. For this reason, it may be difficult to find the necessary components (in the event of a breakdown).

In general, the device has more positive qualities, therefore, it deserves the attention of people who want to equip a comfortable and easy-to-use house.

See also:

Modules that can be used

Additional modules can be used to expand the smart home functionality on the Raspberry Pi 3 Model B. Their use expands the number of available options and allows you to create a unique system that provides maximum convenience:

  1. VIDEO CAMERA. Connecting this module allows you to add a smart home with a video surveillance system. The camera is compatible with the operating system of a small PC Raspberry Pi 3 Model B. After installing the device, you can record video in Full HD resolution and take photos with a resolution of 5 MP.
  2. SMOKE AND WATER DETECTORS. Installing these modules allows you to protect property from fire and leakage, respectively. For owners of large houses, this is a useful option to avoid trouble. In the event of smoke or a flood, the system promptly informs the owner about the presence of problems.
  3. AIR TEMPERATURE AND HUMIDITY METER. Using these modules, you can turn your Raspberry Pi 3 Model B-based smart home into a weather station with detailed information about the situation outside the window and indoors.
  4. MOTION SENSOR. Connecting the device allows you to automatically turn on and off the light in the premises. The motion sensor is useful on the street, in the garage, in the corridor and other non-residential areas.
  5. WIRELESS COMMUNICATION MODULE. To combine external devices and the controller, you can use a receiver and transmitter operating at a frequency of 433 Hz. If you have funds, you can buy a more advanced version of the device – Z-Wave Fibaro Home Center

The use of these sensors expands the capabilities of a smart home and increases the level of its protection.

Also read what remote access surveillance cameras are on the market, the rating of popular models, connection features.

First settings and preparation for work

To get started, you should read the instructions and manufacturer’s recommendations regarding the use of the device. It is worth making sure that the necessary sensors are available and plan their connection. The board is installed in a special box that protects the product from mechanical influences. The device does not play and looks very solid.

After removing the top cover, you can access the board. The only difficulty is connecting the side connector. For convenience, it is recommended to buy a corner loop.

Additionally, two heatsinks are purchased to cool the Ethernet controller and the main chip.

There are other solutions as well.

For the first start, you will need a memory card with an operating system installed on it. The minimum size of the flash drive must be 4 GB or more. The OS image is available online (download link below). You will also need the Win32 Disc Imager program.

After downloading the image to the laptop, you need to unpack it from the archive, and then insert the memory card into the card reader. Next, the already installed Win32 Disc Imager program is launched.

As soon as the work is completed, the image is selected using the program and written to the flash drive.

Next, the memory card with the image is taken out and inserted into the Raspberry Pi 3 Model B device. After that, the keyboard, display and mouse are connected. If desired, you can use a wireless keyboard.

Assembly of the smart home system

In order to avoid problems, we will give detailed instructions for assembling the system and preparing it for work. The algorithm of actions is as follows:

  1. Login to the official website of the Raspberry Pi 3 Model B device and download the required OS version.
  2. Purchasing and formatting a Micro SD memory card. Booting onto her OS image.
  3. Installing the card in the motherboard slot to install the OS.

This completes the setup of the Raspberry Pi 3 Model B.

  1. Installing NodeJS. Passing this stage will be required for the full operation of the NodeMCU ESP-12E.
  2. Installing Homebridge and setting up automatic startup with Root rights (the device should start after turning on the Raspberry Pi 3 Model B).
  3. Connecting external modules according to a special scheme.

After completing the specified work, you need to go to your mobile phone and open the Home application. After that, it’s worth adding the Raspberry Pi platform.

Upon completion of the authorization process, the user can manage various devices in the apartment or house.

The owner controls the lighting, knows the exact information about humidity and temperature, receives information about the presence of a leak or smoke (if such problems occur).

These are just a few of the Raspberry Pi 3 Model B smart home features that the owner gets.

By clicking on the package, you can read the complete instructions for installing the Raspberry Pi 3 Model B.

What can happen, look at the video.

Results

A smart home based on Raspberry Pi 3 Model B is a convenient alternative to existing and more expensive devices. The peculiarity of the platform is its compactness, the possibility of expanding the functionality and low price. You can connect various external modules to it without worrying about compatibility problems.

For successful connection and installation, knowledge of the principles of working with the command line is recommended. To do this, you need to prepare the system for work, find the necessary materials on the Web and configure.

Despite the time investment, the result of labor is a powerful and convenient system that provides full home automation. In the future, you can connect multimedia and other devices to it.

Leave a Reply