mirror of
https://github.com/jie65535/stm32f10x-uC-OS-II.git
synced 2024-07-27 19:10:55 +08:00
upload template
This commit is contained in:
22
uCOS-II Template/Project/main.c
Normal file
22
uCOS-II Template/Project/main.c
Normal file
@@ -0,0 +1,22 @@
|
||||
#include "includes.h"
|
||||
#include "task.h"
|
||||
#include "SerialPort.h"
|
||||
|
||||
// <20><><EFBFBD>ӳ<EFBFBD>ʼ<EFBFBD><CABC>
|
||||
void BSP_Initializes(void)
|
||||
{
|
||||
// <20><>9600<30><30><EFBFBD><EFBFBD><EFBFBD>ʳ<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
SerialPortInit(9600);
|
||||
}
|
||||
|
||||
int main(void)
|
||||
{
|
||||
// uC/OS-II <20><>ʼ<EFBFBD><CABC>
|
||||
OSInit();
|
||||
// <20><>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
BSP_Initializes();
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
OSTaskCreate(TaskStart, (void *)0, &TASK_START_STK[TASK_START_STK_SIZE - 1], TASK_START_PRIO);
|
||||
// uC/OS-II <20><><EFBFBD><EFBFBD>
|
||||
OSStart();
|
||||
}
|
||||
Reference in New Issue
Block a user