Intel 386 User Manual

Page 239

Advertising
background image

Intel386™ EX EMBEDDED MICROPROCESSOR USER’S MANUAL

9-40

return E_OK;

}/* SetIRQVector */

/*****************************************************************************

SetInterruptVector:

Description:

Loads the interrupt vector table with the address of the interrupt

routine. The vector table entry number is determined by the vector

number.

Parameters:

InterProc

Address of interrupt function, will be loaded into

the interrupt table.

ISR_Type

Specifies if the interrupt function. Real Mode only

supports INTERRUPT_ISR (the parameter is ignored). The

parameter is kept to maintain compatibility with the

protected mode version of this function.

Returns:

None

Assumptions:

Compiler supports far and interrupt keywords

Compiler may issue a warning about IntrType not used.

IntrType is kept for protected mode compatibility.

Syntax:

SetInterruptVector(wdtISR, INTERRUPT_ISR);

Real/Protected Mode

Real Mode only

*****************************************************************************/

void SetInterruptVector( void (far interrupt *IntrProc)(void),

int Vector, int IntrType)

{

(void) IntrType;

// Reference to avoid compiler warning

((unsigned long far *)(0))[Vector] = (unsigned long)IntrProc;

}/* SetInterruptVector */

/*****************************************************************************

Advertising