How to enable PIC-2

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
pepito

How to enable PIC-2

Post by pepito »

I can't activate the CMOS Real Time Clock periodic interrupt. I read some tutorials and I belive I am follow the necessary steps to do it, then I suspect I have some error enabling the PIC-2 (IRQ8-IRQ15).

What is necessary to enable PIC-2?

Thank you,
pepito
CodeSlasher

RE:How to enable PIC-2

Post by CodeSlasher »

in order to receive interrupts from the slave pic, you need to enable IRQ line 2 which the slave pic is cascaded on. Also in your initialization code for the master pic, make sure you tell it to cascase the slave on irq line 2.
Hope this helps
pepito

RE:How to enable PIC-2

Post by pepito »

Thank you!

How may I tell the PIC-1 to cascase the slave on irq line 2?

pepito
CodeSlasher

RE:How to enable PIC-2

Post by CodeSlasher »

By default its supposed to be cascaded on irq line 2. but its better to be safe and add it in the setup sequence sent to the master pic. Its one of the control words written to the master pic (i.e a set bit in one of them) can't remember but any doc explaining the pic and its setup should have the info.
pepito

RE:How to enable PIC-2

Post by pepito »

Thank you very much for your response!  I will see the PIC documents...

pepito
Post Reply