Active Topics

 



Notices


Reply
Thread Tools
ericdkirk's Avatar
Posts: 232 | Thanked: 45 times | Joined on Jul 2007 @ Tennessee, US
#11
Same here, I am sad to say the neither of your scripts would run on my N800 it was mad about some font. Thanks for the effort though.

Code:
Nokia-N800-23-14:/home/user/MyDocs/nrace01# python nrace.py
nrace.py:5: RuntimeWarning: import cdrom: No module named cdrom
  from pygame import *
nrace.py:5: RuntimeWarning: import joystick: No module named joystick
  from pygame import *
/home/user/MyDocs/nrace01/ci_init.py:107: RuntimeWarning: use font: libSDL_ttf-2
.0.so.0: cannot open shared object file: No such file or directory
  font=pygame.font.Font(path+"nosnb.ttf",43)             #Boldish font for the a
larm
Traceback (most recent call last):
  File "nrace.py", line 6, in <module>
    import ci_init as ci
  File "/home/user/MyDocs/nrace01/ci_init.py", line 107, in <module>
    font=pygame.font.Font(path+"nosnb.ttf",43)             #Boldish font for the
 alarm
  File "debian/python2.5-pygame/usr/lib/python2.5/site-packages/pygame/__init__.
py", line 52, in __getattr__
NotImplementedError: font module not available
 

The Following User Says Thank You to ericdkirk For This Useful Post:
ciroip's Avatar
Posts: 334 | Thanked: 366 times | Joined on Nov 2008 @ Italy
#12
strange... to avoid this kind of errors I usually pack everything I can with the application: the nosnb.ttf font (a standard nokia font on the n810) should be under a directory data at the same level of nrace.py togheter with the background pic, in your case:
Code:
/home/user/MyDocs/nrace01/
but if you received the same error even with the .deb I would believe is something bad with the pygame library installed on the tablet
the
Code:
----NotImplementedError: font module not available----
thing make me think
should be possible to test if you have that pygame module installed using the python commandline:
Code:
python
>>>import pygame.font
you should receive just the 2 usual pygame RuntimeWarnings about the missin modules cdrom and joystick
(retyping the import pygame.font a second time shoudl give you a cleaner feedback (no feedback at all in case of success)
To see the different answers you could try to import another pygame module less 'exotic' like:
Code:
>>>import pygame.event
or a mispelled one like
Code:
>>> import pygame.IHATEPYGAME
that should return with something like
Code:
  File "<stdin>", line 1, in <module>
ImportError: No module named IHATEPYGAME
In case you want give it a second shot I packed another version that should use a font already installed on the nokia (no more paths for the fonts but still use the pygame calls)

https://garage.maemo.org/frs/downloa...nrace02.tar.gz

buonanotte
__________________
I can't do it. No one can help.
[SIGPIC][/SIGPIC]

Flip Alarm Clock - 3DMania Theme - Synesthesia - Deluxepain
http://ciroip.blogspot.com/
http://twitter.com/ciroippolito

Last edited by ciroip; 2009-01-26 at 13:25.
 
Reply


 
Forum Jump


All times are GMT. The time now is 16:27.