Re: Request internet connection with python

2008-10-10 Thread Owen Williams
On Thu, 2008-10-09 at 21:40 +, Hermann Lacheiner wrote:
 Hi all!
 
 I am trying to request an internet connection using conic and python. 
 I started with this example:
 https://garage.maemo.org/svn/pymaemo/packages/python-conic/branches/chinook/tests/test_connect.py
 
 The problem is now, that the callback function is never called, when the
 connection becomes available (the Nokia successfully connected to my WLAN).
 Were there any API changes in Diablo or does someone know any hint, why the
 callback is never called. Thanks for your help!


I've also seen this problem.  It never worked, even on chinook.

owen

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: R: Can't force display light to stay on forever?

2008-10-03 Thread Owen Williams
Is there a good way of doing this temporarily, for instance while
playing back video?  Can I do it in python?  Right now I'm telling the
backlight to turn on every 8 seconds or so, but even that doesn't really
work (sometimes the display goes dim and then pops back).

I don't want to temporarily change any configuration files in case my
program crashes before it can unset this option.

Owen


On Thu, 2008-10-02 at 16:25 +0200, Marco Solari wrote:
 Thanks! It worked like a charm ;-)
 Now the limit is 480 minutes (8 hours), which I suppose is quite a long
 time... ;-)
 Cheers.
 
   Marco

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Announcing PenguinTV, rss reader and podcast downloader

2008-10-03 Thread Owen Williams
I've finally finished the port of my RSS/Podcast software, PenguinTV, to
hildon and maemo.  The big sticking point was how to package
python-gtkmozembed support, but I figured that out and now PenguinTV is
on extras-devel for testing and comments.  If it seems to work for
people, then I'll promote it to extras.

Where to find it:
extras-devel

Here's a quick feature list:

* 5-year development history, with workarounds for all sorts of
malformed feeds
* responsive on maemo even with 100 feeds
* local image caching, for viewing feeds even when you don't have an
internet connection
* support for enclosed media, including video and audio
* built-in gstreamer media player that remembers playback position so
you can exit and restart where you left off
* tagging support for quick access to subsets of your feeds
* mostly finger-friendly interface, although I could use some help with
this
* power-management Good Citizen -- no ticking clocks or running threads
unless needed -- leave it running all day


Here are some problems:

* startup time is really slow right now, and I'm trying to improve it.
Since PenguinTV is python-based, most of the time is just starting up
python and loading all the modules it needs (which is a lot).  Another
big chunk of time is loading the glade UI.  I would appreciate any help
fixing this.
* feed updating is very slow, but it is steady and it won't peg the CPU.
Feed updates are done at priority 15 to ensure that the device remains
responsive and doesn't pop up not responding messages.
* penguintv eats a lot of RAM.  not much I can do about this.
* gtkmozembed doesn't support finger-scrolling.  I don't know how to fix
this.

Please give it a go and let me know what you think!

Owen Williams

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: R: Can't force display light to stay on forever?

2008-10-03 Thread Owen Williams
Ah yes, there is a binding in python.  I was using display_state_on
instead of display_blanking_pause, that was my problem.

thanks,
owen


On Fri, 2008-10-03 at 16:23 +0200, Frantisek Dufka wrote:
 Owen Williams wrote:
  Is there a good way of doing this temporarily, for instance while
  playing back video?  Can I do it in python? 
 
 You need to periodically call osso_display_blanking_pause in libosso
 http://maemo.org/api_refs/4.1/libosso-2.16-1/
 http://maemo.org/api_refs/4.1/libosso-2.16-1/group__Devstate.html#gbd82d7b0160e26cd15479f2685697322
 
 Not sure if there is python binding but it is quite likely.
 
 Frantisek
 
 

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


trouble autobuilding python bindings, configure barfs on python2.5

2008-09-30 Thread Owen Williams
I am trying to upload my package to extras, and it keeps failing.  While
my application is mostly python, I have to build python-gtkmozembed
support for it.  I thought I set up the debian/rules file correctly but
it's failing now.

The build log is here:
https://garage.maemo.org/builder/diablo/penguintv_3.8-1/armel.build.log.FAILED.txt

