Capacitive Touch Sensor Circuit

The post explains an effective capacitive touch sensor circuit which may be used for detecting intruders near a priced object such as your vehicle. The idea was requested by Mr. Max Payne.

The  Circuit Request

Hello Swagatam,

Please Post a Capacitive/Body/Touch Sensitive Circuit can be applied on bicycle. Such device seen on car security system, When somebody come closer to car or a simple touch would trigger the alarm for 5 seconds.

How this type of alarm works, the alarm only trigger when somebody come closer (say 30cm) what type of sensor they use?


Circuit Schematic

Capacitive Touch Sensor Circuit

Circuit Image Courtesy: Elektor Electronics

The Circuit Design

The capacitive touch sensor circuit may be understood with the help of the following description:

IC1 is basically wired as an astable, but without incorporating a real capacitor. Here a capacitive plate is introduced and takes the position of the capacitor required for the astable operation.

It must be noted that larger capacitive plate will produce better and much reliable response from the circuit.

Since the circuit is intended to work as a vehicle body touch alert security system, the body itself could be used as the capacitive plate, and it being huge by volume would suit the application quite well.

Once the capacitive touch sensor plate is integrated, the IC555 comes into a standby position for the astable actions.

On detecting a "ground" element at a close proximity, which could be the hand of a human, the required capacitance is developed across pin2/6 and ground of the IC.

The above results in an instantaneous development of frequency as the IC starts oscillating in its astable mode.

The astable signal is acquired at pin3 of the IC which is appropriately "integrated" with the help of R3, R4, R5 along with C3----C5.

The "integrated" result is fed to an opamp stage rigged as a comparator.

The comparator formed around IC2 responds to this change from IC1 and translates it into a triggering voltage, operating T1 and the corresponding relay.

The relay may be wired with a siren or a horn for the required alarming.

However it's seen practically that IC1 produces a peak positive to negative voltage pulse at the instant when a caapcitive ground is detected near the plate.

IC2 solely responds to this sudden rise in the peak voltage for the required triggering.

If the capacitive body continues to be at the close proximity of the plate, the peak frequency voltage at pin3 vanishes to a a level which may be undetectable by IC2, rendering it inactive, meaning the relay stays active only at the instant the capacitive element is brought or removed near the plate surface.

P1,P2 may be adjusted for acquring maximum sensitivity from the capacitive plate
For obtaining a latching action, the output of IC2 may be further integrated to a flip flop circuit, making the capacitive touch sensor circuit extremely accurate and responsive

