[HomeBrew] more touch switches

Steven Weber kd1jv at moose.ncia.net
Wed Jan 5 22:04:16 EST 2005


If you know how to program a uP, a touch switch is fairly easy to implement. 

Set up an R/C circuit on a port, using a pull up resistor of say 470K in
combination with your touch senser (piece of copper clad board). 

Then set up the following routine:

1: Configure  port to output and set low. (discharges C)
2: Configure port to high impedance input.
3. Wait a short period of time. 
4. Test port to see if it is high or low. 

No touch = short time constant so port will read high.
Touch = longer time constant, so port will read low. 

The tricky part is figuring out how long to wait before the test. A simple
trimmer cap can be used to adjust the time constant, or if you want to get
fancy, a test routine can determine the time constant to use on power up. 

The advantage here is your not trying to couple an AC signal or using
resistance. It can be a little temperature sensitve though. 

I made a complete touch paddle with an 8 pin micro (Atmel ATTINY 15) using
this method and it worked reasonably well. I suppose you could use one of
those brain dead microchip PICs too if you wanted. 
72,
Steve, KD1JV
"Melt Solder"
White Mountains of New Hampshire
http://www.qsl.net/kd1jv/


More information about the HomeBrew mailing list