[pypy-dev] google should build a pypy phone or someone

Dima Tisnek dimaqq at gmail.com
Tue Feb 15 20:09:49 CET 2011


There's always NDK which includes JNI bindings, so you can comile (or
jit-compile) pypy and python code natively and still access android
framework. If it really is a good idea, I cannot tell.

I suppose if you want simple scripting, json-rpc would suit you fine,
if you wanted more scripting, reflection, shared object space and good
integration perhaps dalvik jvm is a way to go, if cpython or pypy
becomes standard in android and apps are witten in python entirely,
jni bindings are probably better, whether static or runtime
reflection. I'm sure there would be a few issues to resolve though,
object lifetime, garbage collection and callbacks for one.

2c from someone who went dumbphone 2 years ago :P

On 15 February 2011 11:40, Dan Stromberg <drsalists at gmail.com> wrote:
> On Tue, Feb 15, 2011 at 6:29 AM,  <pypy at pocketnix.org> wrote:
>> On Tue, Feb 15, 2011 at 03:06:07PM +0100, Carl Friedrich Bolz wrote:
>>> On 02/15/2011 12:51 PM, Laura Creighton wrote:
>>
>
>>> I am sure you know of this then:
>>>
>>> http://code.google.com/p/android-scripting/
>>>
>>> It's an app for Android that lets you script the phone with various
>>> dynamic languages (including Python). Actually I think that PyPy
>>> could/should be made to work with this thing. It would not quite make
>>> PyPy a first class VM on the phone, but would already give you access to
>>> a number of phone-specific features.
>>
>> the Scripting eniroment uses an enviroment varible to indicate a
>> socket to connect to, once connected you make JSON calls over the
>> socket to access the platform API's that are done via a java proxy.
>> porting pypy to run in the enviroment would be as simple as compiling
>> an arm port and importing the (all python) proxy libary
>
> A guy at my local Python User Group uses an Android phone, and has
> explored both Python and Ruby in the Android Scripting Environment.
>
> He tells me that because the Ruby implementation is running on the
> Dalvik virtual machine, that its API access is more complete than that
> of the CPython port.  Presumably you need a wrapper function for
> everything you want to chain into over the socket (in CPython), and
> people create those wrappers mostly on an as-needed basis.
>
> In light of this, it seems it might be better to put a JVM (which is
> almost the same as Dalvik) version of Pypy, or Jython, on Android
> rather than Pypy built for ARM.
> _______________________________________________
> pypy-dev at codespeak.net
> http://codespeak.net/mailman/listinfo/pypy-dev
>



More information about the Pypy-dev mailing list