View previous topic :: View next topic |
Author |
Message |
pulurumbuluruciu
Joined: 06 Nov 2013 Posts: 27
|
Interrupt on change not working with low current EX trigger |
Posted: Mon Jan 06, 2014 4:43 pm |
|
|
When I'm using a low-power (5V , ~10 mah) external trigger source my PIC wont "See" the interrupt. I tested with the logic-analyzer and the rising edge generated by the external trigger is there. How come the PIC does not "see" it and the logic analyzer do!? Another story is if I use a higher current external trigger, is working as it should. What could be the problem?
(I'm using a LED blink with decent lighting time to see if the INT fired).
The PIC setup is with a 10K pull-down resistor for the EXT int pin, as I want to detect the rising edge. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Mon Jan 06, 2014 5:36 pm |
|
|
Post your schematic and a detailed description of the circuits and
also post your test program.
If you look at your post and several of the other posts made at the
same time, you notice that very little information is given to us.
Post the details. Then we have a chance to understand your problem
and maybe help you to solve it. |
|
|
jgschmidt
Joined: 03 Dec 2008 Posts: 184 Location: Gresham, OR USA
|
|
Posted: Mon Jan 06, 2014 8:10 pm |
|
|
I ran into something similar recently trying to get a 12LF1822 to wake up from sleep via a signal from a PIR sensor. I saw the same thing on my scope - a nice clean rising edge but apparently not enough "umph" to trigger the hardware interrupt. (Woke up just fine with a 1K to positive.) The PIR sensor only draws 1uA when idle and 100uA when triggered. Rather than dig through the specs I just amplified it with a PN2222 transistor to see if that would work, and it did. Everything works fine now. _________________ Jürgen
www.jgscraft.com |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19535
|
|
Posted: Tue Jan 07, 2014 4:56 am |
|
|
Key thing is that on many chips the INT_EXT pin has a Schmitt buffer.
So (for instance), on a 18F4520, at 5v, the signal has to go up to 4v, before it is seen as 'high' (0.8*Vdd).
Now on this chip if instead you use the 'interrupt on change' on RB4 to RB7, this triggers at 2v.
It's designed so that signals carrying significant noise won't cause erroneous triggers.
Odds are your logic analyser uses buffers that switch at perhaps 2 to 2.4v.
Best Wishes |
|
|
|