[PythonCE] Remote Interactive Python shell

Johnny deBris johnny at debris.demon.nl
Mon May 1 08:36:41 CEST 2006


Hello!

After a couple of years of catching dust, I started playing with my IPaq
a bit over the weekend. Installed the latest PythonCE (great work btw,
works like a charm), opened it, typed two lines of Python code... and
found again that the little keyboard thingie is not the most ideal for
input.

To overcome this, I wrote a little script, that allows executing Python
code remotely. There's a little server that can be started on the IPaq,
after that the client can be used to either present a Python prompt from
the server, or send complete files to it to be executed.

Type 'python ripshell.py' to start the server, 'python ripshell.py -' to
start the client and have the server present a prompt, or 'python
ripshell.py <filename>' to execute a Python script. Stdin, stdout and
stderr are redirected from the server to the client.

I was quite delighted, no more pressing little fake keys with the stylo
to test Python code on my IPaq, so I figured perhaps you guys might be
interested in it too. Added a BSD-style license, so you can kdo with it
whatever you wish basically...

Note that you will need to have a pocket pc with an IP address, I think
normally when connected via IR or USB and ActiveSync that's not the case
(I tested with USB and Linux/SynCE myself).

If you have questions or remarks, mail me!

Cheers,

Guido

P.S. To cleanly shut down the server, send it "raise SystemExit('quit')".
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ripshell-0.1.tar.gz
Type: application/x-gzip
Size: 3183 bytes
Desc: not available
Url : http://mail.python.org/pipermail/pythonce/attachments/20060501/495482e6/attachment.bin 


More information about the PythonCE mailing list