This is the mail archive of the ecos-discuss@sources.redhat.com 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]

Re: Regarding to eCos on VRC4373


> It is in clock ticks, which are platform-specific. You can use the kernel
> API functions at
> http://sources.redhat.com/ecos/docs-latest/ref/ecos-ref.9.html
>
> Specifically, look at the definition of cyg_resolution_t, and notice you
> can use cyg_clock_get_resolution( cyg_real_time_clock ) to get a
> cyg_resolution_t for your real-time-clock.
>
> A shortcut given that you know the platform is to look at the CDL for the
> vrc4373 which includes the fields CYGNUM_HAL_RTC_NUMERATOR and
> CYGNUM_HAL_RTC_DENOMINATOR which correspond to the fields in the
> cyg_resolution_t. This is 1000000000 and 100 respectively, giving
> 10,000,000 ns/tick == 10 ms/tick.
>
Thanks, Jifl,

If I need a timer faster than 10ms/tick, could I increase denominator or
decrease the numerator? I can it is a caculated value, user can not specify.
How could I change them and what is the consequences?

Regards,
-Ling


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