⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pctimer.h

📁 一个C语言写的读入位置跟踪器数据的源程序
💻 H
字号:
/*
    pctimer.h      PC Timer Header File

    Modification History

    9/15/93   jf    created
    10/20/93  jf    added PCTIMER and DOS ifdefs

*/

#ifdef DOS

#ifndef PCTIMER
#define PCTIMER



#define PCTIMER_INTERRUPT IRQ0_VEC   /* IRQ0 on a PCAT/compatible */
#define PCTIMER_CTLREG 0x43     /* Programmable Timer Control Reg */
#define PCTIMER_TIMER0 0x40     /* Programmable Timer 0 Reg */

/*
    Interrupt Controller (8259) Definitions
*/
#define INT_CNTRL_OCW1 0x21       /* operational control addresses */
#define INT_CNTRL_OCW2 0x20
#define INT_CNTRL_OCW3 0x20
#define INT_MSK_REG INT_CNTRL_OCW1  /* mask register address */
#define INT_EOI 0x20               /* end of interrupt command */
#define INT_RD_IRR 0x0a             /* read Interrupt request register */
#define INT_RD_ISR 0x0b             /* read Interrupt service register */

extern unsigned long numirqticks;
extern unsigned char irq0_flg;
extern unsigned char pctimerstored_flg;

#define GETTICKS numirqticks
#define TICK_MSECS 50

/*
    Prototypes
*/
short pctimer_init(short millisecs);
void pctimer_restore(void);

#endif /* PCTIMER */

#endif /* DOS */



⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -