mirror of
https://github.com/home-assistant/core.git
synced 2025-07-08 13:57:10 +00:00
Better logging of method used for ADB connection (#24037)
This commit is contained in:
parent
aa5d8e5a81
commit
03253f4598
@ -90,14 +90,15 @@ def setup_platform(hass, config, add_entities, discovery_info=None):
|
|||||||
|
|
||||||
if CONF_ADB_SERVER_IP not in config:
|
if CONF_ADB_SERVER_IP not in config:
|
||||||
# Use "python-adb" (Python ADB implementation)
|
# Use "python-adb" (Python ADB implementation)
|
||||||
|
adb_log = "using Python ADB implementation "
|
||||||
if CONF_ADBKEY in config:
|
if CONF_ADBKEY in config:
|
||||||
aftv = setup(host, config[CONF_ADBKEY],
|
aftv = setup(host, config[CONF_ADBKEY],
|
||||||
device_class=config[CONF_DEVICE_CLASS])
|
device_class=config[CONF_DEVICE_CLASS])
|
||||||
adb_log = " using adbkey='{0}'".format(config[CONF_ADBKEY])
|
adb_log += "with adbkey='{0}'".format(config[CONF_ADBKEY])
|
||||||
|
|
||||||
else:
|
else:
|
||||||
aftv = setup(host, device_class=config[CONF_DEVICE_CLASS])
|
aftv = setup(host, device_class=config[CONF_DEVICE_CLASS])
|
||||||
adb_log = ""
|
adb_log += "without adbkey authentication"
|
||||||
else:
|
else:
|
||||||
# Use "pure-python-adb" (communicate with ADB server)
|
# Use "pure-python-adb" (communicate with ADB server)
|
||||||
aftv = setup(host, adb_server_ip=config[CONF_ADB_SERVER_IP],
|
aftv = setup(host, adb_server_ip=config[CONF_ADB_SERVER_IP],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user