This commit is contained in:
刘可亮
2024-09-03 11:16:08 +08:00
parent cf270df8d6
commit 803cac77d5
2931 changed files with 614364 additions and 31222 deletions

View File

@@ -0,0 +1,23 @@
## **rtthread** 系统相关函数
**rtthread** 模块提供了与 RT-Thread 操作系统相关的功能,如查看栈使用情况等。
### 函数
#### rtthread.current_tid()
返回当前线程的 id 。
#### rtthread.is_preempt_thread()
返回是否是可抢占线程。
### 示例
```
>>> import rtthread
>>>
>>> rtthread.is_preempt_thread() # determine if it's a preemptible thread
True
>>> rtthread.current_tid() # current thread id
268464956
>>>
```