sir, i would like to know what are the functions of different "Interrupt Vectors"? say for example: void External0 () interrupt 0; void External1 () interrupt 2; void ADCR () interrupt 6;
- as u can see , diffferent interrupts has been called for different functions . so my question is what are the applications of these various interrupts and their functionality? .....please reply with reference to ADuC845(8051 core), using c51 compiler. .....if possible please post the detail functions of all the 0-31 interrupts of c51 compiler.....
Are you _really_ saying that you did not look at this thread: http://www.keil.com/forum/docs/thread16047.asp before posting?
The link had to have been in the top-three on the first page, when you wrote your post.
By the way - what do you think about the text found in the manual? Was there no notion about the interrupt numbers there either?
Another thing - isn't it better if we just post the complete source code to your program, instead of focusing on documenting the ADuC845 processor?
They are clearly stated in the Manual:
http://www.keil.com/support/man/docs/c51/c51_le_interruptfuncs.htm
The interrupt number tells the compiler which vector location to use; your specific chip documentation will tell you what functions it attaches to each vector.
sir, thank you for your reply..... still there is one more doubt in my mind... i.e. the instruction interrupt 2 does refer to the particular interrupt vector and the no.2 refers to the interrupt priority , where the function I have written with respect to this interrupt and the register values we have loaded w.r.t. our needs is stored at a register bank.... and when we access access this interrupt we actually load the register values already stored in corresponding register bank....? plz explain....
"the instruction interrupt 2 does refer to the particular interrupt vector and the no.2 refers to the interrupt priority"
NO!!!!!!!!!!!
Where on the manual page did you see anything about priority?!
The interrupt number in this context relates purely to which vector is being used.
For register bank usage, see the using keyword...
I think you probably need to go back to the basics of the 8051 architecture:
Links to the so-called "bible" for the 8051 here: www.8052.com/.../120112
Tutorials here: http://www.8052.com/tutorial Book list here: http://www.keil.com/books/8051books.asp
John gave an excellent reason for why Keil picked up the interrupt number idea, so no blame to Keil here.
But is it not interesting how many misunderstandings could have been avoided over the years if
void ISREI0 interrupt 0 would have been void ISREI0 vector 003h
Erik
Yes - the "interrupt number" does seem a rather unnecessary level of indirection!
In fact, I think that Tasking does have the option of specifying either an interrupt number, or the absolute vector address.