ts-7000
[Top] [All Lists]

[ts-7000] Re: Question about an interrupt handler and debounce

To:
Subject: [ts-7000] Re: Question about an interrupt handler and debounce
From: "bdon003" <>
Date: Mon, 30 Jun 2008 19:31:50 -0000
I need to have the board continuously processing data from sensors 
and hosting that information for another computer, and relative to 
uptime, the keypad will be used very minimally, so I don't think 
polling the keypad will work well for me.  Also, as this is just for 
school, I would like to get some experience with interrupts, if it 
does not turn into too much work.  

As far as making it available to user space, I havn't worked through 
it much but I would like to write the entered code, if correct, to a 
file so that it can be logged.  

What do you mean by using the FPGA to do the debouncing?  

Thanks for the tips.

Brandon


--- In  David Hawkins <> wrote:
>
> Hi,
> 
> > I need to hook up a 3x4 Matrix Keypad to the board and
> > have it send an interrupt when a key has been pressed.
> 
> What you really want is for your user-space application
> to see the key presses.
> 
> How the driver is implemented is hidden from the user.
> I haven't implemented a key press driver, but I have
> seen examples where the key pad is polled rather than
> interrupt driven. I'm not sure if you'll have this
> book, but there is an example in;
> 
> "Embedded Systems Building Blocks", 2nd Ed, Jean
> Labrosse.
> 
> Its for the uCOS-II RTOS, but the idea is the same as
> you might want to implement. According to that text,
> typically bounce times are 5ms to 30ms. So they're
> pretty long timescales. That driver polls keys,
> detects key presses, and keys held down.
> 
> If you were to write a driver that was interrupt driven
> then you definitely need to take care regarding debouncing.
> If you are using a TS-7300 and can use the FPGA, then
> you could debounce in the FPGA.
> 
> Check out the above book for its polling routine.
> I'm pretty sure you could setup a kernel timer inside
> your driver, detect key presses, etc, and then send
> the results to userspace. Chances are this will be a
> lot simpler than trying to use interrupts on non-debounced
> pins.
> 
> Alternatively, add debounce circuits to your keypad to
> ensure that you don't get ringing, and then you can
> use interrupts.
> 
> Cheers,
> Dave
>



------------------------------------

Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU