HiI mostly diddled with the cam and automated uploading of pictures with simple JSON encoding over WLAN, and as I said, twisted is running with a few patches on the E61i..
Using putools http://people.csail.mit.edu/kapu/symbian/python.html helped a lot.Please find attached a tiny example with a very primitive server and a client counterpart using the standard socket API in python on the E61i. Although the pictures are lousy (the cam looses the white balance when the picture is taken) this code ran for days with no problem. So 'not ready for production' seems to me a bit too harsh as a judgment.
Werner [email protected] wrote:
Date: Thu, 4 Mar 2010 15:57:43 -0600 From: Prince Riley <[email protected]> Subject: [Twisted-Python] Twisted Python on Nokia E71x (Running the phone Python Interpreter) To: [email protected] Message-ID: <[email protected]> Content-Type: text/plain; charset="iso-8859-1" Has anyone experimented with twisted-python on the Nokia E71x or E72 smartphones? Prince RileyHi,I had tried to use Python for S60 (not Twisted, but standard socket module) writing a NNTP client, but I found many problem specially about networking. There is no high-layer abstraction layer for networking, so you have to implement all the logic from low level. I tried to use select (that may be useful for doing asynchronous networking apps), but is not working correctly on s60 phones. There is no porting for Twisted.My experience is that PyS60 is not mature for a production environment. _______________________________________________ Twisted-Python mailing list [email protected] http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python
jsonphotoclient.py
Description: application/python
photoserver.py
Description: application/python
# jasstest.tac - controlling file for a single instance jass webapp
# -*- coding: iso-8859-1 -*-
#
# author : Werner Thie, wth
# last edit: 20.03.2009
# modhistory:
# 20.03.2009 - wth, created
import sys, os
path = os.getcwd()
sys.path.append(path)
from twisted.python import log
from twisted.python.log import ILogObserver, FileLogObserver
from twisted.python.logfile import LogFile
from twisted.internet import reactor
from twisted.application import service, strports, internet
from photoserver import gRSRC, JSONFactory
application = service.Application("photoserver")
application.setComponent(ILogObserver,
FileLogObserver(LogFile('photoserver.log', '/var/log',
rotateLength=10000000)).emit)
gRSRC = JSONFactory()
#site = server.Site(gRSRC)
webserver = strports.service("tcp:9000", gRSRC)
webserver.setServiceParent(application)
#this main() is only used for debugging the server, this file should be run
with twistd
def main():
log.startLogging(sys.stdout)
reactor.listenTCP(9000, gRSRC) #start only a basic service when
debugging
reactor.run()
if __name__ == '__main__':
main()
_______________________________________________ Twisted-Python mailing list [email protected] http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python
