使用SL4A发送短信
我想每10秒发送一条文本消息,但我不知道问题出在哪里。抱歉问这个初学者的问题,不过我还是个新手,真的需要一些帮助。以下是我的代码:
import android, time
from time import localtime
droid = android.Android()
now = str(datetime.datetime.now())
while True:
ans = droid.dialogGetInput("Phone Number","","").result
tosend='Wake up!'
droid.smsSend( ans ,tosend )
time.sleep(10)
droid.dialogDismiss()
time.sleep(600)
1 个回答
-1
试试这个:
droid = android.Android()
ans = droid.dialogGetInput("Phone Number","","").result
tosend='Wake up!'
while True:
droid.smsSend(ans,tosend)
time.sleep(10)