The condition variables are used to ensure that the Producer does not produce more data than the Consumer can consume, and that the consumer does not try to consume data from an empty Buffer
C Example
Wait for a particular condition
condFuel is the condition variable
mutexFuel is the Mutex (互斥体) to protect shared data
pthread_cond_wait(&condFuel, &mutexFuel); equivalent to:
Particular Condition fulfilled & execution is passed back
pthread_cond_signal(&condFuel);
The waiting thread mutex lock & continue with the execution