Makes strings compatible for adb shell input text ...
Project description
Makes strings compatible for "adb shell input text ..."
The string escape functions use numba under the hood - that means the first run is very slow (compile time)
pip install adbescapes
from adbescapes import ADBInputEscaped
adb_path = "C:\\Users\\Gamer\\AppData\\Local\\Android\\Sdk\\platform-tools\\adb.exe"
deviceserial = "localhost:5555"
adbk = ADBInputEscaped(adb_path=adb_path, deviceserial=deviceserial)
adbk.connect_to_device()
adbk.activate_debug()
adbk.escape_text_and_send(
"'ąćęłń'\tóśźż\nĄĆĘŁŃÓŚŹŻ\n\"Junto à Estação de \nCarcavelos;\"" "äöüÄÖÜß",
respect_german_letters=False,
exit_keys="ctrl+x",
)
adbk.escape_text_and_send_with_delay(
"""
"Müller\n&Ärger,ändern,\nKüche,Übung, Köchin, Öl\ngroß
""",
delay=(0.01, 0.2),
respect_german_letters=True,
exit_keys="ctrl+x",
)
debug output:
input text \'aceln\'\ \ \ \ oszz
input keyevent 66
input text ACELNOSZZ
input keyevent 66
input text \"Junto\ a\ Estacao\ de\
input keyevent 66
input text Carcavelos\;\"aouAOUb
input keyevent 66
input keyevent 66
sleep 0.072
input text \
sleep 0.103
input text \
sleep 0.109
input text \
sleep 0.066
input text \
sleep 0.159
input text \"
sleep 0.134
input text M
....
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
adbescapes-0.10.tar.gz
(5.1 kB
view details)
Built Distribution
File details
Details for the file adbescapes-0.10.tar.gz
.
File metadata
- Download URL: adbescapes-0.10.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | befbc07e1a5cfa1a3c52fa3ebbbc3caf6a0d25b0f8916dd48b363d0ac0ed554b |
|
MD5 | 9d2053ea7057c8f7410caebec44fe6f6 |
|
BLAKE2b-256 | d7534647919a54e44ef83022393a83a9723a8b42ef1d86cd5d71bdcce915d928 |
File details
Details for the file adbescapes-0.10-py3-none-any.whl
.
File metadata
- Download URL: adbescapes-0.10-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5ff017a9521ae09039d2c3d1579869877ad6e45c6715e8f157ee8d631eb2b676 |
|
MD5 | 75a2a11a18fb38a7fd1bbf6d349bdfdd |
|
BLAKE2b-256 | a84ae13c48887f0c8433a2342bc39b2ec00840b7853e589b96b947ca1086cbff |