This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Using instrument buffer by applications?


On 2008-07-21, Andrew Lunn <andrew@lunn.ch> wrote:

>> Has anybody used the instrument buffer scheme to log
>> application events?
>
> I have, but my events were over a short period of time.

For my apps, there are going to be bursts of a few events
separated by gaps that are pretty large (on the scale of the
HAL counter).

> Interestingly, if you look in
> packages/kernel/current/src/instrmnt/meminst.cxx you will
> find:
>
> #ifdef CYGVAR_KERNEL_COUNTERS_CLOCK        
> //        p->timestamp        = Cyg_Clock::real_time_clock->current_value_lo();
>         HAL_CLOCK_READ( &p->timestamp );
> #else
>         p->timestamp        = 0;
> #endif
>
> so it looks like you can change from HW ticks to slower eCos
> timer ticks.

I saw that, but assumed it would break other stuff if I changed
it.  I thought about adding aonther field so that it recorded
both the low 32 bits of the system tick counter and the value
from HAL_CLOCK_READ().  That would get me a rollover at about 3
(1ms) or 30 years (10ms), but I'd still have a resolution of
about 25ns.

years with 

-- 
Grant Edwards                   grante             Yow! Hello...  IRON
                                  at               CURTAIN?  Send over a
                               visi.com            SAUSAGE PIZZA!  World War
                                                   III?  No thanks!


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]