Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Thread

Newbee needs timing examples

Newbee needs timing examples

2006-01-15 by teddyroskvist

Hello World.

I have just startet with the arm lpc2119, and now i need some examples 
on how i control time on the arm.

I would like to see use of the realtime clock, and the internal timers.

The only function the examples need to have i that it sets an io pin 
high when the time occures.

I also need to know how i can make a delay of x ns/ms, or how to 
calculate the number of loops to required give a certain delay.

I will be happy with any hints, or ideas.

Regards
Teddy

Re: [lpc2000] Newbee needs timing examples

2006-01-15 by Robert Adsett

At 03:57 PM 1/15/06 +0000, teddyroskvist wrote:
>I would like to see use of the realtime clock, and the internal timers.
>
>The only function the examples need to have i that it sets an io pin
>high when the time occures.
>
>I also need to know how i can make a delay of x ns/ms, or how to
>calculate the number of loops to required give a certain delay.

See http://www.aeolusdevelopment.com/Articles/download.html Look at the 
newlib-lpc source for an example of using the timer for generating 
micro-second delays.  There is also an application note 
http://www.aeolusdevelopment.com/AppNotes/LPC210X/an-timerperformance.pdf 
that describes the performance of the timer and one 
http://www.aeolusdevelopment.com/AppNotes/LPC210X/ConfiguringTimer.html 
describing how to adapt it for different clock rates.

The code was developed for the 2104/5/6 members of the family but should 
work for other members since most (all?) share the same timer peripherals.

Robert

" 'Freedom' has no meaning of itself.  There are always restrictions,   be 
they legal, genetic, or physical.  If you don't believe me, try to chew a 
radio signal. "  -- Kelvin Throop, III
http://www.aeolusdevelopment.com/

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.