⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 inittask_main.c

📁 uT Kernel os source code for AT91
💻 C
字号:
/* *---------------------------------------------------------------------- *    micro T-Kernel * *    Copyright (C) 2006-2007 by Ken Sakamura. All rights reserved. *    micro T-Kernel is distributed under the micro T-License. *---------------------------------------------------------------------- * *    Version:   1.00.00 *    Released by T-Engine Forum(http://www.t-engine.org) at 2007/03/26. * *---------------------------------------------------------------------- *//* *	inittask_main.c (sysmain) *	Initial Task */#include "sysmain.h"#include "kernel.h"#include <sys/debug.h>typedef INT	(*MAIN_FP)(INT, UB **);#if USE_KERNEL_MESSAGELOCAL const char knl_boot_message[] = {	/* Boot message */	BOOT_MESSAGE};#endif/* ------------------------------------------------------------------------ *//* * Initial task Main *	The available stack size is slightly less than 8KB. *	The initial task is the system task, *	so it should not be deleted. */EXPORT INT knl_init_task_main( void ){	INT	fin;	/* Start message */#if USE_KERNEL_MESSAGE	tm_putstring((UB*)knl_boot_message);#endif	fin = 1;#if RI_USERINIT != NULL	/* Perform user defined initialization sequence */	fin = (*(MAIN_FP)RI_USERINIT)(0, NULL);#endif	if ( fin > 0 ) {		/* Perform user main */		fin = usermain();	}#if RI_USERINIT != NULL	/* Perform user defined finalization sequence */	(*(MAIN_FP)RI_USERINIT)(-1, NULL);#endif	return fin;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -