public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] short accurate delay in DSR or startup
@ 2004-07-27  4:14 harmon
  2004-07-27  5:35 ` Gary Thomas
  0 siblings, 1 reply; 3+ messages in thread
From: harmon @ 2004-07-27  4:14 UTC (permalink / raw)
  To: ecos-discuss

When initializing a chip, I need to delay for ~ 1 millisecond.  I can't
use any blocking calls, so I am now using a simple for loop to eat up
time.  Is there a portable, accurate way to delay within a DSR or
initialization code?

 

I am using ecos 2.0 on an x86 platform.

Larry


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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] short accurate delay in DSR or startup
  2004-07-27  4:14 [ECOS] short accurate delay in DSR or startup harmon
@ 2004-07-27  5:35 ` Gary Thomas
  0 siblings, 0 replies; 3+ messages in thread
From: Gary Thomas @ 2004-07-27  5:35 UTC (permalink / raw)
  To: harmon; +Cc: ecos-discuss

On Mon, 2004-07-26 at 17:53, harmon wrote:
> When initializing a chip, I need to delay for ~ 1 millisecond.  I can't
> use any blocking calls, so I am now using a simple for loop to eat up
> time.  Is there a portable, accurate way to delay within a DSR or
> initialization code?

#include <cyg/hal/hal_if.h>

CYGACC_CALL_IF_DELAY_US(_n_ms);

-- 
Gary Thomas <gary@mlbassoc.com>
MLB Associates


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

^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: [ECOS] short accurate delay in DSR or startup
       [not found] <001401c473ea$8301c7d0$8601a8c0@k7sem>
@ 2004-07-27 15:52 ` Gary Thomas
  0 siblings, 0 replies; 3+ messages in thread
From: Gary Thomas @ 2004-07-27 15:52 UTC (permalink / raw)
  To: harmon; +Cc: eCos Discussion

Please copy replies to the mailing list so that all may benefit.  
Private email support is available under contract only.

On Tue, 2004-07-27 at 09:00, harmon wrote:
> Thank you for your response to my question.  
> 
> However, when I try to use the CYGACC_CALL_IF_DELAY_US call, my library
> builds, but the application does not link.
> 
> /ecos-c/cygwin/opt/ecos/ecos-2.0/packages/devs/usb/Nc2270/v2_0/src/usbs_
> Nc2270.c
> :3378: undefined reference to `CYGACC_CALL_IF_DELAY_US'
> 
> Is this an option that needs enabled??

You need this line in your code:

  #include <cyg/hal/hal_if.h>

> 
> Larry
> 
> -----Original Message-----
> From: ecos-discuss-owner@ecos.sourceware.org
> [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Gary Thomas
> Sent: Monday, July 26, 2004 8:22 PM
> To: harmon
> Cc: ecos-discuss@sources.redhat.com
> Subject: Re: [ECOS] short accurate delay in DSR or startup
> 
> On Mon, 2004-07-26 at 17:53, harmon wrote:
> > When initializing a chip, I need to delay for ~ 1 millisecond.  I
> can't
> > use any blocking calls, so I am now using a simple for loop to eat up
> > time.  Is there a portable, accurate way to delay within a DSR or
> > initialization code?
> 
> #include <cyg/hal/hal_if.h>
> 
> CYGACC_CALL_IF_DELAY_US(_n_ms);
> 
> -- 
> Gary Thomas <gary@mlbassoc.com>
> MLB Associates
-- 
Gary Thomas <gary@mlbassoc.com>
MLB Associates


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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2004-07-27 15:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-27  4:14 [ECOS] short accurate delay in DSR or startup harmon
2004-07-27  5:35 ` Gary Thomas
     [not found] <001401c473ea$8301c7d0$8601a8c0@k7sem>
2004-07-27 15:52 ` Gary Thomas

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).