/* Create a thread and add it to Active Threads and set it to state READY.  */
osThreadId osThreadCreate(osThreadDef_t *thread_def, void *argument)
/* Create a thread and add it to Active Threads and set it to state READY.  */
osThreadId osThreadCreate(osThreadDef_t *thread_def, void *argument)
{
	osThreadId thread;
	thread = rt_thread_create(thread_def->name, thread_def->entry, argument, thread_def->stack_size, thread_def->priority, thread_def->tick);	if (thread != RT_NULL)
        rt_thread_startup(thread); 
	return thread;
}