On 21/12/11 16:25, michael.vancann...@wisa.be wrote:
On Wed, 21 Dec 2011, Henry Vermaak wrote:
On 21/12/11 15:56, Felipe Monteiro de Carvalho wrote:
On Wed, Dec 21, 2011 at 4:53 PM, Henry
Vermaak<henry.verm...@gmail.com> wrote:
Spinning like this is bad news for efficiency and battery life of
embedded
devices.
Well, using X11 in an embedded device by itself is a very bad choice
Better tell Maemo they've made a very bad choice, then. It's not just
embedded devices, laptops have batteries, too. You're wasting CPU and
power just spinning around a loop, so even if your app isn't active,
it's still waking up every 50ms. I don't consider this very good
programming practice.
But presumably only if you are using a timer, in which case that's exactly
what the programmer wanted ?
No, he's got a hard coded wakeup, since he wants to support multiple
timers by adding them up (sometimes "guessing" the value). If I set a
timer for 1 hour, I don't want the program to wake up every 50ms.
Henry
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal