Archive for the ‘samples’ Category

Aug

24

Long keypress using keycapture

By raissa

While developing Fake Call, we had to find a way of detecting long keypress of an especific key. The solution we found was to keep calling a function that puts the current time in a list when the key is pressed and check everytime if the last value minus the first is equal to the [...]

Jan

14

How to make animations without block and using sprites

By diego

Here is a good code example of how to make animations without block and using sprites in python for series 60.

Aug

29

Getting Routs

By souto

This example shows, using a gmaps feature, how to get rout from a place to another in Python for s60. You can submit two locations or two GPS coordinates and get the rout.

#routs.py
 
import urllib
from html_parser import *
 
def parser_html(start,end):
rout_link = "http://www.google.com.br/maps?site=local&
[...]

Aug

8

SOAPpy for s60

By souto

Here is the package of SOAPpy for s60.
A quick explanation of how the porting was made.
And finally a small example of a calculator using the mobile as a client and a server at PC.

#SOAPcalculator.py
 
import SOAPpy
 
calculator = SOAPpy.SOAPProxy("http://localhost:8080/")
 
a = 8
b = 2
 
print calculator.plus(a,b)
print calculator.minus(a,b)
print calculator.multiply(a,b)
print calculator.divide(a,b)

#Server.py
 
import SOAPpy
 
class Calculator:
 
def plus(self, a, b):
[...]

Jul

31

How to include python path when using the nokia emulator

By admin

If you import a module that is in python s60 emulator directory it will not work. Even if your module that is responsible to do the import lies in the same directory.
To solve this problem you can do this:
import sys
sys.path.append(“c:\\python”)