Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

Re: Teenagers should write code.

2004-09-07 by Graham Davies

--- In AVR-Chat@yahoogroups.com, Dave VanHorn <dvanhorn@d...> wrote:

> ... so there is then a list of tasks
> that are ready to be executed, which
> you drop through. Eventually, you hit
> the end, and start over, or just sit
> in a loop waiting for more tasks to do?

In ECROS, multiple lists (queues), one for each priority. You 
never "hit the end" because the idle task is always ready on the 
lowest priority queue.

> How exactly do you "send" an event to a task?

There is an ECROS function to do this.

> In terms I'm familiar with (I'm an
> assembler kind of guy), I might be
> sending data to a UART ...

In ECROS, you use a printf-like function specifying the UART stream 
as the destination. This returns "immediately", having stored the 
output text in a buffer. Interrupts move the text out of the buffer 
to the UART while you go about something else. The idea is that you 
don't have to worry about all the stuff you list.

If the point of your message is to take issue with my claim that it 
is not necessary to poll, then I give up. You win. It is possible to 
define polling such that polling is necessary. I don't care how; 
picking at terminology is not interesting to me.

Graham.

Attachments

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.