Start and end sl4a service from terminal

87 views
Skip to first unread message

Rogier G. Kauw-A-Tjoe

unread,
May 23, 2017, 3:08:54 AM5/23/17
to QPython


Hi all,

Is it possible to start and end the sl4a service from the terminal? I'm running a script from an android terminal: in my application I do not want to start the QPython app so using the terminal to start the service would be great. 

Also I found that the AP_PORT and AP_HANDSHAKE are only set correctly with scripts running from the QPython app. The port I can find via netstat, but is it also possible to find the handshake without the app? (I'm guessing this is not possible, because that's the whole idea of the handshake, but still ... :) )

Thank you!

River Yan

unread,
May 24, 2017, 11:33:59 AM5/24/17
to QPython
I think you could not start or end sl4a service from terminal, it's implemented with java and was started with the android's startService API.

If your mobile is rooted, you could call qpython's python Interpreter without start the qpython app, if your mobile is not rooted, you could not call do that for android's app security policy.

The handshake was generated by some  random UUID function, so I think it's possible to get it by some special method.

: )

Rogier G. Kauw-A-Tjoe

unread,
May 24, 2017, 3:30:22 PM5/24/17
to QPython
Thank you for the reply! I'm afraid I'll need to try a different way..

Thanks again!
Reply all
Reply to author
Forward
0 new messages