rfkill bluetooth has no output so not gonna print it
This commit is contained in:
1 parent
8f8ed4bda7
commit
5c06fb36a5
1 file changed
+2
-2
+2
-2
@@ -224,9 +224,9 @@ def read_data_sync(mac: str) -> Optional[SensorReading]:
|
|||||||
# --------------------------------------------------------------------------- #
|
# --------------------------------------------------------------------------- #
|
||||||
def reset_adapter():
|
def reset_adapter():
|
||||||
log.info("Restting BT Adapter...")
|
log.info("Restting BT Adapter...")
|
||||||
log.info(subprocess.run(["sudo", "rfkill", "block", "bluetooth"], capture_output=True, text=True, check=True).stdout)
|
subprocess.run(["sudo", "rfkill", "block", "bluetooth"], capture_output=True, text=True, check=True)
|
||||||
time.sleep(2)
|
time.sleep(2)
|
||||||
log.info(subprocess.run(["sudo", "rfkill", "unblock", "bluetooth"], capture_output=True, text=True, check=True).stdout)
|
subprocess.run(["sudo", "rfkill", "unblock", "bluetooth"], capture_output=True, text=True, check=True)
|
||||||
time.sleep(5)
|
time.sleep(5)
|
||||||
log.info("Reset complete. ")
|
log.info("Reset complete. ")
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user