debian/rules runs configure with this line (host and build are
autodetect):
PYTHON=/usr/bin/python2.5 ../../gtkmozembed/configure\
--host=arm-linux-gnueabi \
--build=arm-linux-gnueabi  \
--prefix=/usr \
--with-gtkmozembed=gtkembedmoz


and then it bombs here:

checking whether /usr/bin/python2.5 version = 2.3... configure: error: too old
make: *** [configure-stamp] Error 1


which makes no sense.  python2.5 is clearly newer than 2.3, but whatever
configure is using to test the version number is failing.  Am I doing
something wrong?

thanks,
Owen Williams

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: trouble autobuilding python bindings, configure barfs on python2.5

2008-09-30 Thread Owen Williams
Thanks for the off-list message.  The answer was indeed a missing
build-depends section in the control file.

owen


On Tue, 2008-09-30 at 09:17 -0400, Owen Williams wrote:
 I am trying to upload my package to extras, and it keeps failing.  While
 my application is mostly python, I have to build python-gtkmozembed
 support for it.  I thought I set up the debian/rules file correctly but
 it's failing now.
 
 The build log is here:
 https://garage.maemo.org/builder/diablo/penguintv_3.8-1/armel.build.log.FAILED.txt
 
 debian/rules runs configure with this line (host and build are
 autodetect):
 PYTHON=/usr/bin/python2.5 ../../gtkmozembed/configure\
   --host=arm-linux-gnueabi \
   --build=arm-linux-gnueabi  \
   --prefix=/usr \
   --with-gtkmozembed=gtkembedmoz
 
 
 and then it bombs here:
 
 checking whether /usr/bin/python2.5 version = 2.3... configure: error: too 
 old
 make: *** [configure-stamp] Error 1
 
 
 which makes no sense.  python2.5 is clearly newer than 2.3, but whatever
 configure is using to test the version number is failing.  Am I doing
 something wrong?
 
 thanks,
 Owen Williams


___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: Treeview drag and drop

2008-08-25 Thread Owen Williams
I find I have to tape and select the item, then tap and hold to get it
to drag and drop.  If I tap to select and immediately start dragging, I
get the multi-select thing.

If your treeview does not have multiselect, that sounds like a gtk bug.

owen

On Mon, 2008-08-25 at 10:23 -0600, Jeffrey Barish wrote:
 I have a treeview in which it is possible to reorder rows by drag and drop. 
 (It is also possible to drag a row into the treeview from another
 treeview.)  It all works fine on Ubuntu, but on maemo I find that to drag a
 row from the treeview in question to itself, I have to move the stylus to a
 point outside the treeview before the movement registers as a drag.  Any
 movements confined to the treeview itself will not trigger the drag.  I
 suppose that there must be a problem with drag_check_threshold.  Has anyone
 else has observed this behavior?  Is there a workaround?

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: need help uploading to Extras

2008-08-05 Thread Owen Williams
On Tue, 2008-08-05 at 10:38 +0200, Benoît HERVIER wrote:
 If i understand Sonata MDP is a Python GTK application, if nothing
 need to be compiled, you can use py2deb to build a debian source
 package that can be used by the autobuilder. I use it to build
 mCalendar, Home* applet ...
 
 It s available in the extras-devel repository.
 
 And you can use it on a nit :)
 
 You need to set your gpg key and ssh rsa key on the nit and the maemo
 repository.
 
 To use it :
 
 import py2deb
 __version__ = 0.5.8
 __build__ = 1 # Result is 0.5.8-1
 p=Py2deb(myuberpackage)
 p.description=Best Package !
 p.author=Benoît HERVIER
 p.mail=[EMAIL PROTECTED]
 p.depends = python2.5-runtime
 p.section=user/programming
 p.arch=any
 p.urgency=low
 p.distribution=diablo
 p.repository=extras-devel
#Here installation of files :
 p[/usr/lib/python2.5/site-packages] =
 [py2deb.py,py2tar.py,py2dsc.py,py2changes.py,md5hash.py]
 p[/usr/bin] = [py2deb.launch]
 
 print p
 print 
 p.generate(__version__,__build_,tar=True,dsc=True,changes=True,build=False,src=True)
 
 This will open a xterm, and follow the instructions (there is many
 debug displayed thing) ... but to resume it ll ask two time to enter
 your gpg password to sign .dsc and .changes file ... and press some
 time enter key.
 
 Once xterm windows close, you can use extras assistant to upload your package.
 

