This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import appdaemon.plugins.mqtt.mqttapi as mqtt | |
import ctypes | |
import json | |
import functools | |
def dict_inv(old): | |
new = {} | |
for value, key in old.items(): | |
new[key] = value |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Requirements: | |
# pip install adbutils tqdm | |
# Tested on Huawei STF-L09 that randomly reboots when screen is on | |
import os | |
from tqdm import tqdm | |
import adbutils | |
adb = adbutils.AdbClient(host="127.0.0.1", port=5037) | |
adb.wait_for(state="device") | |
device = adb.device_list()[0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import mimetypes | |
import os | |
import random | |
import subprocess | |
import configparser | |
import bs4 | |
import gi | |
import gi.repository.Notify | |
import requests |