public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* Noise causes gpio interrupt
@ 2007-01-25  9:40 Arnold
  2007-01-25  9:43 ` Syed Mohammed, Khasim
  0 siblings, 1 reply; 6+ messages in thread
From: Arnold @ 2007-01-25  9:40 UTC (permalink / raw)
  To: linux-omap-open-source

Hi All,

I am working on omap5912 and I am using linux 2.6.17.
I am using a gpio to handle interrupts. I believe that
I am having a noise interrupt which my firmware thinks
is a really interrupt. Is there a way to distinguish a
noise interrupt from a real interrupt?


Thanks,
Arnold


 
____________________________________________________________________________________
Now that's room service!  Choose from over 150,000 hotels
in 45,000 destinations on Yahoo! Travel to find your fit.
http://farechase.yahoo.com/promo-generic-14795097

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: Noise causes gpio interrupt
  2007-01-25  9:40 Noise causes gpio interrupt Arnold
@ 2007-01-25  9:43 ` Syed Mohammed, Khasim
  2007-01-25 15:01   ` Woodruff, Richard
  0 siblings, 1 reply; 6+ messages in thread
From: Syed Mohammed, Khasim @ 2007-01-25  9:43 UTC (permalink / raw)
  To: Arnold, linux-omap-open-source

I don't know about the GPIO module in 5912. If you have, you can try configuring your GPIO interrupt to level instead of edge interrupt. I don't know if debounce time can help you in fixing this.
 
Regards,
Khasim 

________________________________

From: linux-omap-open-source-bounces@linux.omap.com on behalf of Arnold
Sent: Thu 1/25/2007 3:40 AM
To: linux-omap-open-source@linux.omap.com
Subject: Noise causes gpio interrupt 



Hi All,

I am working on omap5912 and I am using linux 2.6.17.
I am using a gpio to handle interrupts. I believe that
I am having a noise interrupt which my firmware thinks
is a really interrupt. Is there a way to distinguish a
noise interrupt from a real interrupt?


Thanks,
Arnold



____________________________________________________________________________________
Now that's room service!  Choose from over 150,000 hotels
in 45,000 destinations on Yahoo! Travel to find your fit.
http://farechase.yahoo.com/promo-generic-14795097
_______________________________________________
Linux-omap-open-source mailing list
Linux-omap-open-source@linux.omap.com
http://linux.omap.com/mailman/listinfo/linux-omap-open-source

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: Noise causes gpio interrupt
  2007-01-25  9:43 ` Syed Mohammed, Khasim
@ 2007-01-25 15:01   ` Woodruff, Richard
  2007-01-26  7:19     ` Arnold
  0 siblings, 1 reply; 6+ messages in thread
From: Woodruff, Richard @ 2007-01-25 15:01 UTC (permalink / raw)
  To: Syed Mohammed, Khasim, Arnold, linux-omap-open-source

Depending on the polarity and the circuit you might also get away
configuring the internal pull-up/down to try and help mask any noise.

In the past for some early designs I recall things like the lcd inducing
noise on the touch screen interrupt.  For that I believe we dumped an
external pull up one the line to stop it (along with board routing and
bits to diminish the noise).  The internal pull's aren't so strong, but
if your on the edge and the driver of that line can force the state it
might be enough to mask it.

Regards,
Richard W.
 

