mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-23 09:17:06 +00:00
Asuswrt config entries (#16012)
This commit is contained in:
parent
477bcb3682
commit
39266893d1
@ -6,6 +6,7 @@ ha_category:
|
|||||||
- Presence Detection
|
- Presence Detection
|
||||||
- Sensor
|
- Sensor
|
||||||
ha_release: 0.83
|
ha_release: 0.83
|
||||||
|
ha_config_flow: true
|
||||||
ha_iot_class: Local Polling
|
ha_iot_class: Local Polling
|
||||||
ha_codeowners:
|
ha_codeowners:
|
||||||
- '@kennedyshead'
|
- '@kennedyshead'
|
||||||
@ -21,78 +22,9 @@ There is currently support for the following device types within Home Assistant:
|
|||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|
||||||
To use an ASUSWRT router in your installation, add the following to your `configuration.yaml` file:
|
To add your ASUSWRT devices into your Home Assistant installation, go to:
|
||||||
|
|
||||||
```yaml
|
**Configuration** -> **Integrations** in the UI, click the button with `+` sign and from the list of integrations select **ASUSWRT**.
|
||||||
# Example configuration.yaml entry
|
|
||||||
asuswrt:
|
|
||||||
host: YOUR_ROUTER_IP
|
|
||||||
username: YOUR_ADMIN_USERNAME
|
|
||||||
```
|
|
||||||
|
|
||||||
{% configuration %}
|
|
||||||
host:
|
|
||||||
description: "The IP address of your router, e.g., `192.168.1.1`."
|
|
||||||
required: true
|
|
||||||
type: string
|
|
||||||
username:
|
|
||||||
description: "The username of a user with administrative privileges, usually `admin`."
|
|
||||||
required: true
|
|
||||||
type: string
|
|
||||||
password:
|
|
||||||
description: "The password for your given admin account (use this if no SSH key is given)."
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
protocol:
|
|
||||||
description: "The protocol (`ssh` or `telnet`) to use."
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
default: ssh
|
|
||||||
port:
|
|
||||||
description: SSH port to use.
|
|
||||||
required: false
|
|
||||||
type: integer
|
|
||||||
default: 22
|
|
||||||
mode:
|
|
||||||
description: "The operating mode of the router (`router` or `ap`)."
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
default: router
|
|
||||||
ssh_key:
|
|
||||||
description: The path to your SSH private key file associated with your given admin account (instead of password).
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
require_ip:
|
|
||||||
description: If the router is in access point mode.
|
|
||||||
required: false
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
interface:
|
|
||||||
description: "The interface of the router that you want statistics from (e.g. eth0,eth1 etc)"
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
default: eth0
|
|
||||||
dnsmasq:
|
|
||||||
description: "The location of the dnsmasq.leases files"
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
default: /var/lib/misc
|
|
||||||
sensors:
|
|
||||||
description: List of enabled sensors
|
|
||||||
required: false
|
|
||||||
type: list
|
|
||||||
keys:
|
|
||||||
"devices":
|
|
||||||
description: Connected devices sensor
|
|
||||||
"upload":
|
|
||||||
description: TX upload sensor
|
|
||||||
"download":
|
|
||||||
description: RX download sensor
|
|
||||||
"download_speed":
|
|
||||||
description: download mbit/s sensor
|
|
||||||
"upload_speed":
|
|
||||||
description: upload mbit/s sensor
|
|
||||||
{% endconfiguration %}
|
|
||||||
|
|
||||||
<div class='note warning'>
|
<div class='note warning'>
|
||||||
|
|
||||||
@ -100,32 +32,29 @@ You need to enable telnet on your router if you choose to use `protocol: telnet`
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
### Example Sensor Configuration
|
### Sensor Configuration
|
||||||
|
|
||||||
To enable ASUSWRT sensors as part of your installation, reference the following example configuration:
|
These sensors are automatically created in status **disabled** and associated to the router device:
|
||||||
|
|
||||||
```yaml
|
- Connected devices sensor
|
||||||
# Example configuration.yaml entry
|
- Download sensor (unit_of_measurement: Gigabyte - *Daily accumulation*)
|
||||||
asuswrt:
|
- Download Speed sensor (unit_of_measurement: Mbit/s)
|
||||||
host: YOUR_ROUTER_IP
|
- Upload sensor (unit_of_measurement: Gigabyte - *Daily accumulation*)
|
||||||
username: YOUR_ADMIN_USERNAME
|
- Upload Speed sensor (unit_of_measurement: Mbit/s)
|
||||||
ssh_key: /config/id_rsa
|
|
||||||
sensors:
|
|
||||||
- devices
|
|
||||||
- upload
|
|
||||||
- download
|
|
||||||
- upload_speed
|
|
||||||
- download_speed
|
|
||||||
```
|
|
||||||
|
|
||||||
The example above, creates the following sensors:
|
To use ASUSWRT sensors, simply **enable** them in the devices page.
|
||||||
|
|
||||||
- sensor.asuswrt_devices_connected
|
## Integration Options
|
||||||
- sensor.asuswrt_download (unit_of_measurement: Gigabyte - *Daily accumulation*)
|
|
||||||
- sensor.asuswrt_download_speed (unit_of_measurement: Mbit/s)
|
|
||||||
- sensor.asuswrt_upload (unit_of_measurement: Gigabyte - *Daily accumulation*)
|
|
||||||
- sensor.asuswrt_upload_speed (unit_of_measurement: Mbit/s)
|
|
||||||
|
|
||||||
|
It is possible to change some behaviors through the integration options. These can be changed at **ASUSWRT** -> **Options** on the Integrations page.
|
||||||
|
|
||||||
|
- **Consider home**: Number of seconds that must elapse before considering a disconnected device "not at home"
|
||||||
|
- **Track unknown**: Enable this option to track also devices that do not have a name. Name will be replaced by mac address.
|
||||||
|
- **Interface**: The interface that you want statistics from (e.g. eth0,eth1 etc)
|
||||||
|
- **Dnsmasq**: The location in the router of the dnsmasq.leases files
|
||||||
|
- **Require IP**: If devices must have IP (this option is available only for access point mode)
|
||||||
|
|
||||||
|
**Note**: if you don't want to automatically track new detected device, disable the integration system option `Enable new added entities`
|
||||||
|
|
||||||
## Padavan custom firmware (The rt-n56u project)
|
## Padavan custom firmware (The rt-n56u project)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user