"""Tasmota constants."""
RSLT_POWER = "POWER"

CONF_DEVICENAME = "dn"
CONF_FRIENDLYNAME = "fn"
CONF_FULLTOPIC = "t_f"
CONF_HOSTNAME = "hn"
CONF_ID = "id"
CONF_LIGHT = "li"
CONF_MODEL = "md"
CONF_OFFLINE = "ofl"
CONF_ONLINE = "onl"
CONF_PREFIX = "t_p"
CONF_QOS = "qos"
CONF_RETAIN = "retain"
CONF_SENSOR = "se"
CONF_STATE = "state"
CONF_RELAY = "rl"
CONF_SW_VERSION = "sw"
CONF_TOPIC = "t"
CONF_VERSION = "ver"

CONF_AVAILABILITY_TOPIC = "availability_topic"
CONF_COMMAND_TOPIC = "command_topic"
CONF_DEVICE_ID = "device_id"
CONF_MANUFACTURER = "manufacturer"
CONF_NAME = "name"
CONF_STATE_POWER = "state_power"
CONF_STATE_POWER_OFF = "state_power_off"
CONF_STATE_POWER_ON = "state_power_on"
CONF_STATE_TOPIC = "state_topic"
CONF_UNIQUE_ID = "unique_id"

PREFIX_CMND = 0
PREFIX_STAT = 1
PREFIX_TELE = 2

STATE_OFF = 0
STATE_ON = 1
STATE_TOGGLE = 2
STATE_HOLD = 3
