This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Semaphore


Hi!

Code:
extern cyg_sem_t g_semInit;

In cyg_user_start(),
{
thread_init();
cyg_scheduler_start();
cyg_semaphore_wait(&g_semInit);
printf("wake up\n");
}

In about function, I called the thread_init to create a thread, init
semaphore and resume it, this thread will call some functions and then call
cyg_semaphore_post(&g_semInit). I found that the printf did not print the
wake up message. 
Is there something wrong?

Thanks!

----------------------------------------------------
Chris

_________________________________________________________________________
Sure, you can have free email. But free Email, Voicemail and Faxmail?
Check it out at http://www.2bzd.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]