www.pudn.com > Tornado_Train_Workshop_demo_program.rar > hello.c


/* hello.c -- hello "world" function */ 
 
#include "vxWorks.h" 
#include "stdio.h" 
#include "semLib.h" 
#include "taskLib.h" 
 
SEM_ID semM; 
 
 
int hello(void) 
{ 
	printf("hello world!\n"); 
	return OK; 
} 
 
void test(void) 
{ 
	semM = semMCreate(0); 
	 
} 
 
int test1(void) 
{ 
	semTake(semM,-1); 
	printf(" take a semM \n"); 
	semGive(semM); 
	return OK; 
}