📄 datatypes_v1.1.h
字号:
/*=============================================================================
// File : Datatypes_V1.1.h //
// //
// Abstract: This header file containing the required basic datatypes and //
// user defined macros. //
// Compiler : IAR Embedded Work Bench //
// //
// Author : Kuberappa.M.Sajjan //
// E-mail : kuber@unifiest.com //
// //
// //
=============================================================================*/
/*---------------------------- Preprocessor Directives ----------------------*/
#include "intrinsics.h"
/*--------------------------- Macros and Constants --------------------------*/
#ifndef _DATATYPES_H_ // If Datatypes header file is not defined then
#define _DATATYPES_H_ // Define the Datatypes header file
#define EI __enable_interrupt();
#define DI __disable_interrupt();
#define NOP __no_operation();
#define ZERO 0
#define UCHAR unsigned char // It defines the unsigned char
#define UINT unsigned int // It defines the unsigned integr
#define ULONG unsigned long // It defines the unsigned long
#define CHAR signed char // It defines the signed char
#define INT signed int // It defines the signed integer
#define LONG signed long // It defines the signed long
#define FLOAT float // It defines the float var
#define SET 1 // It defines the SET as 1
#define CLR 0 // It defines the CLR as 0
//#define OUT_PORT 0xFF // To configure the port as output port
//#define IN_PORT 0x00 // To configure the port as input port
#define ASCII 0x30
#define RESOLUTION 0.45
/*--------------------------- The delay routine for 8-bit -------------------*/
#define DELAY_8 {UCHAR del;for(del = 0;del<255;del++);}
/*--------------------------- The delay routine for 16-bit ------------------*/
#define DELAY_16 {UINT del;for(del = 0;del<0xFFFF;del++);}
/*--------------------------- Global variable Declarations ------------------*/
/*--------------------------- Function Prototypes ---------------------------*/
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -