?? os_cpu.h
字號:
#ifndef __OS_CPU_H__
#define __OS_CPU_H__
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <stdlib.h>
#include <conio.h>
#include <windows.h>
#include <mmsystem.h> //包含時(shí)鐘函數(shù)的頭文件,需要windows.h的支持
#define OS_EXT
#define DEBUG printf
typedef unsigned char BOOLEAN;
typedef unsigned char INT8U; /* Unsigned 8 bit quantity */
typedef signed char INT8S; /* Signed 8 bit quantity */
typedef unsigned int INT16U; /* Unsigned 16 bit quantity */
typedef signed int INT16S; /* Signed 16 bit quantity */
typedef unsigned long INT32U; /* Unsigned 32 bit quantity */
typedef signed long INT32S; /* Signed 32 bit quantity */
typedef float FP32; /* Single precision floating point */
typedef double FP64; /* Double precision floating point */
typedef unsigned int OS_STK; /* Each stack entry is 32-bit wide */ //change by wenjia
typedef unsigned int OS_CPU_SR; /* Define size of CPU status register (PSW = 32 bits) */ //change by wenjia
#define BYTE INT8S /* Define data types for backward compatibility ... */
#define UBYTE INT8U /* ... to uC/OS V1.xx. Not actually needed for ... */
#define WORD INT16S /* ... uC/OS-II. */
#define UWORD INT16U
#define LONG INT32S
#define ULONG INT32U
extern BOOLEAN FlagEn; //中斷是否關(guān)閉
#define OS_STK_GROWTH 1
#define OS_TASK_SW() OSCtxSw() //保護(hù)模式下不能中斷
#define OS_ENTER_CRITICAL() FlagEn=0 /* 禁止定時(shí)器 調(diào)度 */
#define OS_EXIT_CRITICAL() FlagEn=1 //容許定時(shí)器調(diào)度 /* Enable interrupts */
void CALLBACK OSTickISR(unsigned int a,unsigned int b,unsigned long c,unsigned long d,unsigned long e);
#define OS_TASK_TMR_PRIO 8
#endif
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -