This is the mail archive of the mailing list for the eCos project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Finding Interrupt Vector Number for PIT

>>>>> " " == AbdullahKhateeb Khan <> writes:

 > I am using Intel P-4 Desktop computer as a target. My host
 > platform is an i386-pc (window based)

 > #define PC_PIT_CONTROL  (0x43)
 > #define PC_PIT_CLOCK_0	(0x40)
 > #define PC_PIT_CLOCK_1	(0x41)
 > #define PC_PIT_CLOCK_2	(0x42)

 > The above mentioned piece of code is taken from "var_intr.h". It
 > shows that Programmable Interval Timer (PIT) includes three
 > seperate timers. The addresses 0x40, 0x41, 0x42, 0x43 are the I/O
 > addresses used to program these timers. I know how to program these
 > Timers in different modes.

 > To program any of these timers to generate interrupt and to map an
 > ISR at its interrupt i need to know the interrupt vector number
 > where i have to store the address of ISR.

 > How can i find the interrupt vector number of PC_PIT_CLOCK_0?

CYGNUM_HAL_INTERRUPT_TIMER. The interrupt vectors are always #define'd
directly or indirectly in <cyg/hal/hal_intr.h>. For a PC target
hal_intr.h #include's var_intr.h #include's plf_intr.h #include's
pcmb_intr.h, which defines all the interrupt vectors for a standard PC

Note that on a standard PC only the first timer is hooked up to the
interrupt controller. The other two timers cannot generate interrupts.
For more information on PC hardware you can consult a standard
reference such as Messmer's "The Indispensable PC Hardware Book".
That first timer is normally used for the eCos system clock so is not
available to application code.


Bart Veer                       eCos Configuration Architect     The eCos and RedBoot experts

Before posting, please read the FAQ:
and search the list archive:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]