微波EDA网,见证研发工程师的成长!
首页 > 硬件设计 > 嵌入式设计 > 单片机——压力传感器LCD

单片机——压力传感器LCD

时间:11-18 来源:互联网 点击:

#define CWORD ((unsigned int volatile code *) 0)
#define DWORD ((unsigned int volatile data *) 0)
#define PWORD ((unsigned int volatile pdata *) 0)
#define XWORD ((unsigned int volatile xdata *) 0)

#ifdef __CX51__
#define FVAR(object, addr) (*((object volatile far *) (addr)))
#define FARRAY(object, base) ((object volatile far *) (base))
#define FCVAR(object, addr) (*((object const far *) (addr)))
#define FCARRAY(object, base) ((object const far *) (base))
#else
#define FVAR(object, addr) (*((object volatile far *) ((addr)+0x10000L)))
#define FCVAR(object, addr) (*((object const far *) ((addr)+0x810000L)))
#define FARRAY(object, base) ((object volatile far *) ((base)+0x10000L))
#define FCARRAY(object, base) ((object const far *) ((base)+0x810000L))
#endif

#endif

MATH.h子程序

#ifndef __MATH_H__
#define __MATH_H__

#pragma SAVE
#pragma REGPARMS
extern char cabs (char val);
extern int abs (int val);
extern long labs (long val);
extern float fabs (float val);
extern float sqrt (float val);
extern float exp (float val);
extern float log (float val);
extern float log10 (float val);
extern float sin (float val);
extern float cos (float val);
extern float tan (float val);
extern float asin (float val);
extern float acos (float val);
extern float atan (float val);
extern float sinh (float val);
extern float cosh (float val);
extern float tanh (float val);
extern float atan2 (float y, float x);

extern float ceil (float val);
extern float floor (float val);
extern float modf (float val, float *n);
extern float fmod (float x, float y);
extern float pow (float x, float y);

#pragma RESTORE

#endif

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top