|
|
| version 1.4, 2003/12/08 00:55:32 | version 1.7, 2007/11/03 00:00:20 |
|---|---|
| Line 1 | Line 1 |
| typedef struct { | typedef struct { |
| int levels; | |
| UINT8 level[8]; | |
| int levelsbak; | |
| UINT8 levelbak[8]; | |
| UINT8 pry[8]; | |
| UINT8 icw[4]; | UINT8 icw[4]; |
| UINT8 imr; // ocw1 | UINT8 imr; // ocw1 |
| UINT8 ocw3; | UINT8 isr; |
| UINT8 irr; | UINT8 irr; |
| UINT8 ext; | UINT8 ocw3; |
| UINT8 isr; | UINT8 pry; |
| UINT8 isrbak; | |
| UINT8 writeicw; | UINT8 writeicw; |
| UINT8 padding; | UINT8 padding[2]; |
| } _PICITEM, *PICITEM; | } _PICITEM, *PICITEM; |
| typedef struct { | typedef struct { |
| _PICITEM pi[2]; | _PICITEM pi[2]; |
| BYTE ext_irq; | |
| } _PIC, *PIC; | } _PIC, *PIC; |
| enum { | enum { |
| Line 54 enum { | Line 45 enum { |
| IRQ_INT6 = 0x0d | IRQ_INT6 = 0x0d |
| }; | }; |
| #define PICEXISTINTR ((!pic.ext_irq) && \ | #define PICEXISTINTR ((pic.pi[0].irr & (~pic.pi[0].imr)) || \ |
| ((pic.pi[0].irr & (~pic.pi[0].imr)) || \ | (pic.pi[1].irr & (~pic.pi[1].imr))) |
| (pic.pi[1].irr & (~pic.pi[1].imr)))) | |
| #ifdef __cplusplus | #ifdef __cplusplus |
| extern "C" { | extern "C" { |
| #endif | #endif |
| void extirq_push(void); | |
| void extirq_pop(void); | |
| void pic_irq(void); | void pic_irq(void); |
| void pic_setirq(REG8 irq); | void pic_setirq(REG8 irq); |
| void pic_resetirq(REG8 irq); | void pic_resetirq(REG8 irq); |
| void pic_registext(REG8 irq); | |
| void picmask(NEVENTITEM item); | void picmask(NEVENTITEM item); |
| void pic_reset(void); | void pic_reset(const NP2CFG *pConfig); |
| void pic_bind(void); | void pic_bind(void); |
| #ifdef __cplusplus | #ifdef __cplusplus |