from com.android.monkeyrunner import MonkeyRunner, MonkeyDevice
import time
device = MonkeyRunner.waitForConnection()
for i in range(3):
#start to call
device.shell("am start -a android.intent.action.CALL -d tel:10086")
time.sleep(10)
device.touch(271,799,'DOWN_AND_UP')
time.sleep(3)
device.press("KEYCODE_BACK",'DOWN_AND_UP',"")
device.press("KEYCODE_HOME",'DOWN_AND_UP',"")
time.sleep(3)