<< Previous | Next >>

SetVectExtern2000

unsigned SetVectExtern2000( int priority, void * isr );

Description

Sets up the external interrupt table vectors for external interrupts 0 and 1. This function should be used for Rabbit 2000 processors revision IQ2 due to a bug in the chip's interrupt handling. (See Technical Note 301, "Rabbit 2000 Microprocessor Interrupt Issue," on the Rabbit Semiconductor website for more information.)

Once this function is called, both external interrupts 0 and 1 should be enabled with priority levels set higher than any currently running interrupts. (All system interrupts in the BIOS run at interrupt priority 1.) The interrupt priority is set via the control register I0CR for external interrupt 0 and I1CR for external interrupt 1.

The actual priority used by the interrupt service routine (ISR) is passed to this function.

Parameters

priority
Priority the ISR should run at. Valid values are 1, 2 or 3.

isr
ISR handler address. Must be a root address.

Return value

Address of vector table entry, or zero if priority is not valid.

Library

SYS.LIB

See also

GetVectExtern2000, SetVectIntern, GetVectIntern


Dynamic C Functions << Previous | Next >> rabbit.com