48 lines
953 B
C
48 lines
953 B
C
/* MCU INCLUDE */
|
||
#include "stm32f10x.h"
|
||
/* BSP INCLUDE */
|
||
#include "Bsp.h"
|
||
/* OPEN_SOURCE_LIB INCLUDE */
|
||
#include "LetterShell.h"
|
||
/* APP INLCUDE */
|
||
#include "LedTest.h"
|
||
|
||
/**
|
||
* @brief ThreadX操作系统入口函数
|
||
* @param FirstUnusedMemory OS相关
|
||
* @retval void
|
||
* @note 此函数应该将所有OS相关的初始化放到这里
|
||
* @example void
|
||
*/
|
||
void ThreadXTaskInit(void* FirstUnusedMemory)
|
||
{
|
||
/* 优先级31,抢占10 */
|
||
LedCtlTaskInit(31,10);
|
||
}
|
||
|
||
/**
|
||
* @brief C程序主函数
|
||
* @param void
|
||
* @retval void
|
||
* @note void
|
||
* @example void
|
||
*/
|
||
int main(void)
|
||
{
|
||
//bsp初始化
|
||
BspConfigInit();
|
||
|
||
//LetterShell初始化
|
||
LetterShellInit(TTY_COM,115200);
|
||
|
||
/* Start ThreadX */
|
||
tx_kernel_enter();
|
||
|
||
while (true)
|
||
{
|
||
//程序运行到这里说明OS调度运行失败
|
||
printf("OS Start Error !\n");
|
||
DelayMs(1000);
|
||
}
|
||
}
|