You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/_components/sensor.miflora.markdown
+35-18Lines changed: 35 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -13,37 +13,54 @@ ha_release: 0.29
13
13
ha_iot_class: "Local Polling"
14
14
---
15
15
16
-
The [Mi Flora plant sensor](https://www.open-homeautomation.com/2016/08/23/reverse-engineering-the-mi-plant-sensor/) is a small Bluetooth Low Energy device that monitors not only the moisture, but also light, temperature and
17
-
conductivity. As only a single BLE device can be polled at the same time, the library implements locking to make sure this is the case.
16
+
The [Mi Flora plant sensor](https://www.open-homeautomation.com/2016/08/23/reverse-engineering-the-mi-plant-sensor/) is a small Bluetooth Low Energy device that monitors not only the moisture, but also light, temperature and conductivity. As only a single BLE device can be polled at the same time, the library implements locking to make sure this is the case.
18
17
19
18
To use your Mi Flora plant sensor in your installation, add the following to your `configuration.yaml` file:
20
19
21
20
```yaml
22
21
# Example configuration.yaml entry
23
22
sensor
24
-
platform: miflora
25
-
mac: xx:xx:xx:xx:xx:xx
26
-
name: Flower 1
27
-
force_update: false
28
-
median: 3
29
-
monitored_conditions:
30
-
- moisture
31
-
- light
32
-
- temperature
33
-
- conductivity
34
-
- battery
23
+
- platform: miflora
24
+
mac: xx:xx:xx:xx:xx:xx
25
+
monitored_conditions:
26
+
- temperature
35
27
```
36
28
37
29
- **mac** (*Required*): The MAC address of your sensor. You can find this be running `hcitool lescan` from command line.
30
+
- **monitored_conditions** array (*Required*): The paramaters that should be monitored.
31
+
- **moisture**: Moisture in the soil.
32
+
- **light**: Brightness at the sensor's location.
33
+
- **temperature**: Temperature at the sensor's location.
34
+
- **conductivity**: Conductivity in the soil.
35
+
- **battery**: Battery details.
38
36
- **name** (*Optional*): The name displayed in the frontend.
39
37
- **force_update** (*Optional*): Sends update events even if the value hasn't changed.
40
-
- **median** (*Optional*): Sometimes the sensor measurements show spikes. Using this parameter, the poller will report the median of the last
41
-
3 (you can also use larger values) measurements. This filters out single spikes. Median: 5 will also filter double spikes.
42
-
If you never have problems with spikes, median=1 will work fine.
43
-
- **monitored_conditions** (*Required*): The paramaters that should be monitored.
38
+
- **median** (*Optional*): Sometimes the sensor measurements show spikes. Using this parameter, the poller will report the median of the last 3 (you can also use larger values) measurements. This filters out single spikes. Median: 5 will also filter double spikes. If you never have problems with spikes, `median: 1` will work fine.
44
39
- **timeout** (*Optional*): Define the timeout value in seconds when polling (defaults to 10 if not defined)
45
40
- **retries** (*Optional*): Define the number of retries when polling (defaults to 2 if not defined)
46
41
- **cache** (*Optional*): Define cache expiration value in seconds (defaults to 1200 if not defined)
47
42
48
-
Note that by default the sensor is only polled once every 15 minutes. This means with the median=3 setting, it will take as least 30 minutes before the sensor will report a value after a Home Assistant restart. As the values usually change very slowly, this isn't a big problem.
43
+
Note that by default the sensor is only polled once every 15 minutes. This means with the `median: 3` setting will take as least 30 minutes before the sensor will report a value after a Home Assistant restart. As the values usually change very slowly, this isn't a big problem.
49
44
Reducing polling intervals will have a negative effect on the battery life.
45
+
46
+
A full configuration example could looks the one below:
0 commit comments