2 #include "nvitem_os.h"
\r
7 pthread_mutex_t mutex;
\r
8 pthread_cond_t notify;
\r
10 static THREAD_COMMUNICAT communicate;
\r
12 void initEvent(void)
\r
14 pthread_mutex_init(&communicate.mutex, 0);
\r
15 pthread_cond_init(&communicate.notify, 0);
\r
18 void waiteEvent(void)
\r
20 pthread_cond_wait(&communicate.notify, 0);
\r
23 void giveEvent(void)
\r
25 pthread_cond_signal(&communicate.notify);
\r
30 pthread_mutex_lock(&communicate.mutex);
\r
35 pthread_mutex_unlock(&communicate.mutex);
\r
40 void initEvent(void){}
\r
42 void waiteEvent(void){}
\r
44 void giveEvent(void){}
\r
46 void getMutex(void){}
\r
48 void putMutex(void){}
\r