I happen to find that for GSM standard phone, call duration would be created into sql database only if the outgoing call is being answered, or after hanging up if it is not being answered.
So i guess this method is meant for CDMA android phone only. cause we could not detect if outgoing call is offhook by the callee via tasker or sl4a.
Java code would be the solution i think, by monitoring the phone state.
In my earlier entry, i have posted an idea about to your android droid vibrate while the callee answers via sqlite3 command.
according to the feedback from a user, reporting a bug, which indicates the run shell action with root most likely would run kinda slow in some low RAM like 512M or 215M smartphone.
i guess the loop interval is also a problem, which make it worse in such a short while.
so i was thinking of finding another workaround.
after done some homework, i have tested working in my android tablet pad. running kinda fast, however, when i moved it to my HTC droid, it failed, error says "sqlite database disk image is malformed".
i got scared ATM, and quickly run some checks on my database file, whereas everything is fine, i opened it via RE and sqlite editor, both are fine. no corruption at all. when i switched back to the python script, it still ran end up with the same error.
well, i am not sure if there is some kind of secure system preventing me from accessing the database.
if you guys are interested, please run some testings for me, will be greatly appreciated.
First move, change the database file permission to be rw-rw-rw, or else, python could fail to access it.
and then you may run this script with tasker outgoing call context.
###### script content ########
import android
droid = android.Android()
import sqlite3
import time
time.sleep(3)
con = sqlite3.connect("/data/data/com.android.providers.contacts/databases/contacts2.db")
con.isolation_level = None
while True:
cur = con.cursor()
cur.execute("SELECT duration FROM calls WHERE type <= 2 ORDER BY date DESC LIMIT 1")
for i in cur:
if i[0] == 1 or i[0] == 2:
break
print i[0]
droid.vibrate(200)
cur.close()
con.close()
Well, MIUI ROM support this feature for a long time.
ReplyDeleteGood job. I'm happy to see how it's realized with SL4A and Python.
Thanks!
Deleteucuz takipçi
ReplyDeleteucuz takipçi
tiktok izlenme satın al
binance güvenilir mi
okex güvenilir mi
paribu güvenilir mi
bitexen güvenilir mi
coinbase güvenilir mi
Baccarat, Cards, and Poker | WURRI | Wolverione
ReplyDeletePlay Baccarat at 인카지노 Wolverione Casino. Get up to £100 worrione in 카지노사이트 free play plus a 100% up to €300 casino bonus. Rating: 4.5 · 11 votes
mmorpg
ReplyDeleteinstagram takipçi satın al
tiktok jeton hilesi
Tiktok jeton hilesi
antalya saç ekimi
referans kimliği nedir
İnstagram takipçi satın al
metin2 pvp serverlar
instagram takipçi satın al
Fon perde modelleri
ReplyDeletesms onay
mobil ödeme bozdurma
nft nasıl alınır
Ankara Evden Eve Nakliyat
trafik sigortası
dedektör
web sitesi kurma
aşk kitapları
Smm Panel
ReplyDeleteSmm Panel
iş ilanları
instagram takipçi satın al
Hırdavat
Beyazesyateknikservisi.com.tr
servis
tiktok jeton hilesi
Good content. You write beautiful things.
ReplyDeletemrbahis
vbet
taksi
sportsbet
sportsbet
hacklink
korsan taksi
mrbahis
vbet
dijital kartvizit
ReplyDeletereferans kimliği nedir
binance referans kodu
referans kimliği nedir
bitcoin nasıl alınır
resimli magnet
BAKOX3
https://saglamproxy.com
ReplyDeletemetin2 proxy
proxy satın al
knight online proxy
mobil proxy satın al
S7DEYL