[Asterisk-Users] TDM users: modified zttest.c for testing
Rich Adamson
radamson at routers.com
Wed May 4 20:16:20 MST 2005
> > > > > > TDM & X100P card users:
> > >
> > > > > I get average numbers very close to 1.024 (especially if I take some
> > > > > rounding error into account).
> > > >
> > > > That's a very good point. Now I'm not sure since the only thing I've
> > > > got to go by is existing code in zttest.c which implies 8192, and
> > > > data arrives in 1024 byte frames.
> > > >
> > > > I'll dig a little deeper to see if I can figure out which one _is_
> > > > correct.
> > >
> > > I also recommend only printing 3 decimal places for the times. All of
> > > the additional digits are just noise.
> >
> > Why do you say 3 when the os call returns 6 places?
> >
> > The thought process is essentially oriented around identifying timing
> > issues (missed frames) with the TDM card, and it seems from the users
> > posting "it works" type responses that six digits _are_ indicative
> > of the issue.
> >
> > Help me understand...
>
> While the OS may be returning more digits, the interrupt on the card is
> only happening on millisecond boundaries (3 decimal places). A missed
> frame will add 0.001 to the time, not something smaller than that.
Based on what I think I've read in the chip specs, there is no such
millisecond timer. Rather, it appears the interrupt is raised when
the pci chip buffer contains sufficient data (apparently 1024 bytes
I'm assuming).
Regardless, the microsecond timer (from the OS) is a reasonable way to
measure elapsed time and the number of significant digits is better
(and more accurate) then whatever is on the card. So, displaying the
six digits is very reasonable.
More information about the asterisk-users
mailing list