104 thoughts on “Capacitive Touch Sensor Circuit

  1. Have questions? Please feel free to post them through comments! Comments will be moderated and solved ASAP.
  2. Hi Swagatam

    Nice idea. But, usually the body of a car/bike is connected to the (-)ve railing of the vehicle's electrical system so, the 555's trigger will always be connected to the ground.

    • Hi Abu-Hafss,
      While writing the article I had this in mind, but later completely forgot to address it.

      Yes, you are right, the circuit will need a separate power supply using a small SMF battery, which will be switched only when the vehicle is not being used, and during the operational periods the battery will be charged from the vehicle alternator.

      Or alternatively the power can be derived from the vehicle battery itself but isolated using a ferrite transformer DC DC converter.

  3. Hi Swagatam sir
    I made that Simplest Inverter Circuit that uses 2 nos 100 ohm 10watt,2nos15 ohm 10watt and 2 nos 2n3055 transistor,12 0 12 5 amp transformer,32ah battery when I connected a 60watt bulb the bulb is lighting like an agarbatti only I checked all the components they all r working fine.what will be the issue.

    • Hi Vijeesh,

      when I built it, a 60 watt bulb produced full 60 watt bright illumination and lasted for about 30 minutes through a 12V 6.5AH kinetic honda battery.
      The transformer that I had used was rated correctly at 5 amps and it weighed around 5kgs.
      does your transformer weigh that much.
      If it's lighter would mean it's a 2 amp not 5 amps.

  4. Yes Sir
    You r right the amp rate is very low,I tried with another transformer its working fine.I am doing one more circuit "12V to 220V Inverter 180W by 2N3055"which is in 'Electronic projects circuits'. BD 680 transistor was not available instead they give me BD 140 said its equivalent to BD 680,I made the circuit and its not working,what should be the watt of 22 ohm,330 ohm and 27k resistors.the 2N3055 are getting hot quickly what will be the issue.

  5. Hai Sir
    Thank you very much for the help,I made it and its Woking perfectly well.being a civil engineer,electronics is my hobby,I am so happy seeing it working.thanks again.

  6. Yes Sir,its already TIP 127 as you suggested early.Given below are the actual quantity and value used in the circuit except 2N3055 which I am going to increase as you suggested, any change in the value,quantity or connection.
    D1,D2- IN5402 (2NOS)
    Q2,Q5- TIP 127 (2NOS)
    Q3,Q4 – BC549 (2NOS)
    Q1,Q6 – 2N3055 (10NOS) 5 on each side parallel
    R1,R8 – 22 OHM 5WATT (2NOS)
    R2,R3,R6,R7- 330 OHM 1/4 WATT (4NOS)
    R4,R5- 27K 1/4 WATT (2NOS)
    C1,C2-0.47 uf (2NOS)
    Transformer 220 V 50 HZ (Class 200) micro wave Owen transformer (800 watt) that I have to rewind secondary for (500 watt).

    • 22 ohms will also need to be 10 in numbers, each for the individual 2N3055 bases.

      the trafo primary should be 9-0-9V

      battery = 12V 150ah.

      rest all looks OK.

      Mount TIP127 also on large heatsinks so that it stays cool

      2N3055 will need large finned heatsinks.

      preferably use a small fan for cooling these devices.

  7. good day sir! May i ask if there is a capacitive proximity sensor that uses the negative/ground as the touch/trigger sensor? I want to create an alarm for car and use the body/chassis as sensor. So that when someone comes near, or touch the car, the alarm will sound off. Thank you so much. Unfortunately, your capacitive proximity switch for vehicle security cannot handle a large surface area. It cannot make use of a whole motorcycle body as a sensor. I tried adjusting and replacing the variable resistor to the highest value possible (10Meg) but still no result. Thank you for your response.

    • Bugoy, try the above circuit by powering the circuit with a separate 12V battery, in this way you would be able to isolate the circuit from the body ground of the car and use the chassis as the capacitive plate,

    • Good Day Sir!
      I really admire your enthusiasm in electronics. I myself is also inclined to electronics. Unfortunately, I tried powering it separately but it cannot make use of the whole motorcycle. I guess it is only applicable to small sensor plates. The largest that I have tried is the cover of a metal casserole. Beyond that, it wont function anymore. Can you please suggest some other circuit similar to it? And also a circuit for an isolated 12v to isolated 12v converter. Thank you so much in advance.

    • Thanks Bugoy, I don't think such a circuit could be designed which would allow the entire body of the vehicle to behave as the sensor. That's why most vehicles rely on a shock sensor or a vibration detector circuit instead of capacitive proximity sensor concepts.

      I would be publishing a shock sensor circuit soon in this blog, which might be relevant to your application.

    • Good Day Sir!
      Thank you so much for your feedback. I am experimenting on something similar to your circuit with some modifications thru trial and error. I think I am arriving at my desired result. But, my main problem now is, it should be powered separately. The body of a vehicle is the negative ground. Could you please provide the simplest fully isolated converter so that I could use the vehicle's battery? I cannot make use of another battery because there is no more room for it in my motorcycle. The isolated dc-dc converter should be efficient and will not drain the battery for an overnight use of the alarm which consumes 10mA on standby. Thank you very much for your time and effort.

    • Hi Bugoy, you can try the following circuit:

      D1—D4, T1, R4, R5, R6, VR1 all these may be removed, not required for this application

      The primary side of the coil could be 6 turns of 25mm magnet wire, secondary can also be the same, slight experimentation with the no. of turns will need to be done for getting the precise isolated voltage for the circuit.

    • Good Day Sir!
      Thank you so much for your response. May I just ask, do the left side and the right side of the transformer share the same ground? Also, what kind of transformer to use? Torroid, pot core, or a conventional transformer? What will I replace T1? Will pin 5 directly connect to ground, or I have to put a 0.01 cap? The circuit should function something like this sir.

      Im sorry, I used your schematic to edit and visualize the principle.
      I hope you could help me more. Thank you.

    • Good day Bugoy,

      Left side ground can be left isolated from the battery ground.

      Transformer core could be any ferrite core but a torroidal core would be ideal.

      Pin5 should be terminated to ground through a 0.01uF capacitor.

      Yes the drawing you have made is correct ,except pin5.

    • good day sir! Thank you very much for your feedback. I just want to clear some more things before i purchase the parts. Is this a dc-dc isolated converter? What is the diameter of the torroid? What awg magnet wire to use? Is the other end of the primary is positive, while the other end becomes the negative? Is it efficient enough not to discharge an idle motorcycle battery for overnight use with the sensor? Can i connect the sensor wire directly to the battery negative? Considering that the battery negative is connected to chassis. You are so kind sir and helpful. You are heaven-sent. Thank you in advance.

    • Good day Bugoy,

      yes, It is a DC DC isolated converter circuit, the secondary coil not touching anything in the primary stage of the coil.

      Wire gauge is not critical since the current requirement is low, you can try with a 25 SWG or anything between 0.3mm to 0.5 magnet wire.

      the core dimension is also not important, use any size torroid which accommodates the winding comfortably.

      Connecting the sensor wire to the body won't damage the sensor circuit but I am not able to simulate the results whether it will work as intended or not, you'll have to confirm it practically.

  8. Hi Swagatam

    I think 6 turns of 0.3mm wire will heat up the mosfet.
    Recently, I have working on a small ferrite transformer for CDI. 22 turns of 0.4mm wire in the primary worked but mosfet was fairly warm (whereas, it should operate at ambient temperature).

    • Hi Abu-Hafss,

      The number of turns to be selected depends on the frequency and the required output voltage, As frequency increases the number of turns decreases and vice versa…it works in that way.

      6 turns would be perfect at a certain frequency, but if the frequency is decreased or is not matching with the number of turns, the mosfet will start getting hot.

  9. Good Day Sir!
    Thank you for your response. There are some little things that I want to clarify. What does the dots means in the opposite sides of the coil in the schematic sir? And also, can you please teach me how to wire the coil, I am not yet familiar with coils and transformers. What leads of the coil goes where? And also, how to wind the wire in the torroid? Is there a particular pattern to follow? Thank you so much. I really appreciate it. I will update you as soon as I get results. Take care Sir.

    • Good day Bugoy,

      The dots indicate the start point of the respective winding, but it's irrelevant here since there are just two winding with no center taps. Ignore the dots and start winding without bothering about any particular direction or pattern.

      Use one winding as the primary for feeding the 555 frequency, the other winding could be used as the output. The output winding voltage will need to be checked with a meter for confirming its polarity before connecting the diode and the filter capacitor.

  10. Good Day Sir!
    Thank you. One more thing Sir, how will I wind the coil? Overlapping each other? Alternate spaces? Bifilar method? What Sir? I hope you could illustrate it in a picture or even a hand-drawn picture. I will be buying the parts today. I am so excited about it. What will be the type of electricity feeding the primary? oscillated AC or oscillated DC? I know for a fact that the output in the secondary is isolated DC. Thank you Sir.

  11. Good Day Sir!
    How are you? I have some not so very good news though. I completed the circuit but unfortunately, there is no output in the coil. Without the mosfet, the reading from PIN3 and GND is 5.24V DC. But when I connect the mosfet, the circuit became a bit shorted and has a reading of a fraction of a volt. The LED indicator from my power supply became dim, indicating that there is a little short on the circuit. What do you think is the problem Sir? I guess I wired the mosfet right, PIN1 is GATE, PIN2 is DRAIN, PIN3 is SOURCE. GATE goes to PIN3 of LM555, DRAIN goes to one end of primary, and SOURCE goes to GND. Thank you for continuing helping me.

    • Bugoy, don't use a mosfet, try a TIP122 transistor.

      To begin with use 20 turns for the primary and check the voltage, if it's higher than the required value, gradually go on decreasing the turns by trial and error method until the right number of turns are achieved.

  12. Good Day Sir!
    I used the IRF540 as indicated in the circuit diagram that you provided sir. Is it really normal for the output at PIN3 of LM555 to be 5.24V? I think it is not oscillating to drive the coil. Will the TIP122 oscillate the output at PIN3? How will I know or test if the output from PIN3 is oscillating? Will an LED blink test will do? Moreover, I want to send you a link of my breadboard assembly. Thank you so much for your efforts.

    • Good day Bugoy, if the voltage at pin3 is half of the supply volatge that would possibly indicate it's oscillating, this is due to the approximately 50% duty cycle generated by the IC

      For confirmation you can connect a 1uF capacitor in series with the mosfet/BJT gate/base resistor, if the device still conducts (shows boosted output) will indicate an oscillation other wise there could be a possible fault in the IC circuit.

  13. Good Day Sir!
    I just want to update you in the progress of my project. Unfortunately, it didnt work Sir. The IRF540 heats up in just a few seconds. There is no output voltage in the primary as well as in the secondary of the coil. I followed the schematic properly. The 555 is working because when I connect an LED to pin 3, it blinks rapidly. What could be wrong sir? Is there really a 12V to isolated 12V converter? Thank you so much.

    • Bugoy, the circuit frequency should be at least 20kHz, and an LED will not blink at this frequency, which capacitor have you used in the circuit, it should be 1nF that's 0.001uF or a 102 capacitor.

      Confirm the frequency, the circuit will keep malfunctioning unless the above is corrected.

  14. Good Day Sir!
    I used 0.001uF or 102 Sir. But the IRF540 heats up rapidly. Could you please provide a revised schematic that I can follow properly. Thank you so much. I am looking forward to completing this project. Thank you for your patience.

    • Bugoy, the referred DC DC converter circuit is perfect, you are not following my instructions properly.

      I said the frequency should be above 20 kHz…….. with the shown components the frequency of the circuit could be even above 100 kHz, so first make sure you are getting this frequency.

      You said a test LED blinked at pin3, that's impossible at this frequency.

      I also told you to use a TIP122 and 20 turns at the primary initially and then gradually reduce it to the optimal point, although a 20 turn will also work since the current requirement at the secondary is quite low.

      please follow the above for getting correct results.

  15. Good Day Sir!
    Thank you for your patience. I will do as what you have told. Do I still need the 33k resistor from PIN5 to positive? I will update you ASAP. Thank you so much Sir. Take care.

  16. Good day Sir!
    Thank you. I will be going now to the electronics store. I will update you later today. I hope this works this time. Otherwise, I will send you a picture of the components I used, for you to see clearly what is wrong. I do not have an oscilloscope, so I could not test the frequency.

    • Bugoy, If you do it correctly it will surely work.

      sending picture will not help, you'll have to troubleshoot it yourself, a frequency meter is what you will need in case you find the circuit not working…today all cheap DMMs include a the frequency measuring range so that shouldn't be a problem.

  17. Good day Sir!
    What I mean is the D5 sir, the 6A4 in the secondary output sir. What you mentioned before sir are the 4 diodes in the positive input to form a bridge rectifier. You did not mention about D5, the 5th diode in the secondary output. I do not know any 6A4 diode sir. What to replace it? Thank you.

    • Bugoy, your parts look correct…

      use 10k for both R1 and R2, this will bring down the frequency to a manageable 48kHz.
      increase the primary to 20 turns, keep the secondary section blank and measure the voltage across the primary, if you see a boosted voltage will confirm the correct working of the circuit, after this you can carry on with the secondary winding section.

  18. good day sir! Thank you. I will do what you said. Anyway, how will i wire up tip122? Because the first time i tried, it heats up. It seems the primary is shorting out the circuit, because if i remove the coil, tip122 stops heating up. Pin1 base, pin2 collector, pin3 emitter? The coil is already 20 turns sir. Now i will just remove the secondary. Will update you sir. Thank you.

  19. Good day Sir!
    I have an update for you Sir. I think I finally got it working. But the voltage in the secondary is so low, just a fraction of a volt. But when I connect an LED,it lights up. Also, the circuit is destroying 555. It destroyed two 555 already. Why is that Sir? The frequency across primary positive and collector pin of TIP122 is 35khz. My DMM has a frequency function. I used 10k for both R1 and R2. Thank you Sir for your help.

  20. hello sir! The TIP122 heats up so fast in just 25 seconds. Also, why is that the secondary output seems like AC. Because when i connect an LED, it lights up in either way, but one way seems brighter than the other. How will i know the positive and negative? Thank you sir.

    • hello Bugoy, add a few more turns to the primary, or add a heatsink to the TIP 122 for controlling its heating up.
      The one which is showing max brightness is the correct orientation, add the diode on the line corresponding to the anode of the LED.

  21. Good Day sir!
    I am now ready to wind my ferrite rod coil. I will make it 25 to 30 turns this time. A heatsink for TIP122 wont suffice. The heatsink gets so hot also. I used this kind of heatsink:

    I am hoping and praying that it will work this time with the ferrite rod. One more thing Sir, it destroys 555 when I add the diode to the anode position of brighter LED illumination.

    Here is a picture of it working with 4 LED. I didnt include the diode yet because it seems to be the culprit in the destruction of my two 555.

  22. Good day Sir!
    Hello. I was working on the circuit all day. Unfortunately, even the ferrite rod did not work Sir. It still make the TIP122 very hot. I put a pushbotton switch across positve so I could easily monitor TIP122's hotness. On the bright side of things, the circuit is working as intended, but for only a very short period of time (25 seconds max). But the true purpose of this is to power an alarm overnight. so I guess we-re back to the drawing board Sir. I am so sorry if I bothered you so much already. Thank you Sir.

  23. Good Day Sir!
    Thank you for your inputs. It really helped. I placed a pot and I can now lower the heat of TIP122 and also adjust the voltage output. I changed my toroid into a bigger one. The voltage range now is 3V to 18V. But there is one thing I noticed. Whenever I play with the pot, there is a spot where the circuit emits a buzzing sound? Like a bee sound Sir. It starts from low pitch up to a high pitch frequency. Where is it coming from Sir? Is that normal?
    As what you have said about a rechargeable battery, it is not possible due to space constraint Sir. I am really amazed on the outcome of our project. Just in case we can perfect this Sir, I would be grateful to send you something as a token of "thank you".

    • That's great Bugoy, positive results finally.

      The buzzing sound is normal, it indicates lowering of the frequency to an audible range, may be around 2kHz…try to reach a spot where this noise just disappears.

      Keep trying hard, success could be just round the corner:)

      I am sure others also might have learned a lot with your involvement here and the discussion between us…keep it up

  24. Good day Sir!
    How are you Sir? Finally the project is done. I have bad news and good news. The good news first Sir, the circuit is a success. it works as it should be. But the bad news is, it is not appropriate for the application that I want. The capacitive proximity sensor's stray capacitance affects the isolation properties of the isolated dc-dc converter. The capacitive proximity sensor stays triggered when used with the dc-dc converter. I am so sad. With all that effort and countless hours. But the good thing is, I learned so much about it. How transformer isolation works. It was my first time working with coils/transformers. Thank you so much Sir. A separate battery is really the only one solution.
    I have another request though Sir. I have another project in mind. It is about a wireless helmet brakelight. I know there are aftermarket version of it sold on ebay, but I want to create my own. I really like to create my own electronics for my own usage. I made a few several circuits that I got from your website/blogspot. And I am very proud using them. They are very helpful. And the feeling of using your own work is priceless. am thinking of hacking a wireless doorbell or a cheap remote controlled toy car to drive red LED that will be attached to the back of my helmet. But I do not know how to start. Maybe you could help me with the simplest wireless transceiver and receiver that could probably drive 4 to 6 red LED. Also I want the receiver to be as compact as possible for it to be fitted perfectly behind one of my helmet's foam padding. The tranceiver will be attached in parallel to my motorcycle's brakelight switch that operates in 12V.
    Thank you so much Sir.

    • Good day Bugoy, buck-boost converters or flyback converters are crucial circuits in the field of electronics and that's exactly what you learned in the course of the experiments and now you know well how to optimize these devices, this knowledge will help you whenever you come across such circuit stages in your experiments.

      A wireless brakelight helmet is an interesting project, but how would the commands be supplied to the transmitter for implementing the operations?? pleae specify in detail then we can start with it…

  25. Good day Sir!
    How are you? Yes, it was indeed a very interesting project. I am really an advocate of safety and security when it comes to my bike Sir. I wish you could se it soon. By the way, here are some links of an aftermarket product:

    I am thinking of hacking a wireless doorbell or a remote controlled toy car with lights. But I do not know how to do it. So I'm asking for your help Sir if you know of a simple RF tranceiver and receiver that could drive LED's.
    Here are some video links Sir:

    Thank you so much Sir.

  26. Good day Sir!
    Thank you. I guess it is similar to 12v remote switch as shown here:

    But should be more simple due to space constraint. The helmet padding provides a very tight flat space to hide the controller along with the batteries. The receiver module in the above product is a bit bulky due to the relays included. The above product's transmitter (remote) operates on a 12v battery which is ideal for vehicle supply. Thank you so much Sir.

    • Thanks Bugoy, yes I am aware of these units, and have published quite a few articles involving these ready made remote control devices,

      along with this option I would also include a DIY circuit having the same features as these units for the required application.

      I'll first finish the previous pending requests and then get busy with your request.

  27. Hello Sir! Thank you. Could you make it as simple as possible and parts should be very common. Because the electronics store here do not provide much items. Maybe the specs should be 4.5v supply for the receiver and 12v for the transmitter. Or maybe i could just use a voltage regulator such as LM78xx just in case your design for the transmitter require a lower voltage. But the receiver is best to be powered by a 4.5v supply such as 3 button cells or 3 AAA batteries. Thank you so much sir.

  28. Good Day Sir!
    I went out today Sir to look for a wireless doorbell. I have some not so good news Sir. The battery operated wireless doorbell is no longer available here in our country. It was replaced by the plug-in version as shown here:

    Only the remote switch runs on battery but the chime unit is already a wall outlet plug-in type. The salesperson told me that the battery operated version were already phased-out. The last time I saw them on stores here was way back 2010. The plug-in version now costs so much here, around 800 pesos or 1,096.59 indian rupee. What do I do now Sir?

  29. Good Day Sir!
    I went out today Sir to look for a wireless doorbell. I have some not so good news Sir. The battery operated wireless doorbell is no longer available here in our country. It was replaced by the plug-in version as shown here:

    Only the remote switch runs on battery but the chime unit is already a wall outlet plug-in type. The salesperson told me that the battery operated version were already phased-out. The last time I saw them on stores here was way back 2010. The plug-in version now costs so much here, around 800 pesos or 1,096.59 indian rupee. What do I do now Sir?

  30. Good Day Sir!
    How are you? As for the remote control unit Sir, it is not available here in out country. I do not have paypal or credit card to purchase online. Can you provide a similar circuit for it Sir? Im only relying on the availability of parts provided by the few electronics stores here in our place.
    Thank you so much Sir. Take care.

    • Good day Bugoy, buy a simple, cheapest FM wireless mic from market, I'll tell you how to proceed next.

      the mic should be compatible with an FM radio, meaning when spoken on mic the signal should be receivable on FM radios.

  31. Hello Sir! May i just ask, why cant we just build a simple fm wireless mic? I guess there are a lot of diagrams available and cheaper to build than to buy. But if the project calls for a ready-made unit, i will look for and buy tomorrow.

    • Hello Bugoy, yes you can make any suitable one, but the receiver will be a small FM radio, will there be enough space in the helmet to accommodate a small FM radio circuit??

  32. good day sir! Before i proceed with the project, i just want to know if the idea is foolproof? Will it not accept any interference from other vehicles with radio comm that may result in false triggering of the helmet brake light. Thank you sir.

    • good day Bugoy, until it's tried practically for many months nothing can be predicted about the design….cannot guarantee anything without practically testing it.

      The setting will need to be done on some free unused spot on the FM band of the radio in order to avoid false triggering as far as possible.

  33. Hello Sir, Good Day!
    How are you? its been so long, I really worked on the project but again, I cant make it work. Also, I have a question Sir. If I make two units of those wireless helmet brake light, and it was used by two riders at the same time side by side on the road, will it trigger the other and vise versa? Since it is the same basic circuit and frequency? How is that Sir? And Can you please take a look at this diagram of a remote control that I saw in the internet. What can you say Sir? The circuit is quite incomplete though. Im so frustrated. I think I failed the second time now. Thank you so much Sir for your help.

Leave a Comment