资源简介
基于STM8的微小操作系统,属于STM8的定制款,开源代码,商业应用均免费,专门为STM8设计的微小型嵌入式系统,移植方便,操作简单,包含源码
代码片段和文件信息
/*
* Copyright (c) 2010 Kelvin Lawson. All rights reserved.
*
* Redistribution and use in source and binary forms with or without
* modification are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. No personal names or organizations‘ names associated with the
* Atomthreads project may be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE ATOMTHREADS PROJECT AND CONTRIBUTORS
* “AS IS“ AND ANY EXPRESS OR IMPLIED WARRANTIES INCLUDING BUT NOT LIMITED
* TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT INDIRECT INCIDENTAL SPECIAL EXEMPLARY OR
* CONSEQUENTIAL DAMAGES (INCLUDING BUT NOT LIMITED TO PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE DATA OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY WHETHER IN
* CONTRACT STRICT LIABILITY OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
/**
* \file
* Kernel library.
*
*
* This module implements the core kernel functionality of managing threads
* context-switching and interrupt handlers. It also contains functions for
* managing queues of TCBs (task control blocks) which are used not only for
* the queue of ready threads but also by other OS primitives (such as
* semaphores) for generically managing lists of TCBs.
*
* Core kernel functionality such as managing the queue of ready threads and
* how context-switch decisions are made is described within the code. However
* a quick summary is as follows:
*
* There is a ready queue of threads. There must always be at least one thread
* ready-to-run. If no application threads are ready the internal kernel idle
* thread will be run. This ensures that there is a thread to run at all
* times.
*
* Application code creates threads using atomThreadCreate(). These threads
* are added to the ready queue and eventually run when it is their turn
* (based on priority). When threads are currently-running they are taken off
* the ready queue. Threads continue to run until:
* \li They schedule themselves out by calling an OS primitive which blocks
* such as a timer delay or blocking on a semaphore. At this point they
* are placed on the queue of the OS primitive in which they are blocking
* (for example a timer delay or semaphore).
* \li They are preempted
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-08-27 10:12 atomthreads-master\
文件 126 2017-08-27 10:12 atomthreads-master\.gitmodules
文件 383 2017-08-27 10:12 atomthreads-master\.travis.yml
文件 1874 2017-08-27 10:12 atomthreads-master\README.md
目录 0 2017-08-27 10:12 atomthreads-master\kernel\
文件 47659 2017-08-27 10:12 atomthreads-master\kernel\Doxyfile
文件 1116 2017-08-27 10:12 atomthreads-master\kernel\README
文件 5005 2017-08-27 10:12 atomthreads-master\kernel\atom.h
文件 36597 2017-08-27 10:12 atomthreads-master\kernel\atomkernel.c
文件 25561 2017-08-27 10:12 atomthreads-master\kernel\atommutex.c
文件 2194 2017-08-27 10:12 atomthreads-master\kernel\atommutex.h
文件 2985 2017-08-27 10:12 atomthreads-master\kernel\atomport-template.h
文件 34316 2017-08-27 10:12 atomthreads-master\kernel\atomqueue.c
文件 2637 2017-08-27 10:12 atomthreads-master\kernel\atomqueue.h
文件 22987 2017-08-27 10:12 atomthreads-master\kernel\atomsem.c
文件 2163 2017-08-27 10:12 atomthreads-master\kernel\atomsem.h
文件 15969 2017-08-27 10:12 atomthreads-master\kernel\atomtimer.c
文件 2482 2017-08-27 10:12 atomthreads-master\kernel\atomtimer.h
目录 0 2017-08-27 10:12 atomthreads-master\ports\
目录 0 2017-08-27 10:12 atomthreads-master\ports\arm\
文件 47646 2017-08-27 10:12 atomthreads-master\ports\arm\Doxyfile
文件 5836 2017-08-27 10:12 atomthreads-master\ports\arm\README
文件 8275 2017-08-27 10:12 atomthreads-master\ports\arm\atomport-asm.s
文件 1856 2017-08-27 10:12 atomthreads-master\ports\arm\atomport-private.h
文件 2372 2017-08-27 10:12 atomthreads-master\ports\arm\atomport-tests.h
文件 6609 2017-08-27 10:12 atomthreads-master\ports\arm\atomport.c
文件 3770 2017-08-27 10:12 atomthreads-master\ports\arm\atomport.h
目录 0 2017-08-27 10:12 atomthreads-master\ports\arm\platforms\
目录 0 2017-08-27 10:12 atomthreads-master\ports\arm\platforms\dm36x\
文件 47646 2017-08-27 10:12 atomthreads-master\ports\arm\platforms\dm36x\Doxyfile
文件 5011 2017-08-27 10:12 atomthreads-master\ports\arm\platforms\dm36x\Makefile
............此处省略229个文件信息
- 上一篇:Erlang 微分进化算法
- 下一篇:QQ蠕虫病毒代码
评论
共有 条评论