Let's talk about the selection criteria, manufacturers, prices, a little scolding the Russian market.
We have compiled for ourselves the following list of interesting sensors that are responsible for the indication:
- Leakage
- Smoke
- Penetration (magnetic contact)
- Object movements
- Glass breaking
As well as sensors measuring:
- Temperature
- Gas / water consumption
- Power consumption
- Humidity
Of these, we purchased motion / light, intrusion, leakage and temperature / humidity sensors (based on solutions for a smart home - preventing theft, fire, flooding).
How did we choose a manufacturer?
The simplest criterion for selection is the cost of the sensor and its availability in Russia. The sensor itself is a simple device, different companies give approximately the same quality, so we were guided by the price of the product - the cheaper the better. After all, in the end, the client will pay for everything, and hundreds of sensors can go to a big house. If you pay 1,000 rubles or more for each, it will come out expensive.
Another important criterion is energy consumption (our sensors, for example, operate on battery power). Some devices are placed in hard-to-reach places, the constant replacement of batteries can be an unpleasant problem. We watched sensors supporting ZigBee technology, which is the most energy-efficient communication standard. So, our sensors can be in sleep mode, consuming a minimum amount of energy, and switch to receive-transmit mode only when necessary.
And ZigBee, although it has a low transfer rate, is considered to be a completely reliable, self-healing network that is easy to deploy and operate.
Who makes these sensors?
There are many companies, we just looked at the list. Xiaomi is the leader - they have a cheap product, a large selection, you can even order on Aliexpress. Still, sensors should be easily accessible and popular.
The sensors themselves are useless; they must be connected to the network. Therefore, we need to decide what element base and zigbee SoC to choose in order to test this communication standard.
We chose between Texas Instruments and Silicon Labs crystals. Then they began to look at how things are going with the support of these microprocessors in Russia. When you begin to understand their work, technical questions may arise: the detailed documentation of the manufacturer will help here.
There are also some components that are hard to buy in Russia - there are no direct distributors. And this is important: you must be able to conclude a partnership agreement: you have chosen a crystal and agreed that you will buy a batch on a monthly basis. Accordingly, they will make a special offer for you at prices, etc. By the way, some manufacturers can "give" test samples when registering a project.
As a result, we turned to Silicon Labs distributors, we can conclude a contract with them, the prices are adequate, there is support not only hardware but also software (all kinds of specialized libraries, DLLs - all this makes life easier for developers).
Next, we need an electronic board to work with the chip. This is a long process. And so that programmers can immediately get to work, Silicon Labs provides, in particular, debug boards (a complete package for developers), drivers.
About the controller
The controller collects data on the operation of the sensors and sends it to the server for further processing. We made our own modular Kauri controller so that it can work with as many modern communication standards as possible for different industries. From logistics, where LoRa is primarily used, to retail, where RFID technology is needed.
It is also important for us that the controller works autonomously. And, even if there are problems with the network, the house should remain βsmartβ and safe. Xiaomi controllers, for example, do not provide such a solution. They transmit all the information to the servers in China (by the way, information about the location of housing can also fly there).
The Kauri controller manages all devices on the ZigBee LAN using Python scripts. Therefore, in case of problems with the Internet, the system will continue to properly perform its tasks.
The βbox" for the controller itself - the case - is made by many companies. When choosing it, it is better to start from the sphere of exploitation - a street, a house. If the controller will be on the street, select IP at least 65 (to withstand rains). The controller for the premises (home, factory, warehouse) is selected with IP40. If we need a sealed device (to work under water) - select IP66.
When choosing a housing for the room, you should pay attention to its appearance, it should look aesthetically pleasing in the house. For the controller we use the processor of the iMX 8M family, Cortex A53.
About security
We took the debug board, the sensor, and the programmer rebuilt the Zigbee network. Then we checked whether the sensors appeared on the network and whether they reacted normally. And here we thought about security. The ZigBee network itself provides cryptographic data protection.
The debug board is the coordinator of the Zigbee network. The network can be relatively open (security keys are exchanged when a new sensor is connected) and closed (no keys are exchanged, that is, the desired security key is sewn into the sensor itself).
The disadvantage of an open network is that if someone at the time of connection can intercept the key, then decrypting all the transmitted information is not difficult. And this is especially dangerous when it comes to the work of the plant, for example.
In our case, the settings will be set at the network configuration level, which means that the client will choose the method of connecting sensors and the type of security.
About Russian and foreign industry
We used the element base of foreign production. In Russia, unfortunately, they do not make suitable components. All ZigBee technology, microprocessors, matrices - all this belongs to the Americans.
In Russia, microelectronics is practically not developed, even resistors do not. Mostly domestic components are produced for the space industry, and all this costs crazy money. And in any case, this is not suitable for our decisions.
Where did you order and how much did it cost?
It was a regular purchase for an individual (without contracts) at retail in a regular online store. In terms of cost, it turned out like this:
- One motion sensor cost 989 rubles
- Window and window opening sensor - 989 rubles
- Water leaks - 929 rubles
- Temperature humidity - 700 rubles
But we bought it for ourselves in the office to test. On the same Aliexpress, these sensors can be bought at half the price.