Tried, most of apps work well with am start but there is one which I'm currently working on failed.

The interesting thing is if I clicked that app icon manually to launch it then click BACK key to exit, I then can use am start launch it successfully. That's why I'm searching a way to finish the "preparation" steps.

Now I can do it with a third party component named "AndroidViewClient" in Python by writing:

import re
import time
from com.dtmilano.android.viewclient import ViewClient

device, serialno = ViewClient.connectToDeviceOrExit()
vc = ViewClient(device, serialno)

apps_tab = vc.findViewWithContentDescriptionOrRaise(re.compile('Apps'))
apps_tab.touch()
time.sleep(5)

Problem solved!


On 18 August 2014 10:47, YongQin Liu <yongqin.liu@linaro.org> wrote:



On 18 August 2014 08:24, Botao Sun <botao.sun@linaro.org> wrote:
Hi,

Recently I'm looking at the keycode page provided by Google:


As we know after screen unlocked, there is a white circle with six dots above the HOME key, which can be clicked to enter the APPS tab. However after tried around, I can't find which key is handling it. I tried KEYCODE_BUTTON_MODE, KEYCODE_APP_SWITCH, KEYCODE_MENU, KEYCODE_HOME and some others, none of them works.

Is that icon an actual key? Or it's just a pixel area on the screen?
I think it's only one area used for click.

BTW, if you want to open some application from there,
I think it's better to open the application via am start command.


--
Best Regards,
Yongqin Liu
---------------------------------------------------------------
#mailing list
linaro-android@lists.linaro.org