Is there a reason it can't build the deb file?  It'd be nice to be able
to do it in one step instead of needing to use dpkg-buildpackage
afterward.  Otherwise this is a very nice tool!

Hm, does it support specifying a postinst script?  That's sort of
necessary to pop up a window asking for where the user wants to place
the application in the menus.

owen

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: need help uploading to Extras

2008-08-04 Thread Owen Williams
On Sat, 2008-08-02 at 13:50 +0400, Andrew Zabolotny wrote:
 From Fri, 01 Aug 2008 08:10:35 -0400
 Owen Williams [EMAIL PROTECTED] wrote:
 Have you used some tool to build the debian/ directory? If you're
 building the .deb file manually, that won't work for the builder, as it
 needs automatic instructions for building your package.

I am building the deb manually.  I don't know how to make a debian/
directory.  Again, the instructions are always C-specific.  The idea
below of looking at apt-get source sonata is a great idea to help with
this.

 
  The first is a hildonized version of the Sonata MPD client
  (http://sonata.berlios.de/).  I've uploaded my patched tarball and
  built deb here: http://ywwg.com/maemo/  Version 1.5.2 is the latest
  version.
 I can help you with packaging, as I'm interested too in Sonata. Do you
 have a project on garage for this?

No, I just have a diff file against current Sonata SVN.  (The Sonata
maintainer has said that the diff is too large to merge into trunk).
I'll set up a garage page, but I'll need some help setting up a repo
that can pull in changes from Sonata's primary SVN from time to time.

 
 Also you may try to get/adapt the packaging scripts from the Ubuntu or
 Debian version of Sonata. Just run apt-get source sonata in some
 directory from Ubuntu/Debian.

that's a good idea


 That's easy, really. You just have to read a little docs (for example,
 here: http://www.debian.org/doc/maint-guide/

I think I'll focus on getting sonata to work, then start wrestling with
this problem.


 I believe that's because you don't provide larger icons (app menu
 uses 64x64 icons as far as I understand), or don't run
 gtk-update-icon-cache. You should put them in 
 /usr/share/icons/hicolor/64x64/apps/ and run
 
 gtk-update-icon-cache -f /usr/share/icons/hicolor
 
 from your postinst hooks of the .deb package.


I thought scalable would be enough :).  

thanks for all the info, I'll see if I can beat on this a little more.

owen

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: Contribution code, ...

2008-01-22 Thread Owen Williams
The contribution codes work now, I got an email with an updated URL from
nokia.  No need to yak on the phone!

owen


On Mon, 2008-01-21 at 10:15 -0900, John Mitchell wrote:
 Frank,
 
 On 1/21/08, Frank Banul [EMAIL PROTECTED] wrote:
  I just stated that the final price should be $145 (well 99 euros) and
  gave them my code.
 
 
 I just called and they said they would take 145 off the price, so
 it would be 344 not that the final price would be 145. I really would
 like to know who to talk too. This process has been so crazy.
 
  Frank
 
  On Jan 21, 2008 1:02 PM, John Mitchell [EMAIL PROTECTED] wrote:
   Frank,
  
   On 1/21/08, Frank Banul [EMAIL PROTECTED] wrote:
US Store.
   
I told them the discount code was 99 euros, or $145. I spoke with
Chris, I never found out the supervisor's name.
   
  
   So you are saying that the device cost before shipping should be
   $145 dollars. So the balance for the code should be about 335.00? That
   is what the person I spoke with asked about several times. I will try
   that and see what happens.
  
  
Frank
   
On Jan 21, 2008 12:42 PM, John Mitchell [EMAIL PROTECTED] wrote:
 Frank,

 On 1/21/08, Frank Banul [EMAIL PROTECTED] wrote:
  Hi All,
 
  I called letstalk.com to ask when the web site might be ready. The
  person assisting me could not provide and answer but instead offered
  to place my order at the correct discounted price. I tried it and it
  worked like this. Place the order at full price. In a few hours a
  supervisor will override the price. This worked out and now I have 
  my
  N810.
 

 Thanks for working this out. I assume this is the US store? I
 tried calling them and they wanted to know how much my discount should
 be (which was _really_ odd, I could have said the device was free), I
 told them I did not know what the discount balance was supposed to be.
 So they offered 75 dollars off, which I thought was too low in light
 of our European friends picking them up for 99 euro. They said they
 could do no better, so I gave up. How much did you tell them it should
 be and who did you talk to? I would like to talk to the same
 supervisor so the transactions is easy.


  Thanks to all responsible. Now if you will excuse me, I have an
  application to port. :)
 
  Frank
 
  On Jan 16, 2008 12:00 PM, Scott Bambrough [EMAIL PROTECTED] wrote:
   I just placed my order on the Canadian site as well.  Thanks Quim 
   and
   Nokia.
  
   Scott
  
  
   Mike Morrison wrote:
On Jan 15, 2008 10:03 PM, Quim Gil [EMAIL PROTECTED] wrote:
   
ext Michael Wiktowy wrote:
   
   
Since Canada was not on the initial list of countries to get 
the N810
from, is there something that needs to be done by the code 
recipient
to switch the code over from the US to Canada or should the 
US code
work once the Canadian site is updated?
   
Since Canada joined late with the best of the intentions, they 
will deal
with the cases one by one no matter what country your code 
belongs to
(as far as you have a real code and you provide a Canadian 
delivery
address).
   
Quim
   
   
I just placed my order with the Canadian site, discount code 
and all
(it came to $175 with shipping  taxes)! Thank you Quim and 
Nokia!
   
   
Mike
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers
   
   
   
   ___
   maemo-developers mailing list
   maemo-developers@maemo.org
   https://lists.maemo.org/mailman/listinfo/maemo-developers
  
  ___
  maemo-developers mailing list
  maemo-developers@maemo.org
  https://lists.maemo.org/mailman/listinfo/maemo-developers
 



 --
 John P. Mitchell [EMAIL PROTECTED]

   
  
  
   --
  
   John P. Mitchell [EMAIL PROTECTED]
  
 
 
 

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: Suggestions for storing data for Python based Maemo application

2008-01-08 Thread Owen Williams

On Tue, 2008-01-08 at 08:33 +1100, Devraj Mukherjee wrote:
 Hi all,
 
 We are developing an application for Maemo which is if you like a
 custom data collection application for a local firm. The application
 is being written in Python 2.5 against the Chinook framework and is
 expected to create upto about 200 records (all up). Are there any
 general suggestion for what we should use to store data? At this stage
 thoughts/options are
 
 - Python object serialization

This can be very dangerous, as even slight changes in data structure can
make the serialized objects unreadable. 

 - XML file

This is good for small to medium data sets, but can be slow to process
with large amounts of data.

 - SQLite database

This is better for large data sets.

Owen Williams

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: Contribution code, ...

2008-01-04 Thread Owen Williams
Based on the email it looks like US developers are still out of luck.
Hopefully they come back in stock before the end of february --
hopefully this won't be another Wii.

owen


On Fri, 2008-01-04 at 17:17 +0200, Michael Stepanov wrote:
 I just received email from Nokia and made the order on the UK on-line
 shop! Thanks a lot Nokia and Maemo for the great chance  to get N810! 
 
 On 1/4/08, Torello Querci [EMAIL PROTECTED] wrote:
 Hi to all, now the discount code work on Italy. The order form
 is 
 already send ... :) ... but the discount is not 360€ not 499
 €  :(
 
 Bye.
 
 2008/1/4, Mathieu Pillard [EMAIL PROTECTED]:
  I got the mail with the new code and tried it on 
  https://boutique.nokia.fr. It worked... better than I
 expected:
 
  Sous-total: 499,00€
  Escompte : -499,00€
 
  Yes, for those who do not understand french, that means I
 just got a 
  499 euros reduction on a device worth 499 euros :-) I
 haven't
  completed the order, and I guess it would probably not be
 processed
  anyway... I have no idea where to report this so I figured
 I'd post it 
  here.
 
 
  --
  mat
  ___
  maemo-developers mailing list
  maemo-developers@maemo.org
  https://lists.maemo.org/mailman/listinfo/maemo-developers
 
 ___
 maemo-developers mailing list 
 maemo-developers@maemo.org
 https://lists.maemo.org/mailman/listinfo/maemo-developers
 
 
 
 -- 
 Cheers,
 Michael 
 ___
 maemo-developers mailing list
 maemo-developers@maemo.org
 https://lists.maemo.org/mailman/listinfo/maemo-developers

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: chinook, python, libglade and toolbars

