External Interrupt on GP2

Status
Not open for further replies.

Suraj143

Active Member
I'm receiving a continuous 5V square wave pulse 50Hz. I want to detect High to low transition (Falling edge) on GP2.

My question is Do I need to enable internal WPU on GP2? I use PIC12F675.
 
If you use the IOC (Interrupt on change) function on GP2 then if, when the interrupt triggers, the pin is low it must have just transitioned. You need the WPU if the signal is active low only.

Mike.
 
Hi,

I need to use INTF external interrupt flag bit.I set INTEDG to falling edge.In this case do I need the internal WPU enable?
 
If your signal is driven high then WPU not needed. If open collector then WPU needed. Either way you can enable WPU as it can't do any harm.

Mike.
 
You only need pull-ups if the source is open-collector, as long as it's a normal logic output then no pull-ups are needed.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…