PDA

View Full Version : [LOGIC] elapsed



null null
12-01-2004, 05:55 PM
Hello Enrico

Could you explain "elapsed"

HydPress1 = HydPress1 + (elapsed * 80)

David

Enrico Schiratti
12-02-2004, 06:57 AM
Hi,

this is indeed a useful one. It will return the elapsed time since the last

loop and allows smooth increments independently of the cycle times...

Ciao

Enrico

"David Allen" wrote in message
news:273535.54342@wb.onvix.com...
> Hello Enrico
>
> Could you explain "elapsed"
>
> HydPress1 = HydPress1 + (elapsed * 80)
>
> David
>

Peter Dowson
12-02-2004, 11:49 AM
On 12/2/2004 5:57:31 AM, Enrico Schiratti wrote:
>Hi,
>
>this is indeed a useful one.
>It will return the elapsed
>time since the last
>loop and allows smooth
>increments independently of
>the cycle times...

Units? Seconds, Millisecinds, Microseconds? Or is this one of those things
where you try any value, then double or halve it, and so on?

Best regards,

Pete

Enrico Schiratti
12-08-2004, 03:01 PM
Hi,

> Units? Seconds, Millisecinds, Microseconds? Or is this one of those
things
> where you try any value, then double or halve it, and so on?

The unit for the "elapsed" value is seconds.

Thus if you want something to go from 0 to 100 in ten seconds, you use:

myValue = myValue + ( elapsed * 10 )

Ciao

Enrico

Enrico Schiratti
12-08-2004, 03:05 PM
Come to think of it, I could add a more explicit

seconds

and

milliseconds

Ciao

Enrico


"Enrico Schiratti" wrote in message
news:275403.54342@wb.onvix.com...
> Hi,
>
>> Units? Seconds, Millisecinds, Microseconds? Or is this one of those
> things
>> where you try any value, then double or halve it, and so on?
>
> The unit for the "elapsed" value is seconds.
>
> Thus if you want something to go from 0 to 100 in ten seconds, you use:
>
> myValue = myValue + ( elapsed * 10 )
>
> Ciao
>
> Enrico
>