Mon Apr 4 14:11:08 EDT 2011

Producer/consumer in C in an embedded context

Main problem in embedded is to limit RAM memory usage.  This makes
algorithms that use intermediate data structures prohibitive.

Usually there is plenty of ROM in comparison to RAM, so it is usually
possible to use use manual "deforestation".

What this means is to turn code into producers/consumers (threads and
streams).  In languages that support partial contiuations this is
straightforward.  How to do it in C?