当前位置:网站首页>1287_ Implementation analysis of prvtaskistasksuspended() interface in FreeRTOS
1287_ Implementation analysis of prvtaskistasksuspended() interface in FreeRTOS
2022-07-02 10:45:00 【grey_ csdn】
All learning summary : GreyZhang/g_FreeRTOS: learning notes about FreeRTOS. (github.com)
Take a look this time prvTaskIsTaskSuspended() The interface of , This interface is used to judge a task Whether it is in a suspended state . Usually , The interface implementation of this judgment class is simpler . Similar to the previous implementation of obtaining task priority , So it is with . Because its function is to query rather than modify , Yes OS The overall operating environment does not have much impact .

Many interfaces are being implemented , Task handle if NULL The default is to process the current task . But in this interface, this explanation is meaningless , As long as the task is executing the query action, it means that the current task is not suspended .

This is the main part of the interface implementation , Made a simple note . Query implementation is relatively simple , First, judge whether the task is in the linked list of suspended tasks . If not , There is no need to query directly , Definitely not a suspended task . So is it necessarily a suspended task ? In fact, it is not .
The query implemented by this interface , In fact, it realizes whether the suspended state of task non execution is triggered by the suspended action . If the suspension is caused by blocking , Nor should it return as a pending state . thus , It is not only the attribution state of a linked list element that is judged , We have to see whether the event status is valid , Because the event state represents that the task enters the suspended linked list because it is not executed due to non suspended actions .
With the rules above , The determined result can be returned as the return result .
边栏推荐
- Webui automated learning
- Pywin32 opens the specified window
- 2.hacking-lab脚本关[详细writeup]
- STM32 and motor development (upper system)
- 1287_FreeRTOS中prvTaskIsTaskSuspended()接口实现分析
- lunix重新分配root 和 home 空间内存
- PCL 点云转深度图像
- SPSS做Shapiro-Wilk正态分析
- [unity3d] cannot correctly obtain the attribute value of recttransform, resulting in calculation error
- MongoDB-快速上手MongoDB命令行的一些简单操作
猜你喜欢

1287_FreeRTOS中prvTaskIsTaskSuspended()接口实现分析

Blender camera surround motion, animation rendering, video synthesis

对话吴纲:我为什么笃信“大国品牌”的崛起?

SUS系统可用性量表

【MySQL】连接MySQL时出现异常:Connection must be valid and open
![[Fantasy 4] the transformation from U3D to UE4](/img/bb/665eba3c8cd774c94fe14f169121da.png)
[Fantasy 4] the transformation from U3D to UE4

Allure -- common configuration items

12. Process synchronization and semaphore

Redis set password

SPSS做Shapiro-Wilk正态分析
随机推荐
SQOOP 1.4.6 INSTALL
Transport Optimization abstraction
sqoop的表的导入
【JetBrain Rider】构建项目出现异常:未找到导入的项目“D:\VisualStudio2017\IDE\MSBuild\15.0\Bin\Roslyn\Microsoft.CSh
axis设备的rtsp setup头中的url不能带参
Sum the two numbers to find the target value
13.信号量临界区保护
Mongodb quickly get started with some simple operations of mongodb command line
测试--面试题总结
Pytest learning --base
Shapiro Wilk normal analysis by SPSS
What are the popular frameworks for swoole in 2022?
STM32 and motor development (upper system)
js promise.all
MYSQL环境配置
Flink calculates topn hot list in real time
Internet News: Tencent conference application market was officially launched; Soul went to Hong Kong to submit the listing application
Determine whether there are duplicate elements in the array
pytest学习--base
2021-09-12