Add missing unit for signal strength (#40436)
* Added missing unit for signal strength * Added one more unit * Replaced string with variable * Fixed wrong import * Fix import * Replaced string with variable * Fixed wrong import * Apply suggestions from code review * Black * Again a fix :-( * iSort * iSort after merge Co-authored-by: springstan <46536646+springstan@users.noreply.github.com>
This commit is contained in:
parent
480066ba63
commit
7554c8d6c5
15 changed files with 84 additions and 27 deletions
|
@ -4,6 +4,7 @@ import logging
|
|||
from homeassistant.const import (
|
||||
DEVICE_CLASS_SIGNAL_STRENGTH,
|
||||
DEVICE_CLASS_TEMPERATURE,
|
||||
SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
||||
TEMP_FAHRENHEIT,
|
||||
)
|
||||
from homeassistant.helpers.entity import Entity
|
||||
|
@ -14,7 +15,11 @@ _LOGGER = logging.getLogger(__name__)
|
|||
|
||||
SENSORS = {
|
||||
TYPE_TEMPERATURE: ["Temperature", TEMP_FAHRENHEIT, DEVICE_CLASS_TEMPERATURE],
|
||||
TYPE_WIFI_STRENGTH: ["Wifi Signal", "dBm", DEVICE_CLASS_SIGNAL_STRENGTH],
|
||||
TYPE_WIFI_STRENGTH: [
|
||||
"Wifi Signal",
|
||||
SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
|
||||
DEVICE_CLASS_SIGNAL_STRENGTH,
|
||||
],
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue