El Sábado, 10 de Junio de 2006 05:34, George Boudreau
escribió:
> Manuel,
>
> I see you are trying to fine tune the delay
variable, compensate for
> bash overhead. I did not know you wanted a precise time
display so I
> never validated the timestamp.. it looked close enough
for government
> work However it
lost time even on my machine.
Well, accuracy isn't the goal, but the previous version was
loosing 16 secs.
each minute on my machine, and that looks excessive to me
> I have included a different concept for the progress
bar. Instead of
> counting seconds via timed loop just use the bash
internal variable
> $SECONDS.
Great.
> notes::
> Occasionally you will see an empty space in the
progress bar and that
> is due to the priority assigned to unpacking a large
package. Since we
> are using actual seconds and not counts the space will
be 'missed'
> seconds.
In my tests the blank space in printed aprox. each 30-80
seconds, depending on
CPU load. Looks like it's auto-adjusting the cursor speed
and the time
counter to the system clock.
Using any sleep value <= .13 there is no blank spaces
(the same position is
drawed two times when the adjusting occurs) and the time
counter keep
accurate with system clock.
I will commit it with sleep .12, that looks more failsafe,
after build some
more targets.
> Does this method have holes.. possibly.
Don't found any hole yet
--
Manuel Canales Esparcia
Usuario de LFS nº2886: http://www.linuxfroms
cratch.org
LFS en castellano: http://www.escomp
oslinux.org/lfs-es http://www.lfs-es.com
TLDP-ES: http://es.tldp.org
--
http://linuxfromscratch.org/mailman/listinfo/alfs-discu
ss
FAQ: http://www.linux
fromscratch.org/faq/
Unsubscribe: See the above information page
|