Hello, I need to know the exact moment when an input is set. I'm using XC167CI and I have fast interrupts. This way is full, I mean I have used all fast interrupts. I don't know how I can know when an input por is set and reset. What can I do? I which file can I paste the code? Maybe in MAIN.C? Maybe in IO.C? Please, help me.
I need an example to know how I can get an interrupt when bit 0 of port 3 is set. Can anybody help me?
I have not done the 16x for a while, someone else (Stefan?) please chime in on this one. Erik
Erik, I don't mind in another micro. Please I need an example to see how I can do it. I don't mind if this example is in another micro. I want to learn only learn. I think you could take the mickey out of me, but please don't do it. I need learn so much about electronic programming. Sorry if I had done something wrong.
general about interrupts: 1) for external interrupts, you must use a pin designated for that purpose. 2) you must code an ISR (interrupt service routine). 3) you must enable the interrupt. in some cases: a) you must configure the port pin correctly for this purpose. b) you must set up a "crossbar" or such to route the interrupt. c) you must specify the priority of the interrupt. (often a default will do) Erik
Thanks a lot, Erik. I know I have to do all the steps you said to me, because I know the theory but I have so many problems with then practical. It's my first time that I use XC167 and I need some basic examples to do that. How can I configure whatever port pin to do whatever function when it is on or off?
I need some basic examples to do that A professional rarely can "give samples" because his code is owned by whoever paid him. Thus the standard reply "show your code and someone will comment on the likely cause of the problem you describe". Erik
Thanks again, Erik. I'd like to say that I don't want to copy any code, only have a reference, but I'm try to do you said to me. Thanks a lot.
View all questions in Keil forum