mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-15 21:36:52 +00:00
Move content to intro
This commit is contained in:
parent
1d1ce980f9
commit
ac711db026
@ -20,9 +20,13 @@ redirect_from:
|
||||
- /components/binary_sensor.random/
|
||||
---
|
||||
|
||||
The `random` integration simply creates random values or state. This can be useful if you want to test automation rules or run an interactive demo. It generates a new state every time it is polled.
|
||||
|
||||
## {% linkable_title Binary Sensor %}
|
||||
|
||||
The `random` binary sensor platform is creating random states (`true`, 1, `on` or `false`, 0, `off`). This can be useful if you want to test automation rules. It generates a new state every time it is polled.
|
||||
The `random` binary sensor platform is creating random states (`true`, 1, `on` or `false`, 0, `off`).
|
||||
|
||||
### {% linkable_title Configuration %}
|
||||
|
||||
To enable the random binary sensor, add the following lines to your `configuration.yaml` file:
|
||||
|
||||
@ -42,7 +46,9 @@ name:
|
||||
|
||||
## {% linkable_title Sensor %}
|
||||
|
||||
The `random` sensor platform is creating random sensor values (integers) out of a given range. Returned values form a [discrete uniform distribution](https://en.wikipedia.org/wiki/Discrete_uniform_distribution), meaning that each integer value in the range configured is equally likely to be drawn. This can be useful if you want to test automation rules. It generates a new value every time it is polled.
|
||||
The `random` sensor platform is creating random sensor values (integers) out of a given range. Returned values form a [discrete uniform distribution](https://en.wikipedia.org/wiki/Discrete_uniform_distribution), meaning that each integer value in the range configured is equally likely to be drawn.
|
||||
|
||||
### {% linkable_title Configuration %}
|
||||
|
||||
To enable the random sensor, add the following lines to your `configuration.yaml` file:
|
||||
|
||||
@ -72,4 +78,4 @@ unit_of_measurement:
|
||||
description: Defines the units of measurement of the sensor, if any.
|
||||
required: false
|
||||
type: string
|
||||
{% endconfiguration %}
|
||||
{% endconfiguration %}
|
||||
|
Loading…
x
Reference in New Issue
Block a user