public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Jonathan Larmour <jlarmour@redhat.com>
To: Ling Su <lingsu@palmmicro.com>,
	eCos discussion <ecos-discuss@sources.redhat.com>
Subject: Re: [ECOS] Regarding to eCos on VRC4373
Date: Wed, 10 Jan 2001 09:17:00 -0000	[thread overview]
Message-ID: <3A5C9902.4BE2B9F7@redhat.com> (raw)
In-Reply-To: <005e01c07ad5$5ba58210$0301a8c0@leopard>

Ling Su wrote:
> 
> Another questions is: What's the time unit used in eCos, in kernel API or
> timer/counter object, such as cyg_thread_delay(time), how to set the delay
> time, it is in microsecond unit or more?

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.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Un cheval, pas du glue. Pas du cheval, beaucoup du glue. || Opinions==mine

  parent reply	other threads:[~2001-01-10  9:17 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-01-09 14:59 Ling Su
2001-01-09 16:44 ` Jonathan Larmour
2001-01-09 23:37   ` Ling Su
2001-01-10  3:30     ` Nick Garnett
2001-01-10  5:15       ` [ECOS] assertion checks for stack Joerg Rapka
2001-01-10  9:10     ` [ECOS] Regarding to eCos on VRC4373 Jonathan Larmour
2001-01-10  0:19   ` Ling Su
2001-01-10  9:08     ` Jonathan Larmour
     [not found]   ` <005e01c07ad5$5ba58210$0301a8c0@leopard>
2001-01-10  9:17     ` Jonathan Larmour [this message]
2001-01-10 14:08       ` Ling Su
2001-01-10 14:17         ` Jonathan Larmour
2001-01-10 15:45         ` Grant Edwards

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3A5C9902.4BE2B9F7@redhat.com \
    --to=jlarmour@redhat.com \
    --cc=ecos-discuss@sources.redhat.com \
    --cc=lingsu@palmmicro.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).