Page 1 of 1

Touch Sensitive Switch

Posted: Sun Sep 09, 2012 3:47 pm
by JohnCrow
Touch Sensitive Switch.

While browsing a component website I came across an IC shown as a 2 Channel touch switch.
It was under a couple o quid so I added a couple to the order to have a play with.

When it arrived it as an 8pin dip device with a small sticky label on the top. I immediately pealed this off to see what the device was.

It turned out to be a 12F683 PIC.
The code was protected (as expected) so I was not able to read it to see how the device was programmed :(

I wired it up on the bread board to test it out, and it works exactly as shown in the specs.

I built it up on a small PCB with a couple of chrome touch sensors.

The sensors are screw in covers to fit in a countersunk screw from the local diy shop.
Because they are chrome plated it was not possible to solder them and the thread is not long enough to use a nut and connector on the back.

The touch inputs are use a 1M-ohm pull up resistor to Vdd.

I made the connection by having a couple of bent over bits of wire under the dome, and connected these to the pcb.

The switches allow the sensors to be set to either latch or momentary.
Pins 4 & 5 on the chip are connected to the switch common termnals, with pins 1 & 2 on the switch to Vdd or Gnd


The screw terminals are left to right
Vdd, Gnd, Output1, Output2

The device will work on any voltage from 2.5V to 5V.
This makes it usable with PIC, AVR, ARM or Raspberry Pi without the need for an external voltage regulator.
Circuit Diagram
Circuit Diagram
Touch-Circuit.gif (3 KiB) Viewed 12604 times
Breadboard Prototype
Breadboard Prototype
Breadboard.jpg (103.58 KiB) Viewed 12604 times
My breadboard has a PP3 battery and 7805 regulator underneth it.
The 4mm binding posts are connected to the regulator input and the spring termnals to the regulator output (5V).
The switch on the top of the case turns off the battery.

The blue & yellow wires at the bottom of the photo are the touch inputs.
It will actually switch by touching the insulation as well as the metal contacts.
Touch Switch
Touch Switch
Touch Switch.JPG (115.15 KiB) Viewed 12604 times
The sensors are actually held on the board by a blob of epoxy resin on the back.

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 7:47 pm
by Spanish_dude
Probably some AD conversion using the PIC.
Have you tried probing the inputs ? See what the signal looks like.

If you know what happens when you touch the switches you could probably make your own program.

Nicolas

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 7:54 pm
by Steve001
sorry if this has posted twice .

Looks like a good project john

I was going to have a play with touch sensors but time evades me :(

Have a look here there is some code examples too

http://www.bytecraft.com/Touch_Sensitive_Switch

steve

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 7:57 pm
by STibor

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 8:00 pm
by JohnCrow
I do intend having a look at trying to replicate it it flowcode sometime.
Dont think it will be too difficult, but like Steve its finding time for all these projects.

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 8:20 pm
by STibor
Simple programs and circuits.

Re: Touch Sensitive Switch

Posted: Sun Sep 09, 2012 9:00 pm
by JohnCrow
Thanks STibor
That looks interesting.
I'll try your program out when I get chance.

Re: Touch Sensitive Switch

Posted: Tue Sep 11, 2012 11:44 am
by jgu1
Hi all!

Here are some related projects:

http://www.pcbheaven.com/circuitpages/P ... ch_Button/
http://www.pcbheaven.com/circuitpages/P ... _Function/

Very interesting. It would be nice if someone could translate them into FC I have no experience with C or assambler.

Best regard

Jorgen

Re: Touch Sensitive Switch

Posted: Sun Sep 16, 2012 2:27 pm
by JohnCrow
This is a simple flowchart and circuit to use the touch switch board with an ECIO

With the slide switch to the left, the channel latchs
With the slide switch to the right the channel toggles.

For example if Sensor 1 is set to latch and Sensor 2 to toggle.
Touch Sensor 1. It will show Sensor 1 Touched. Then touch Sensor 2, it will show Both Sensors Touched.
To unlatch Sensor 1 touch it again.
E-Blocks Setup
E-Blocks Setup
DSC00720.JPG (133.29 KiB) Viewed 12494 times
Simple touch.fcf
(12.22 KiB) Downloaded 451 times

Re: Touch Sensitive Switch

Posted: Mon Sep 17, 2012 11:29 am
by jgu1
Hi John! :D

Very interresting. I will test it this evening.

Maybe something I have misunderstood, but where can I find the input for the slideswitch in the program.


Do you have tied the input to ground with a resistor,if you have is 1M ok :?:

Best regard

Jorgen.

Re: Touch Sensitive Switch

Posted: Mon Sep 17, 2012 12:37 pm
by JohnCrow
Hi

The slide switch is not in the flowcode program.
They connect pins 4 & 5 on the 8pin device to either 5V or Gnd.(This sets it to latch or toggle)
The 8pin pic was bought as a touch switch device. See the first post in the thread.

The touch inputs have a 1M-ohm pull up to the +V line.

Re: Touch Sensitive Switch

Posted: Mon Sep 17, 2012 12:55 pm
by jgu1
Thank“s John :D