Reply
Thread Tools
Posts: 258 | Thanked: 144 times | Joined on Oct 2009 @ Edinburgh
#11
Originally Posted by fpp View Post
I call FUD... All the objects, data structures and libraries (XML, network etc.) in Qt are available from PyQt, which does not eat your battery for lunch, and further cuts down the amount of code you write by another order of magnitude :-)
The battery drain kind of made sence to me, as a widget even doing nothing if it was perl (and i assume python) would need to have the interpreter going in the background. is that not the case?

So would a c++ solution not be better battery wise?

and again cause im a numpty, is PyQt standard on the device. so if an app is developed in pythong with QT. only the App needs installed, as it seems a bit over complicated to expect users to install other tools to use an app. (again if im talking out my rear end do feel free to set me straight)
 
Posts: 3,841 | Thanked: 1,079 times | Joined on Nov 2006
#12
The interpreter is not running around in the background. It executes the code while it's executing. How much battery is used is only a question of how long the application actually spin the CPU. A lot of applications on the earlier Nokia internet tablets are written in Python, a scripted language, and they're no more CPU/battery hogs than any other applications.
__________________
N800/OS2007|N900/Maemo5
-- Metalayer-crawler delenda est.
-- Current state: Fed up with everything MeeGo.
 

The Following 2 Users Say Thank You to TA-t3 For This Useful Post:
jeremiah's Avatar
Posts: 170 | Thanked: 261 times | Joined on Feb 2009 @ Gothenburg, Sweden
#13
Qt is going to be more widely used and officially supported by Nokia (they have purchased Trolltech the team that created Qt.) But at the moment, Qt is not the sole, canonical development platform - hildon is still widely used and supported.

If you want to have the highest level of community support for your app, including support from Nokia, then going down the C/C++ with Qt path is a very good choice. Python with Qt is also an excellent choice.
 
jeremiah's Avatar
Posts: 170 | Thanked: 261 times | Joined on Feb 2009 @ Gothenburg, Sweden
#14
Originally Posted by TA-t3 View Post
The interpreter is not running around in the background. It executes the code while it's executing. How much battery is used is only a question of how long the application actually spin the CPU. A lot of applications on the earlier Nokia internet tablets are written in Python, a scripted language, and they're no more CPU/battery hogs than any other applications.
Can you point to benchmarks or profiled code?
 
Posts: 3,841 | Thanked: 1,079 times | Joined on Nov 2006
#15
No, because there's been no obvious reason to do so. I seem to get exactly as many days out of the battery of my N800 when having Python applications running as when I don't have them running. Remember, most of the time the applications just present a user interface, so there's no CPU usage.
__________________
N800/OS2007|N900/Maemo5
-- Metalayer-crawler delenda est.
-- Current state: Fed up with everything MeeGo.
 
Posts: 3,319 | Thanked: 5,610 times | Joined on Aug 2008 @ Finland
#16
Originally Posted by cgarvie View Post
and again cause im a numpty, is PyQt standard on the device. so if an app is developed in pythong with QT. only the App needs installed, as it seems a bit over complicated to expect users to install other tools to use an app. (again if im talking out my rear end do feel free to set me straight)
You need to set your dependencies in you package/application, and then the application manager will automatically download any library that is needed, completely transparently to the end-user.
 

The Following 2 Users Say Thank You to attila77 For This Useful Post:
Posts: 3,319 | Thanked: 5,610 times | Joined on Aug 2008 @ Finland
#17
As for battery concerns - I feel it's not really a language/framework oriented thing. An error in power management (not really going to sleep, leaking memory, etc) are going to hurt more than any differences caused by language/framework. Also, if one is using a 'real' framework, like Qt, most of the heavy lifting is done in natively compiled libraries - if you stick to a few basic rules (no polling, avoid variable conversions, etc) the battery footprint of such applications is, again, very comparable, regardless if they were written in C, C++, Python or Perl.
 

The Following User Says Thank You to attila77 For This Useful Post:
daperl's Avatar
Posts: 2,427 | Thanked: 2,986 times | Joined on Dec 2007
#18
Originally Posted by wire-less View Post
Hi,

QT is a very complete C++ Library, I think it does not make much sense to use it with another language than C++. It does not only provide Gui-Classes. There are datastructures http://doc.trolltech.com/4.5/containers.html
Networking http://doc.trolltech.com/4.5/qtnetwork.html and a lot of other stuff reducing the c++-code you've to write.

Every QT call is feeded with QT Objects. So if you use it with another language there is a lot conversion work by the binding code. And if using from perl you've the interpreter running which eats your battery before lunch


wire-less
Yeah, sorry. I second the FUD. We're talkin' asynchronous, event-driven UI apps here. We're not drilling for oil. And all the heavy lifting is being done in the C/C++ shared libraries. I have 3 Python apps "running" 24/7, and although they suck memory, they don't suck CPU or battery.
__________________
N9: Go white or go home
 

The Following User Says Thank You to daperl For This Useful Post:
Posts: 258 | Thanked: 144 times | Joined on Oct 2009 @ Edinburgh
#19
Well i was up at 5:30 this morning and installed Qt SDK on my windows lap top as a first pass and managed to build the first examples in C++-GUI-Programming-with-Qt-4-1st-ed.pdf before i had to head out to work. So ive started looking.

Before i can do anything on my Linux box im gonna have to do some work on it. As its previously only been used for mythTV and i've only got about 100M left in the root partition
 
dormant's Avatar
Posts: 332 | Thanked: 76 times | Joined on Oct 2007 @ St. Augustine, Trinidad and Tobago
#20
I'm a hacker with Perl. I have some scripts that are useful to me. But I don't really have the time and wherewithal to try and turn them in to programs that run with Qt.

What I'd love to see is a packaging thing that will allow me to run one of my scripts from the desktop or menu and display the output in a scrollable box, with two buttons - rerun and quit. It might also have a pull-down menu of the recent scripts I have run.

This would be so much better than using xterm.
__________________
  • N900
  • N800
  • LD-3W
  • two magic OTG USB adapters
  • crossed fingers
 
Reply

Thread Tools

 
Forum Jump


All times are GMT. The time now is 21:30.