小米智能门锁+智能网关_以小米为例的带小米的智能住宅
小米智能门锁+智能网关
背景或为什么所有这些都是必要的 (Background or why all of this is necessary)
For starters, a little background so that the context can be understood. In the early autumn of 2018, the sauna was finished and put into operation. The sauna is an autonomous capital structure with year-round heating and water supply.
对于初学者来说,需要一些背景知识,以便可以理解上下文。 2018年初秋,桑拿浴室完工并投入使用。 桑拿浴室是一个自治的资本结构,全年供暖和供水。
For understandable reasons, no one permanently lives in the bathhouse and does not control the condition of the premises. As much as I would like, visiting the bathhouse is also not a very frequent occurrence. Accordingly, thoughts about creating a «smart» bath were present from the very beginning of the project. First of all, for safety reasons (fire, flooding, access control). For example, switching off the heating at -35 degrees outside (I live in Novosibirsk) is a very dangerous situation. However, unlike the main house, I did not think over the project of bath automation from the beginning and did not make additional wiring to the right places. On the other hand, the bath was carried out by the Internet, and the appearance of the other two buildings is video surveillance (you can assess what is happening visually).
出于可以理解的原因,没有人永久住在浴室,也无法控制住所的状况。 据我所愿,去澡堂也不是很频繁。 因此,从项目一开始就提出了创建“智能”浴缸的想法。 首先,出于安全原因(火灾,洪水,访问控制)。 例如,关闭室外-35度的暖气(我住在新西伯利亚)是非常危险的情况。 但是,与主屋不同,我从一开始就没有考虑过浴缸自动化项目,也没有在正确的地方进行额外的布线。 另一方面,洗澡是通过互联网进行的,另外两座建筑物的外观是视频监视(您可以从视觉上评估发生的事情)。
Back from a business trip in November 2019, in the evening I went to the bathhouse, opened the front door and was shocked by what I saw. The WiFi-point LEDs were blinking from the darkness and a stream of water was pouring down my feet. So there was flooding, and the power wasn't cut off. The water in the bathhouse is organized with the help of its own well, a submersible pump and an automation system controlling the process. As it turned out later, one of the fittings in the toilet junction was torn down and all the rooms were flooded. I never found out why the automation was compassionate and still shut down, but it managed to pump 15 cm of water per square 30. It was -14 degrees outside that day. The warm floor managed to keep the room temperature at the right level, but there was 100% humidity. You couldn't sneak in on the organization of a smart house — you have to start doing it.
从2019年11月的一次商务旅行回来,晚上我去了澡堂,打开前门,对我所看到的东西感到震惊。 WiFi点LED从黑暗中闪烁,一股水从我的脚下倾泻而下。 因此,洪水泛滥,电源没有切断。 浴室中的水借助自己的水井,潜水泵和控制过程的自动化系统来组织。 事后证明,厕所交界处的配件之一被拆毁,所有房间都被水淹没了。 我从来没有发现为什么自动化系统具有同情心并仍然关闭,但它设法每平方30英寸抽15厘米水。那天外面是-14度。 温暖的地板设法将室温保持在适当的水平,但湿度为100%。 您无法潜入智能房屋的组织中-您必须开始这样做。
设备选择 (Choice of devices)
During the construction of the main house I gained experience working with Eldes devices (the appropriate wiring was created). Part of the automation is done on
在建造主房屋的过程中,我获得了使用Eldes设备的经验(已创建适当的接线)。 自动化的一部分是在Raspberry PI. Another part is made on Raspberry PI上完成的。 另一部分是在Xiaomi Aqara devices. The variant with Raspberry PI was the one I liked the most and I initially considered it for the bath. But, unfortunately, it requires much more effort to organize. It's not a plug-and-play device after all — from exercises with iron to writing software for your own needs. For certain reasons, MajorDoMo wasn't happy with it. Crossing Raspberry PI, ZigBee Adapter (to use Xiaomi wireless sensors) and Apple HomeKit required learning (and Apple HomeKit interface is not very happy at the moment). There wasn't much time (I didn't want the situation to be repeated) and there was no wiring for each necessary point, so I decided to do everything on Xiaomi devices.小米Aqara设备上制作的 。 Raspberry PI的变体是我最喜欢的变体,我最初考虑将其用于沐浴。 但是,不幸的是,这需要更多的精力来组织。 毕竟,它不是即插即用的设备,从铁的练习到满足您自己需求的编写软件。 由于某些原因,MajorDoMo不满意。 跨越Raspberry PI,ZigBee适配器(以使用小米无线传感器)和Apple HomeKit需要学习(而Apple HomeKit界面目前并不十分令人满意)。 没有太多时间(我不想重复这种情况),每个必要的点都没有接线,所以我决定在小米设备上进行所有操作。
The main device in this situation is the hub. In the case of Xiaomi, there are two versions of the hub: Xiaomi Mi Smart Home Gateway 2 and Xiaomi Aqara Gateway. The latter is about twice as expensive, more suitable for the local market and able to integrate devices into Apple HomeKit. However, if you install the Aqara Home application and select the region «Russia», at the time of writing these lines, only 13 different devices (switches, sockets, sensors) will be available. If you install the application Xiaomi Home, select the region «China Mainland», then there will be hundreds of devices available for connection. However, if you select the «China Mainland» region, you will not be able to connect the European socket and vice versa. Selecting «China Mainland» region within the Aqara Home application does not give the completeness of devices that are present within Xiaomi Home with the same region. Fearing incompatibilities, I decided to stop at the Xiaomi Mi Smart Home Gateway 2 hub. By the way, the hub itself is a lamp — this can be taken into account during installation.
在这种情况下,主要设备是集线器。 对于小米,该集线器有两个版本:小米智能家居网关2和小米Aqara网关。 后者的价格大约是后者的两倍,更适合本地市场,并且能够将设备集成到Apple HomeKit中。 但是,如果您安装Aqara Home应用程序并选择“俄罗斯”区域,则在编写这些行时,将仅提供13种不同的设备(开关,插座,传感器)。 如果您安装了应用程序小米主页,请选择地区“中国大陆”,然后将有数百种设备可供连接。 但是,如果您选择“中国大陆”地区,则将无法连接欧洲插座,反之亦然。 在Aqara Home应用程序中选择“中国大陆”区域并不能使小米Home中具有相同区域的设备完整。 由于担心不兼容,我决定在小米Mi智能家居网关2集线器停下来。 顺便说一下,集线器本身就是一盏灯-在安装过程中可以考虑到这一点。
A separate interesting question is how long this is going to work out. It's not even about sensors and batteries in them, but about synchronization and storage of data in the cloud. At the moment, the account is free. All information is stored on Xiaomi servers. If tomorrow the guys decide that users from Russia should not store data in the region «China Mainland» or Roskomnadzor for some reason will banish their servers, the whole smart house risks to turn into a pumpkin. I decided for myself that in this case the sensors will remain, and the hub will be replaced by Raspberri PI + ZigBee Adapter.
另一个有趣的问题是,要解决多长时间。 它甚至与传感器和电池无关,而与云中数据的同步和存储有关。 目前,该帐户是免费的。 所有信息都存储在小米服务器上。 如果明天人们决定俄罗斯用户不应该将数据存储在“中国大陆”区域或Roskomnadzor出于某种原因而淘汰服务器,那么整个智能住宅就有可能变成南瓜。 我自己决定,在这种情况下,传感器将保留,而集线器将由Raspberri PI + ZigBee适配器代替。
监控和防止泄漏 (Monitoring and preventing leaks)
The first and most important automation scenario was a natural continuation of the problem — when a leak occurs, the water supply, i.e. the pump, must be turned off and a problem alert must be sent to the phone. There were two potentially dangerous leak locations.
第一个也是最重要的自动化方案是问题的自然延续-发生泄漏时,必须关闭供水(即泵),并且必须将问题警报发送到电话。 有两个潜在的危险泄漏位置。
In addition to the hub, this scenario required two leak detectors and a smart wall-mounted socket. Leakage sensors are autonomous, run on batteries. The manufacturer claims that one battery will be enough for 2 years.
除集线器外,此方案还需要两个检漏仪和一个智能壁装插座。 泄漏传感器是自主的,由电池供电。 制造商声称,一块电池可以使用2年。
Installation of a smart socket was a little complicated by the fact that under the Chinese sockets you need square sockets, which are not sold in our regular stores (but you can bring them on order).
智能插座的安装有些复杂,因为在中国式插座下您需要方形插座,而这些插座在我们的常规商店中没有出售(但您可以订购)。
Drilling square holes is still a pleasure. Plus, you need an adapter in a good way, although there is also an outlet for the European plug. The Aqara version for the local market does not currently have a wall-mounted socket, which ties us to the «China Mainland» region. Alternatively, you could install a normal wall socket and plug a smart Xiaomi socket in it, but this would require two additional adapters. Another alternative was a relay. But I stopped at a wall-mounted socket.
仍然可以在方Kong上钻Kong。 另外,尽管也有用于欧洲插头的插座,但您仍需要一个很好的适配器。 目前,针对当地市场的Aqara版本没有壁挂式插座,这使我们与“中国大陆”地区相关联。 或者,您可以安装普通的墙壁插座,然后将智能小米插座插入其中,但这将需要两个额外的适配器。 另一种选择是继电器。 但是我停在壁挂式插座上。
In the Xiaomi Home app, a socket and a sensor were added. Next, a «in case of leakage» scenario is written for two actions: to turn off the socket and send an alert.
在小米家庭应用程序中,添加了一个套接字和一个传感器。 接下来,针对两个动作编写了“万一发生泄漏”的场景:关闭套接字并发送警报。
The first leak sensor was installed next to the pump (and, in fact, next to the hub). For the test, water was poured into a small plate and the sensor was lowered into it. I did all the action directly in the place where the sensor was installed to bring the situation as close to reality as possible. The test was successful: the socket was disconnected, the alarm came on the phone, plus the hub blinked emergency mode.
第一个泄漏传感器安装在泵旁边(实际上,在轮毂旁边)。 为了进行测试,将水倒入一个小板中,并将传感器降低到其中。 我直接在安装传感器的地方进行了所有操作,以使情况尽可能接近实际情况。 测试成功:插座已断开,电话响起了警报,并且集线器闪烁了紧急模式。
The second leak detector was planned to be installed in the toilet near the pipe junction. But with its installation there were nuances — the hub did not see the sensor, although the distance was small. The fault was the configuration of the premises.
计划将第二个检漏仪安装在靠近管道连接处的马桶中。 但是安装时有细微差别-尽管距离很小,但集线器看不到传感器。 故障是房屋的配置。
Between the place of installation of the hub (rest room) and the place of installation of the second sensor of leakage (toilet) there was a steam room. In the best traditions, the steam room was sewn in a circle of foil, creating problems with the signal passing.
在轮毂的安装位置(休息室)和第二个泄漏传感器(厕所)的安装位置之间有一个蒸汽室。 按照最好的传统,蒸汽室被缝成一圈箔纸,在信号传递中产生了问题。
The manufacturer claims that the devices are able to form a mesh network, that is, one device can transmit data to the hub through another device. I have seen information somewhere that only devices that are connected to the network (and not battery-powered) can act as such transmitters on the mesh network. However, it was enough for me to install a temperature sensor in the corner of the washroom so that the signal from the leak sensor would no longer be lost. Maybe this is a coincidence because a street light control relay has been installed below the ceiling in the washing room (maybe it acts as a transmitter in the mesh-network). However, the problem with the loss of signal from the leak detector in the toilet has been solved. In addition, the connection of the instrument to the hub can be checked by pushing the sensor centrally. If all is well, you will hear the information from the hub in pure Chinese (in case of the Aqara hub the communication is in pleasant English).
制造商声称,这些设备能够形成网状网络,即一个设备可以通过另一台设备将数据传输到集线器。 我在某处看到的信息表明,只有连接到网络(而不是电池供电)的设备才能充当网状网络上的此类发送器。 但是,对我来说,在洗手间的角落安装一个温度传感器就足够了,这样泄漏传感器发出的信号就不会丢失了。 也许这是一个巧合,因为路灯控制继电器已安装在洗手间天花板下方(可能充当网状网络中的发送器)。 然而,已经解决了来自马桶中的泄漏检测器的信号丢失的问题。 此外,可通过向中央推动传感器来检查仪器与集线器的连接。 如果一切顺利,您将以纯中文听到来自中心的信息(如果使用Aqara集线器,则以令人愉悦的英语进行交流)。
A check to see if the power has been disconnected and then switched on by means of the machine shows that the smart socket goes off. There is an appropriate setting so that it goes on when the power comes on:
检查机器是否已断开电源然后再接通电源,这表明智能插座已关闭。 有一个适当的设置,以便在打开电源时可以打开:
An additional sign of flooding was an increase in humidity to 100%. Please refer to the next section about controlling this sign.
泛滥的另一个迹象是湿度增加到100%。 请参阅有关控制此标志的下一部分。
烟雾和温度控制 (Smoke and temperature control)
A sauna is a fire hazardous room, so the next scenario was to determine the fire signs. For this scenario, two temperature (and humidity) and smoke detectors were required.
桑拿房是有火危险的房间,因此下一种情况是确定火势。 对于这种情况,需要两个温度(和湿度)和烟雾探测器。
The smoke sensor was mounted on the corridor ceiling in the washroom (actually close to the stove and the exit from the steam room). Further, a device was added to the Xiaomi Home application and a «in case of smoke detection» script was created, followed by a notification to the phone. The test was conducted with a fireplace match. The sensor successfully coped with the test. The hub was freezing the alarm, plus an audible alert was working. The sensor itself was also very nasty and beeped loudly, warning of a problem.
烟雾传感器安装在洗手间的走廊天花板上(实际上靠近火炉和蒸汽室的出口)。 此外,将设备添加到了小米家庭应用程序,并创建了“万一出现烟雾检测”脚本,随后向手机发出了通知。 该测试是在壁炉火柴上进行的。 传感器成功应对了测试。 集线器正在冻结警报,另外还有声音警报正在工作。 传感器本身也很讨厌,会发出很大的哔哔声,警告出现问题。
Another sign of fire is an increase in temperature. Two sensors were installed to monitor the temperature: one in the break room and the other in the wash room. Next, a «in case of temperature above the set point» scenario was set up in the application with a corresponding notification on the phone. At the moment I have set the trigger threshold for the rest room to 30 degrees (in summer it will probably need to be reconfigured).
着火的另一个迹象是温度升高。 安装了两个传感器来监视温度:一个在休息室,另一个在洗手间。 接下来,在应用程序中设置了“温度超过设定点的情况”方案,并在电话上显示了相应的通知。 目前,我已将休息室的触发阈值设置为30度(夏季可能需要重新配置)。
Also, it was configured the scenario «in case of temperature below a preset» with a trigger threshold of 18 degrees and a warning on the phone. If for some reason the heating stops working, I would like to know about it as soon as possible. Similarly, the «in case of humidity rise» scenarios have been created for both sensors with a 70% trigger threshold, a warning on the phone and the shutdown of the water pump.
此外,还配置了“温度低于预设的情况下”的情况,触发阈值为18度,并在电话上发出警告。 如果由于某种原因加热停止工作,我想尽快了解一下。 同样,为两个传感器都创建了“如果湿度升高”的情况,它们的触发阈值为70%,电话上有警告,并且水泵已关闭。
From the nice bonuses on temperature and humidity sensors, historical graphs are available in the application. You can, for example, determine at which moments the bath was used for its intended purpose (temperature peaks in the graph below) or compare whether the current temperature is abnormal.
从温度和湿度传感器的优点中可以得到应用程序中的历史图表。 例如,您可以确定将浴池用于其预定目的的时间(下图中的温度峰值),或者比较当前温度是否异常。
通风控制 (Ventilation control)
The steam room has a forced extractor hood. After completing the procedures, it is desirable to air the room. Ventilation is switched on by means of a key switch, and the ventilation itself takes at least 30 minutes. However, often the sauna ends at the first or second hour of the night. To do everything in advance is not always possible, and to sit at the end of another 30 minutes and wait for the steam room to ventilate — pleasure is below average because you want to sleep already.
蒸汽室配有强制抽油烟机。 完成程序后,最好将房间通风。 通风通过钥匙开关打开,通风本身至少需要30分钟。 但是,桑拿浴室通常在晚上的第一或第二个小时结束。 提前做所有事情并不总是可能的,要再等30分钟再坐一会儿,等待蒸气室通风-愉悦感低于平均水平,因为您已经想睡觉了。
For this scenario we needed a key switch from Xiaomi with zero line and wall mounting. The price of the question is about 1900 p. Switches are available in the version of Aqara for the local market.
对于这种情况,我们需要来自小米的钥匙开关,零线和壁挂式安装。 该问题的价格约为1900便士。 Aqara版本提供适用于本地市场的开关。
In my case, you can not just replace a normal switch with a smart one — a power line is required. Accordingly, it was necessary to pull a zero line to the installation opening for the switch, this was a good opportunity. In the case of a circuit breaker without a zero line, installation would have been easier.
就我而言,您不能仅用智能开关代替普通开关-需要电源线。 因此,有必要将零线拉到交换机的安装开口,这是一个很好的机会。 在没有零线的断路器的情况下,安装会更加容易。
After installation, the smart switch was added to the application as a device and performance tested. The switch settings have a timer and you can set the switch-off time. That is, the switch-off timer is now set for an additional 30 minutes of ventilation before leaving the sauna, and you can go to bed in peace.
安装后,将智能交换机作为设备添加到应用程序中,并对其性能进行了测试。 开关设置有一个计时器,您可以设置关闭时间。 也就是说,现在将关闭计时器设置为在离开桑拿浴室之前要额外通风30分钟,您可以安然入睡。
Another option is possible to automate the process. After bathing procedures are completed, the door to the steam room opens completely in addition to ventilation. This results in an increase in temperature in the washing room, where a temperature sensor is installed. On the basis of this sensor readings, it is possible to create on/off ventilation scenarios. But I haven't run this option around yet. In addition, you could experiment with the sensor for opening the door to the steam room. But I'm afraid it will quickly die or fall off, because the door is made of glass and the steam room can be 120 degrees.
另一个选择是可以使过程自动化。 沐浴程序完成后,除通风之外,蒸汽室的门也完全打开。 这导致安装了温度传感器的清洗室中的温度升高。 基于此传感器读数,可以创建开/关通风方案。 但是我还没有运行这个选项。 另外,您可以尝试使用传感器打开蒸汽室的门。 但是我担心它会很快死掉或脱落,因为门是玻璃制成的,而蒸汽室可能是120度。
路灯控制 (Street light control)
Another task that we wanted to automate was to control street light on the veranda. One of the typical scenarios is to turn on the light on the veranda when you are not far from the building and it is dark outside. The sauna is locked, the street light switch is inside the room. You had to follow the key to open the door and turn on the light. Turning off the lights required a similar procedure. Another scenario that occurred regularly was to turn the lights on or off on the veranda when you were in the main house. I often forgot to turn off the lights on the veranda when I left the sauna and found that I was already in the house: either by looking out the window or by looking at the security cameras. At that moment I was usually reluctant to go anywhere, so the lights kept on all night.
我们要自动化的另一个任务是控制阳台上的路灯。 一种典型的情况是,当您离建筑物不远且外面很暗时,打开阳台上的灯。 桑拿房被锁定,路灯开关在房间内。 您必须按钥匙才能打开门并打开灯。 关闭灯需要类似的步骤。 经常发生的另一种情况是,当您在主屋中时,打开或关闭阳台上的灯。 当我离开桑拿房,发现自己已经在屋子里时,我常常忘记关上阳台的灯:要么看着窗外,要么看着安全摄像机。 那一刻我通常不愿去任何地方,所以灯光一直通宵达旦。
A two-channel relay was purchased to implement this idea. The price of the question is about 2000 p. There are no relays in the version of Aqara for the local market at the moment. But it can be replaced by a key switch (it is clear that installing it in the distributor box is a more troublesome process).
购买了两个通道的继电器来实现此想法。 该问题的价格约为2000便士。 目前,Aqara版本没有针对本地市场的继电器。 但是它可以用钥匙开关代替(很明显,将其安装在分配器盒中比较麻烦)。
Initially, I was supposed to mount the relay behind the key switch, but it was very difficult to reach the power line (the relay again needs power). The ideal place is the junction box where the power line, the line from the circuit breaker and the line from the street lights all converged. It was under a false ceiling, so it had to dismantle some of the car rails. It was desirable to think about this point in advance. However, the installation was successful. The wiring diagram is much more complicated than for sockets and switches (in my case four 3-core wires and 8 terminals on the relay itself). In order not to keep it in my head and not to get anything mixed up, I painted the circuit diagram on paper before mounting it. Next, I did a trial mounting to check everything out:
最初,我应该将继电器安装在钥匙开关的后面,但是很难到达电源线(继电器再次需要电源)。 理想的地方是接线盒,电源线,断路器的线和路灯的线都汇合在一起。 那是在虚假的天花板下,因此必须拆除一些车轨。 最好事先考虑这一点。 但是,安装成功。 接线图比插座和开关要复杂得多(在我的情况下,是继电器本身的四根3芯电线和8个端子)。 为了不让它呆在我的头上并且不让任何东西弄乱,我在安装之前在纸上画了电路图。 接下来,我进行了试装以检查所有内容:
The device was plugged into the application and the testing phase began. The street lights had to be turned on/off with both the previous key switch and the application. There are two street lights, one on the left and one on the right. The relay has two channels, but it made no sense to switch them on separately. On the other hand, you didn't want to turn them on alternately with two clicks in the application either. So the control was done on one channel of the relay. By a strange coincidence, this option didn't work normally — there was a sticking in one or the other position. There was no time for experiments, because the light day was over and we wanted to assemble the car on the ceiling back. So I simply hooked the lanterns parallel to both channels and everything worked as desired. In order to make the physical and software switch work as a gateway switch, the Interlock option was enabled in the relay settings.
该设备已插入应用程序,测试阶段开始。 必须使用先前的按键开关和应用程序打开/关闭路灯。 有两个路灯,一个在左边,另一个在右边。 继电器有两个通道,但是分别打开它们没有意义。 另一方面,您也不想在应用程序中单击两次即可交替打开它们。 因此,控制是在继电器的一个通道上完成的。 碰巧的是,此选项无法正常工作-某个位置或另一个位置出现粘连。 没有时间进行实验了,因为光天化日已经过去,我们想将汽车组装在天花板上。 因此,我只是简单地将灯笼与两个通道平行地钩住,一切都按需工作。 为了使物理和软件交换机可以用作网关交换机,在继电器设置中启用了互锁选项。
It would also be possible to organize switching lights on/off by timer. But this scenario was not interesting yet.
也可以通过计时器来组织开/关的开关灯。 但是这种情况还没有引起人们的兴趣。
房间门禁 (Room access control)
Another curious moment was the control of the opening of the street door. First of all, to determine and notify that someone had forgotten this very door normally slammed or left it open at all.
另一个奇怪的时刻是对街扇门打开的控制。 首先,要确定并通知某人已经忘记了这扇通常被猛撞的门或根本没有打开它。
For this scenario, a window/door open sensor was required. The price of the question is about 1000 p. There are sensors in Aqara version for the local market (they have less rounded edges).
对于这种情况,需要开窗传感器。 该问题的价格约为1000便士。 Aqara版本的传感器适用于本地市场(它们的圆形边缘较少)。
Installation is very simple — sensors are mounted on double-sided tape. Before mounting, it is better to connect the sensor in the application to see at what distance the sensor is triggered. The instructions say up to 20mm clearance, but that's not true to say the least — the sensor and the response magnet have to be mounted almost closely. In the main house, the garage door has a similar sensor. There is a 1 cm wide seal between the guide rail and the door. At this distance, the sensor showed an «open» position and the response magnet had to be increased.
安装非常简单-传感器安装在双面胶带上。 在安装之前,最好在应用程序中连接传感器,以查看传感器触发的距离。 说明中说的是最大20mm的间隙,但这至少可以说是不对的-传感器和响应磁铁必须紧密安装。 在主屋中,车库门具有类似的传感器。 导轨和门之间有1厘米宽的密封圈。 在此距离下,传感器显示“打开”位置,并且必须增加响应磁铁。
Once a new device has been added to the app, you can move on to automation. Configure the scenario «if the door is open for more than 1 minute» with an alarm on the phone. In the English localization you can not see the part of the phrase about 1 minute, but the threshold for triggering is this. In the variant of the Aqara sensor and the Aqara Home application you can configure other triggering intervals. In the Xiaomi Home application, unfortunately, it is not possible to do so yet. But practice has shown that the interval of 1 minute is more than sufficient — there are no false alarms, all the alarms were on the case. You can also look at the logs by sensors. This sensor is not an exception either. You can, for example, from the log to determine when the bath came (first opening the door on a given day) and when it left (last closing the door), thereby estimating the total time spent in the room.
将新设备添加到应用程序后,即可继续进行自动化。 在电话上通过警报配置“如果门开着超过1分钟”场景。 在英语本地化中,大约1分钟内您看不到短语的一部分,但是触发阈值是这个。 在Aqara传感器和Aqara Home应用程序的变体中,您可以配置其他触发间隔。 不幸的是,在小米家庭应用程序中,尚不可能这样做。 但是实践表明,每隔一分钟就足够了-没有虚假警报,所有警报都是针对案件的。 您还可以通过传感器查看日志。 该传感器也不例外。 例如,您可以从日志中确定洗澡的时间(在给定的一天里第一次打开门)和什么时候离开(最后关门),从而估算在房间里花费的总时间。
使用印象 (Impressions of use)
The overall experience of exploitation is purely positive. Of course, there are some minor nuances, but the main goal of automation is achieved. First of all, it is psychological peace of mind, confirmed by test results. Also important and comfort — was received remote control of street lighting, extractor hood, there is an additional night light. Having gone on holiday, it is possible to remember and remotely to switch off water.
剥削的总体经验纯属积极。 当然,有一些细微差别,但是可以实现自动化的主要目标。 首先,测试结果证实了这种心理上的内心平静。 同样重要和舒适-收到了对街道照明,抽油烟机的遥控,还有一个额外的夜灯。 休假后,可以记住并远程关闭水源。
Costs of all the above devices in approximate form (without reference to a particular store) are shown below. When ordering with AliExpress the prices will differ in a smaller direction.
下面以近似形式(不涉及特定商店)显示了上述所有设备的成本。 使用速卖通订购时,价格会在较小的方向上有所不同。
When choosing a set of equipment, you must consider compatibility (for which region the equipment was manufactured and which family it belongs). It will not be possible to create a scenario within the application which, for example, will control a socket for a European region according to a smoke alarm event (for the China Mainland region). If you don't need the exotic smoke sensor type, it's better to look at the Aqara devices for the local market. After all, the relay can be replaced, for example, with a two-key switch. A number of stores selling Xiaomi devices seem to be importing them in gray (these devices are for the Chinese region). But, for example, Svyaznoy, there are devices designed for our market. Besides compatibility of the same sockets, they will also have instructions in English and Russian. Below are photos of two identical sensors, but for different regions:
在选择一组设备时,必须考虑兼容性(设备制造于哪个地区以及它属于哪个系列)。 无法在应用程序内创建方案,例如,该方案将根据烟雾警报事件(针对中国大陆地区)控制欧洲地区的插座。 如果您不需要异国情调的烟雾传感器类型,那么最好看看适合当地市场的Aqara设备。 毕竟,继电器可以用例如两键开关替换。 许多销售小米设备的商店似乎正在以灰色进口它们(这些设备用于中国地区)。 但是,例如Svyaznoy,有些设备是为我们的市场设计的。 除了具有相同插座的兼容性外,它们还将提供英语和俄语说明。 以下是两个相同传感器的照片,但用于不同区域:
The responsiveness of control through an application is not always good. For example, sometimes you may encounter a situation where you get a «request failed» error instead of turning on the light one after another. Experimentally detected treatment — unloading the application from memory and restarting it — solves this problem faster than waiting for a response at the next attempt. There are also sometimes noticeable delays (up to 20-30 seconds) with the update of the status of a particular sensor. At these moments it is better not to press the on/off buttons again, but simply to wait for the status update. When starting the application, in some situations you may see a blank list instead of the device list. There is no need to panic — it usually appears within the next few seconds. Alerts to the phone are not localized and save the correct naming of the events themselves. In addition, the authors of the application periodically use the push-alert channel for advertising (again in Chinese). Of course, I don't like it, but I don't have much choice.
通过应用程序进行控制的响应并不总是很好。 例如,有时您可能会遇到“请求失败”错误,而不是一个接一个地打开灯。 实验检测到的处理(从内存中卸载应用程序并重新启动它)比等待下一次尝试响应更快地解决了此问题。 随着特定传感器状态的更新,有时还会出现明显的延迟(最多20-30秒)。 在这些时候,最好不要再次按开/关按钮,而只是等待状态更新。 启动应用程序时,在某些情况下,您可能会看到一个空白列表,而不是设备列表。 无需惊慌-它通常在接下来的几秒钟内出现。 电话警报未本地化,并保存了事件本身的正确命名。 此外,该应用程序的作者定期使用推送通知渠道进行广告发布(再次使用中文)。 当然,我不喜欢它,但是我没有太多选择。
I hope this article has helped to get a good idea of the capabilities of a number of Xiaomi devices to build a smart home and scenarios for their practical application. If you still have any questions, corrections and additions, I will be glad to discuss them in comments.
我希望本文有助于对许多小米设备构建智能家居的功能及其实际应用场景有一个很好的了解。 如果您还有任何问题,更正和补充,我将很乐意在评论中进行讨论。
小米智能门锁+智能网关