📄 os.h
字号:
/************************************************
*
* $Copyright 2001 Joseph J. Lemieux ALL RIGHTS RESERVED. $
*
* $Filename: C:\OSEKBook\src\CH05\inc\OS.H $
*
* Description: OS Include file that encapsulates
* the OS specific header files.
*
************************************************/
#ifndef OSH
#define OSH
/***********************************************
*
* OSEKWorks specific header files.
*
* osekworks.h - OS specific definitions.
* osekworkscom.h - COM specific definitions.
* osekworksnm.h - NM specific definitions.
* oil.h - Application specific definitions generated
* from the OIL file.
*
***********************************************/
#include "osekworks.h"
#include "oil.h"
//#include "init.h"
/*********************
*
* Application Mode conversion Definition Macros
* Used in os.cfg to define conversions. See
* .cfg file for usage description.
*
*********************/
typedef enum ConvertAppModeTypetag {
APP_MODE_MASK,
APP_MODE_VALUE
}ConvertAppModeType;
/*********************
*
* Application Mode conversion Table
*
*********************/
typedef struct ConvertAppModeListTypetag {
AppModeType mode;
UINT8 value;
}ConvertAppModeListType;
/*********************
*
* Define Configuration Macros
*
* This section defines the configuration macros
* and includes the configuration file to configure
* the application mode conversion list.
*
*********************/
#define START_APPMODE_CONVERT_LIST(name,size) \
enum ConvertAppModeValueEnum {
#define ADD_APPMODE_CONVERT_LIST(appmode) \
appmode##_VALUE,
#define END_APPMODE_CONVERT_LIST \
INVALID_APPMODE_VALUE};
#include "os.cfg"
#undef START_APPMODE_CONVERT_LIST
#undef ADD_APPMODE_CONVERT_LIST
#undef END_APPMODE_CONVERT_LIST
#undef OSCFG
#define START_APPMODE_CONVERT_LIST(name,size) \
enum ConvertAppModeMaskEnum {
#define ADD_APPMODE_CONVERT_LIST(appmode) \
appmode##_MASK = 1 << appmode##_VALUE,
#define END_APPMODE_CONVERT_LIST \
INVALID_APPMODE_MASK = 0xFFFFFFFF};
#include "os.cfg"
#undef START_APPMODE_CONVERT_LIST
#undef ADD_APPMODE_CONVERT_LIST
#undef END_APPMODE_CONVERT_LIST
#undef OSCFG
#ifdef OSC
#define START_APPMODE_CONVERT_LIST(name,size) \
ConvertAppModeListType const name[size+1] = {
#define ADD_APPMODE_CONVERT_LIST(appmode) \
{(AppModeType)appmode,appmode##_VALUE},
#define END_APPMODE_CONVERT_LIST \
(AppModeType)0,0xFF};
#else
#define START_APPMODE_CONVERT_LIST(name,size) \
extern ConvertAppModeListType const name[size+1];
#define ADD_APPMODE_CONVERT_LIST(appmode)
#define END_APPMODE_CONVERT_LIST
#endif /* OSC */
#include "os.cfg"
#endif /* OSH */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -