Sebastien,
If I understand what you are describing then think about this.
1. You have two separate computers with two different clocks. These
clocks are asyncronous. In order to expect consistant results you'd need to
have the clocks phased locked so that they are both derrived from the same
reference clock.
2. Taking into consideration item 1, it appears to me that the RTAI's
computer clock is running faster than the RTL computers clock. That is why
you get the drift.
I hope I have helped and understood what you had described.
Janet Estabridis
-----Original Message-----
From: Wayne E. Van Loon Sr.
To: [EMAIL PROTECTED]
Sent: 6/28/01 8:37 PM
Subject: Re: [rtl] Time not so accurate ?
Sebastien GAUME wrote:
>
> Hello,
>
> I want to check how accurate the functions rt_get_time() of RTAI and
> gethrtime() of RTLinux are, and to draw a comparison between these two
> functions. To do so, I connected two PCs through a parallel wire. On
> each PC, one of the two RT systems is running.
>
> One PC is considered as a sender. A periodic task wakes up every
> millisecond, gets time, writes on the parallel port. The other PC is
> considered as a receiver. It's waiting for an interrupt coming from
the
> 'sender' PC. Each time an interrupt occures, the associated handler
> wakes up and gets time.
>
> After a quick glince at the different measured times (those of the
> sender, and those of the receiver), I discovered that :
> - the periodic task (that is to say the sender) wakes up every
> millisecond, as expected ;
How was this verified?
> - the handler (the receiver) does not wake up every millisecond !
> There's a drift. The first measured times are OK, not so far from
those
> of the sender, but after a while, it's not good anymore.
>
> The results remain the same, whatever the RT system is used for the
> sender or the receiver. I tried the four possibilities, and each time
> there was a drift. Thus, when the receiver is running under RTAI, it's
> an increasing drift, whereas it's a decreasing one when the receiver
is
> running under RTLinux.
>
> I would greatly appreciate your help.
>
> Sebastien
>
Do you mean here that the elapsed time as measured in the receiver is
not one millisecond
and that the sum of the deviation from the expected 1 MS period
accumulates to a positive
sum of errors when RTAI is the receiver and accumulates a negative sum
of errors when rtl
is the receiver (respondent)? Or does the receiver initially have no
error and after a
while start having a consistent error?
Wayne
> ----- End of forwarded message from [EMAIL PROTECTED] -----
> -- [rtl] ---
> To unsubscribe:
> echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
> echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
> --
> For more information on Real-Time Linux see:
> http://www.rtlinux.org/
----- End of forwarded message from [EMAIL PROTECTED] -----
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
--
For more information on Real-Time Linux see:
http://www.rtlinux.org/
----- End of forwarded message from [EMAIL PROTECTED] -----
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
--
For more information on Real-Time Linux see:
http://www.rtlinux.org/