> -----Original Message-----
> From: linux-omap-open-source-bounces@linux.omap.com 
> [mailto:linux-omap-open-source-bounces@linux.omap.com] On 
> Behalf Of Syed Mohammed, Khasim
> Sent: Thursday, January 25, 2007 3:44 AM
> To: Arnold; linux-omap-open-source@linux.omap.com
> Subject: RE: Noise causes gpio interrupt 
> 
> I don't know about the GPIO module in 5912. If you have, you 
> can try configuring your GPIO interrupt to level instead of 
> edge interrupt. I don't know if debounce time can help you in 
> fixing this.
>  
> Regards,
> Khasim 
> 
> ________________________________
> 
> From: linux-omap-open-source-bounces@linux.omap.com on behalf 
> of Arnold
> Sent: Thu 1/25/2007 3:40 AM
> To: linux-omap-open-source@linux.omap.com
> Subject: Noise causes gpio interrupt 
> 
> 
> 
> Hi All,
> 
> I am working on omap5912 and I am using linux 2.6.17.
> I am using a gpio to handle interrupts. I believe that I am 
> having a noise interrupt which my firmware thinks is a really 
> interrupt. Is there a way to distinguish a noise interrupt 
> from a real interrupt?
> 
> 
> Thanks,
> Arnold
> 
> 
> 
> ______________________________________________________________
> ______________________
> Now that's room service!  Choose from over 150,000 hotels in 
> 45,000 destinations on Yahoo! Travel to find your fit.
> http://farechase.yahoo.com/promo-generic-14795097
> _______________________________________________
> Linux-omap-open-source mailing list
> Linux-omap-open-source@linux.omap.com
> http://linux.omap.com/mailman/listinfo/linux-omap-open-source
> 
> 
> _______________________________________________
> Linux-omap-open-source mailing list
> Linux-omap-open-source@linux.omap.com
> http://linux.omap.com/mailman/listinfo/linux-omap-open-source
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: Noise causes gpio interrupt
  2007-01-25 15:01   ` Woodruff, Richard
@ 2007-01-26  7:19     ` Arnold
  2007-01-26 14:15       ` Dirk Behme
  0 siblings, 1 reply; 6+ messages in thread
From: Arnold @ 2007-01-26  7:19 UTC (permalink / raw)
  To: Woodruff, Richard, Syed Mohammed, Khasim, linux-omap-open-source

Hi,

First, Thank you for your help. I really appreciate
it. It seems that my problem is the other way around.
I think I am not getting a noise but instead I could
not detect interrupts that has a fast transition. I
tried to use a switch to see if the driver is working
properly, and it looks fine. It could detect a switch
being press. However when the interupt comes from a
device and the transition of rise to fall is 20ns it
could not detect that an interrupt occured. I also
tried to increase the transition to 20ms and it was
able to detect the interrupt. I am thinking now that
maybe the gpio register have not updated yet the
register but the signal is already falling. So maybe
thats why it didnt see it as an interrupt. Have anyone
encountered the same problem? Is there any recent
patch on the interrupt routine that may solve the
problem?

Thanks erveryone for your help,
Arnold 

--- "Woodruff, Richard" <r-woodruff2@ti.com> wrote:

> Depending on the polarity and the circuit you might
> also get away
> configuring the internal pull-up/down to try and
> help mask any noise.
> 
> In the past for some early designs I recall things
> like the lcd inducing
> noise on the touch screen interrupt.  For that I
> believe we dumped an
> external pull up one the line to stop it (along with
> board routing and
> bits to diminish the noise).  The internal pull's
> aren't so strong, but
> if your on the edge and the driver of that line can
> force the state it
> might be enough to mask it.
> 
> Regards,
> Richard W.
>  
> 
> > -----Original Message-----
> > From:
> linux-omap-open-source-bounces@linux.omap.com 
> >
>
[mailto:linux-omap-open-source-bounces@linux.omap.com]
> On 
> > Behalf Of Syed Mohammed, Khasim
> > Sent: Thursday, January 25, 2007 3:44 AM
> > To: Arnold; linux-omap-open-source@linux.omap.com
> > Subject: RE: Noise causes gpio interrupt 
> > 
> > I don't know about the GPIO module in 5912. If you
> have, you 
> > can try configuring your GPIO interrupt to level
> instead of 
> > edge interrupt. I don't know if debounce time can
> help you in 
> > fixing this.
> >  
> > Regards,
> > Khasim 
> > 
> > ________________________________
> > 
> > From:
> linux-omap-open-source-bounces@linux.omap.com on
> behalf 
> > of Arnold
> > Sent: Thu 1/25/2007 3:40 AM
> > To: linux-omap-open-source@linux.omap.com
> > Subject: Noise causes gpio interrupt 
> > 
> > 
> > 
> > Hi All,
> > 
> > I am working on omap5912 and I am using linux
> 2.6.17.
> > I am using a gpio to handle interrupts. I believe
> that I am 
> > having a noise interrupt which my firmware thinks
> is a really 
> > interrupt. Is there a way to distinguish a noise
> interrupt 
> > from a real interrupt?
> > 
> > 
> > Thanks,
> > Arnold
> > 
> > 
> > 
> >
>
______________________________________________________________
> > ______________________
> > Now that's room service!  Choose from over 150,000
> hotels in 
> > 45,000 destinations on Yahoo! Travel to find your
> fit.
> > http://farechase.yahoo.com/promo-generic-14795097
> > _______________________________________________
> > Linux-omap-open-source mailing list
> > Linux-omap-open-source@linux.omap.com
> >
>
http://linux.omap.com/mailman/listinfo/linux-omap-open-source
> > 
> > 
> > _______________________________________________
> > Linux-omap-open-source mailing list
> > Linux-omap-open-source@linux.omap.com
> >
>
http://linux.omap.com/mailman/listinfo/linux-omap-open-source
> > 
> 



 
____________________________________________________________________________________
Need a quick answer? Get one in minutes from people who know.
Ask your question on www.Answers.yahoo.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Noise causes gpio interrupt
  2007-01-26  7:19     ` Arnold