2007-12-11 Thread Owen Williams

On Tue, 2007-12-11 at 13:25 +0100, Luca Ognibene wrote:
 I'm porting a program wich uses libglade for its gui to maemo.
 I've seen that there are two versions of libglade in chinook:
 1:2.4.0-1osso2 and 1:2.6.2-1indt1
 With libglade 2.4.0 i have a problem with toolbars... i've done this
 code to reparent a toolbar from a normal toolbar to the hildon
 toolbar:
 
 toolbar = gtk.Toolbar ()
 for child in self.toolbar2.get_children():
 child.reparent(toolbar)
 self.window.add_toolbar(toolbar)
 self.toolbar2.destroy()


for comparison, my code looks like this:

vbox = ... all my window contents ... 
toolbar = self._widgetTree.get_widget('toolbar1')
toolbar.unparent()
self.window.add(vbox)
self.window.add_toolbar(toolbar)

The APIs discourage using unparent, but it works for me.

owen

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: chinook, python, libglade and toolbars

2007-12-11 Thread Owen Williams
I'm using 2.6.2-1indt1

owen


On Tue, 2007-12-11 at 18:45 +0100, Luca Ognibene wrote:
 On Dec 11, 2007 6:23 PM, Owen Williams [EMAIL PROTECTED] wrote:
 
  On Tue, 2007-12-11 at 13:25 +0100, Luca Ognibene wrote:
   I'm porting a program wich uses libglade for its gui to maemo.
   I've seen that there are two versions of libglade in chinook:
   1:2.4.0-1osso2 and 1:2.6.2-1indt1
   With libglade 2.4.0 i have a problem with toolbars... i've done this
   code to reparent a toolbar from a normal toolbar to the hildon
   toolbar:
  
   toolbar = gtk.Toolbar ()
   for child in self.toolbar2.get_children():
   child.reparent(toolbar)
   self.window.add_toolbar(toolbar)
   self.toolbar2.destroy()
 
 
  for comparison, my code looks like this:
 
  vbox = ... all my window contents ...
  toolbar = self._widgetTree.get_widget('toolbar1')
  toolbar.unparent()
  self.window.add(vbox)
  self.window.add_toolbar(toolbar)
 
  The APIs discourage using unparent, but it works for me.
 
 
 Thanks but i've tried but python segfaults for me if i try unparent... argh!
 Are you using chinook? which libglade version?
 
 

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


repositories: please provide microb-gtkmozembed

2007-11-27 Thread Owen Williams
Right now the repositories only include microb-engine and
microb-engine-dev.  However this does not provide gtkmozembed, which is
necessary for building gnome-python-extras, which is necessary for
embedding mozilla inside gtk python applications.

If I build microb-engine from SVN, I do get a microb-gtkmozembed
package, but I'm not sure it's working.  It's not providing a correct
pkgconfig file, for instance.

Please add microb-gtkmozembed to the repositories.  It also needs to be
fixed to provide a correct pkgconfig file.

thanks,
Owen Williams

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: repositories: please provide microb-gtkmozembed

2007-11-27 Thread Owen Williams

On Tue, 2007-11-27 at 23:42 -0400, tonikitoo (Antonio Gomes) wrote:
 https://garage.maemo.org/svn/browser/mozilla/trunk/libgtkembedmoz/ ?
 
 regards
 
 
 

but apt-get can only find microb-engine and microb-engine-dev, neither
of which provide gtkmozembed.

I should be able to run:
apt-get install microb-gtkmozembed

and have it work

owen

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


new developer, dpkg-reconfigure missing?

2007-11-12 Thread Owen Williams
I got accepted into the n810 dev program, and I'm trying to get set up
with the SDK so I can start working on porting my app.  I installed
scratchbox and the maemo SDK, but I'm having some problems.

My program is written in python, so I tried to install pymaemo using the
instructions on the pymaemo site (I changed the deb line to refer to
chinook of course).  However the apt-get command fails because it says
that dpkg-reconfigure is not found.  I looked around scratchbox, and
indeed it is missing.

I haven't found any help googling around, other than that
dpkg-reconfigure looks like it should definitely be included in the
scratchbox installation.

Any help getting me started would be greatly appreciated.

thanks,
Owen Williams

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers