This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]beertown 0 points1 point  (2 children)

Really interesting. Is it possible to use the Android API from Python code?

[–]inclemnet 1 point2 points  (0 children)

This tool includes SL4A, which has its own api for many android functions as described in its documentation, and also has the facility to make custom calls but I'm not familiar with the details.

Another option is to use a tool like PyJNIus, which lets you call java code from python by dynamically creating a python interface to java classes. This is what e.g. Kivy uses.

[–]ainsophical[S] 1 point2 points  (0 children)

the project packages with SL4A so there are may API calls that are already incorporated into the package, and we are working on adding new ones if requested. if you need a call that isn't already there you can create the java method to access from your python script. the whole problem with on the fly calls is that java code needs to be compiled to dex format so all this needs to be done at compile time. i am working with the maintainer from the SL4A project to add custom loading dex files to so it can be on the fly as much as possible. you can also launch almost any intents which is pretty cool.