@ 2007-01-26 14:15       ` Dirk Behme
  2007-01-29 21:01         ` Woodruff, Richard
  0 siblings, 1 reply; 6+ messages in thread
From: Dirk Behme @ 2007-01-26 14:15 UTC (permalink / raw)
  To: Arnold; +Cc: linux-omap-open-source

Arnold wrote:
> ... However when the interupt comes from a
> device and the transition of rise to fall is 20ns it
> could not detect that an interrupt occured. I also
> tried to increase the transition to 20ms and it was
> able to detect the interrupt. ...

Maybe http://www.ti.com/litv/pdf/spru767a, section 1.6 or 
page 28, can help:

"Because of the sample operation with the functional clock, 
the minimum pulse
width on the input GPIO to trigger a synchronous interrupt 
request is two times
the functional clock period. This minimum pulse width must 
be met before and
after any expected level transition detection."

Best regards

Dirk

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: Noise causes gpio interrupt
  2007-01-26 14:15       ` Dirk Behme
@ 2007-01-29 21:01         ` Woodruff, Richard
  0 siblings, 0 replies; 6+ messages in thread
From: Woodruff, Richard @ 2007-01-29 21:01 UTC (permalink / raw)
  To: Dirk Behme, Arnold; +Cc: linux-omap-open-source

I generally interpret this to mean you can go low, high, low to fast
else you will miss your high.  This is not what was indicated but it
could be what is happening.  Your 'high' state must also obviously cross
the signaling threshold value also.

If you go low to high quickly I'm not aware of that being an issue.  You
just don't see it for a couple of gpio clocks (assuming you stay high
long enough).

It might be possible that the interrupt was dropped somewhere in
software.  Back in 1510/5910 days this was possible given the way Linux
configured things up and serviced interrupts (mismatch of internal
polarity to configured ones along with quickly unmasked interrupts).
This shouldn't be an issue for later ones like OMAP2 which hook them all
internally as level and only offer edge's on external lines.  MV code at
one point tried to peek at status registers and re-trigger to identify
edges.  I've not looked at what the current code path is for open source
versions here.

You may have a couple types of GPIOs, used to have ARMIO/MPUIO and GPIO.
You might try moving your source to some different pins and see if they
all behave the same way.

If you have a debugger, you really should be able to sit in a stopped
state then make a fast trigger event.  Then you should be able to read
the GPIO registers directly and see if the event was caught.  It almost
certainly will be.

In the end I'd guess your source isn't driving the line high enough for
the interrupt pulse, or the pulse width is to short.  I don't think the
slope of the pulse should matter.  Just that it goes high enough for a
long enough time before falling.

Regards,
Richard W.

> Arnold wrote:
> > ... However when the interupt comes from a
> > device and the transition of rise to fall is 20ns it
> > could not detect that an interrupt occured. I also
> > tried to increase the transition to 20ms and it was
> > able to detect the interrupt. ...
> 
> Maybe http://www.ti.com/litv/pdf/spru767a, section 1.6 or
> page 28, can help:
> 
> "Because of the sample operation with the functional clock,
> the minimum pulse
> width on the input GPIO to trigger a synchronous interrupt
> request is two times
> the functional clock period. This minimum pulse width must
> be met before and
> after any expected level transition detection."
> 
> Best regards
> 
> Dirk

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-01-29 21:01 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-25  9:40 Noise causes gpio interrupt Arnold
2007-01-25  9:43 ` Syed Mohammed, Khasim
2007-01-25 15:01   ` Woodruff, Richard
2007-01-26  7:19     ` Arnold
2007-01-26 14:15       ` Dirk Behme
2007-01-29 21:01         ` Woodruff, Richard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox