January 21st, 2010, 03:59 PM
1) I'm not asking how to block if the buffer is full. I'm saying that I can think of two ways to communicate with the producer thread. a) If Producer_fn returns buffer-full, then the producer thread...
January 21st, 2010, 10:51 AM
Thanks for all the input. I've already stated that I was in favor of using events instead of polling, no argument there. But please consider the following code:
CONSUMER_FN()
{
Loop...
January 20th, 2010, 09:11 PM
*sigh* I wish people showed this much interest to my intellisense thread ;)
I'm not trying to prevent the same thread entering the critical section recursively. I know it was designed that way....
January 20th, 2010, 08:34 PM
Thanks Codeplug, I guess you want to tell me that I should look closer or deeper inside my code to get to the bottom of this, and you are probably right. Maybe I'm not polling frequent enough to see...
January 20th, 2010, 07:44 PM
Thanks Arjay, your idea might have worked but rereading my own post I've seen that I might have mislead you, or any other members who have read my post. My apologies.
The function I export is not...
January 20th, 2010, 04:47 PM
Hi all
For practical purposes I can say that my program has a producer thread and a consumer thread. The producer thread writes data to a circular buffer, and the consumer thread reads data from...