当前位置:网站首页>UCOSII (learning notes)
UCOSII (learning notes)
2022-06-23 09:12:00 【July meteor】
ucosii Embedded system
characteristic : Suitable for small control systems , High efficiency of execution , Small footprint , Excellent real-time performance and strong scalability .
1. Declaration of the task stack :
ucos-ii Create a separate task stack for each task , And the task stack needs to be declared by the user , The data type is OS_STK, Stack structure is generally implemented by array .
#define TASK_STK_SIZE 512
OS_STK TaskStk[N_TASKS][TASK_STK_SIZE]; // Stack Size
2. Declaration of random semaphores :
Before building a semaphore , You need to declare a OS_EVENT* Type pointer , Used to store only event control blocks ECB The address of .
OS_EVENT *RandomSem;
3. Task and function prototype declaration :
Declare the task function , It doesn't mean that a task is a function , Just borrow the form of function .
(1) Mission statement :
void Task(void *data); // Create task array
void TaskStart(void *data); // Task start
(2) Function declaration :
static void TaskStartCreateTasks(void); // Set up tasks
static void TaskStartDispInit(void); // Task initialization
4.main function
complete ucos-ii System initialization ,DOS Environmental preservation , Interrupt vector setting , Appoint ucos-ii Task switching processing function in , Resume of first task and start multi task system .
边栏推荐
- An idea of using keep alive to cache data in vue3 form pages
- 4、 Database design
- [qnx hypervisor 2.2 user manual]6.2 network
- MySQL fault case | mysqldump: couldn't execute 'select column_ NAME
- Leetcode topic analysis contains duplicate III
- 进入小公司的初级程序员要如何自我提高?
- Redis学习笔记—数据类型:集合(set)
- Learn SCI thesis drawing skills (E)
- Redis learning notes - single key management
- Combination sum III of leetcode topic analysis
猜你喜欢
随机推荐
Redis learning notes - Database Management
Redis学习笔记—持久化机制之RDB
通用分页(1)
ucosii(学习笔记)
36氪首发|云原生数据库公司「拓数派」完成新一轮战略融资,估值已达准独角兽级别
Redis学习笔记—数据类型:字符串(string)
General paging (1)
How to use matrix analysis to build your thinking scaffold in flowus, notation and other note taking software
cooding代码库的使用笔记
Redis learning notes - data type: ordered set (Zset)
Basic use of lua
使用base64,展示图片
Redis学习笔记—Redis与Lua
Redis学习笔记—慢查询分析
MySQL fault case | error 1071 (42000): specified key was too long
4、 Database design
swagger UI :%E2%80%8B
Redis learning notes - data type: hash
ionic5錶單輸入框和單選按鈕
Redis学习笔记—遍历键







