At 10:55 PM 3/4/04 +0100, you wrote:
>I belive this is te best way to do it. Using linked list is to
>procesor and memory consumnig. If you use add byte only in interrupt
>rutine and getbyte only in main program it's considered to be "thread
>safe"
It's not thread safe. It'll work in a cooperative tasking environment but
not in a pre-emptive or interrupt environment w/o further protection.
It's also missing overflow protection but that's a different issue.
It's fine as an illustration of the general concept though which is what is
was presented as.
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, IIIMessage
Re: [lpc2000] Circular buffers
2004-03-04 by Robert Adsett
Attachments
- No local attachments were found for this message.