Capacitive touch button behind LCD screen

Go To Last Post
30 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 1

Hi guys

 

i have recently built a speedometer (version 2) with an LCD display driven by a LCD driver chip and a microcontroller (atmega168). All the electronics are small and compact to all fit behind the LCD.

 

The Speedometer will only have two functions

1. show speed

2. distance.

 

To change between either showing speed or distance i had an idea of using a capacitive touch pad behind the LCD so that you could just effectively touch the screen and the function switches from one to the next. I would like to hear your opinions on this idea? will it work? will the electronic signals behind the pad cause false triggers? Do you guys thing the capacitance of the copper pad behind the screen will change enough to detect it if someone puts their finger on the screen?

 

I am shying away from using a mechanical button because i want a sleek looking LCD and to have a "touch screen" speedometer will be awesome. Here are two pictures of the speedometer. the one is before the LCD was mounted and the other one with the LCD mounted. There is enough space for the capacitive pad pcb to be sandwiched between the LCD and the electronics.

 

As for the coding part i was planning on using an RC network and measuring the time constant to charge or discharge the touch capacitor and toggling to switch between functions when the capacitance is above a certain limit above what the idle capacitance would be. i have just been reading about this and it seams possible but i will need to approach this is small steps.

 

Any suggestions?  

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Bump?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Don't be so bloody impatient!

 

Atmel sells small avr's pre-loaded with a touch interface, and output(s)

 

Look here:

http://www.digikey.com/product-s...

 

For one button I suggest this route.  Qtouch is a pain in the butt.

 

JIm

 

And do not 'bump' again....angry

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thank you I will order one of those chips. I have one question regarding the application of the chips though. On the application diagrams in the data sheet they show a copper pad as the touch sensor then just bellow it is a capacitor named Cx. Is this the capacitance of the copper pad? Or must you add an additional capacitor to ground? My apologies for bumping. Will never do that again.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The datasheet says that there is a sample cap(Cs) of 2nF to 20nF, and a resistor(Rs).

 

If memory serves me correct, Cx is the capacitance of the pad itself.

 

There are app notes on using these devices.

 

JIm

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I, for one, will be surprised if it works reliably. Please post back when you've proved me wrong!

 

Four legs good, two legs bad, three legs stable.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I would sooner make a thin metal bezel around the LCD to use as the capacitive sensor.

"Experience is what enables you to recognise a mistake the second time you make it."

"Good judgement comes from experience.  Experience comes from bad judgement."

"Wisdom is always wont to arrive late, and to be a little approximate on first possession."

"When you hear hoofbeats, think horses, not unicorns."

"Fast.  Cheap.  Good.  Pick two."

"We see a lot of arses on handlebars around here." - [J Ekdahl]

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

joeymorin wrote:

I would sooner make a thin metal bezel around the LCD to use as the capacitive sensor.

 

Thats a really good idea i will try this. i got the Qtouch chips so this weekend i will be experimenting

 

John_A_Brown wrote:

I, for one, will be surprised if it works reliably. Please post back when you've proved me wrong!

 

 

i am hoping i can prove you wrong;)

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What you want is some ITO (indium tin oxide) film. It's conductive and see through. Something like a resistive touch screen, but only one layer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What you want is some ITO (indium tin oxide) film. It's conductive and see through. Something like a resistive touch screen, but only one layer.

An even better idea.  Bonding it to the LCD to keep out dust might prove challenging, though.

"Experience is what enables you to recognise a mistake the second time you make it."

"Good judgement comes from experience.  Experience comes from bad judgement."

"Wisdom is always wont to arrive late, and to be a little approximate on first possession."

"When you hear hoofbeats, think horses, not unicorns."

"Fast.  Cheap.  Good.  Pick two."

"We see a lot of arses on handlebars around here." - [J Ekdahl]

 

Last Edited: Fri. Apr 8, 2016 - 02:58 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Seams like its working. Cant say for sure as everything has not been put together yet but those Qtouch Atmel chips that jgmdesign suggested work a treat. They work so consistently even behind the LCD when it is displaying digits and changing digits. I am just etching a board (taking some time because the traces are 0.1mm) then I am going to re-flow everything and put it together to see if it works.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Personally, I look forward to seeing photos of how you have achieved this.

 

Cheers,

 

Ross

 

Ross McKenzie ValuSoft Melbourne Australia

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

0.1mm tracks! You'd pay premium for a board house to make that. Less than 0.15mm is getting towards the limit of manufacturability.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Russell, I read Calvin's post to mean that he is doing the etching... yes 4mils is very specialised. But maybe I have misread it.

Ross McKenzie ValuSoft Melbourne Australia

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ross, that's my point - trying to home etch tracks so thin. 0.4mm is more achievable. Etching a bit of ITO film would be much easier - the lines geometries would be in mm.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm have etched 0.08mm tracks at home before but it's not consistent at all. 0.1mm is also not consistent but I have done it. 0.15 is relatively consistent but this speedometer I'm making there is just no space and I need to do 0.1mm. I've already flopped 5 or 6 pcb's so far but they so small it's just costing me time of which I have plenty. No rush. I will post pictures when I'm done. The main thing I struggle with when doing such small traces is the gap between the traces. The UV light does not get to the photoresist in between closely spaced traces, or should I say that area doesn't get exposed enough.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

As noted you might want to look at having a PCB house do them for you.  you can get 5 made for very reasonable fees.

 

JIm

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

jgmdesign wrote:

As noted you might want to look at having a PCB house do them for you.  you can get 5 made for very reasonable fees.

 

JIm

 

This is true, it is almost not worth making them yourself. its cheaper getting a PCB house to do it for you then you get 100% masked, marked tested boards. Having said this i have already made an exposure box and an etching tank etc so i may as well just use it to play around. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

valusoft wrote:

Personally, I look forward to seeing photos of how you have achieved this.

 

Cheers,

 

Ross

 

 

So I got a PCB etched and populated this weekend, unfortunately the touch capability is not sensitive enough. it works if I put my hand on the LCD touching the whole screen but does not pickup just your finger. What I will do now is increase the Cs capacitor from 10nf to 33nf. By doing this the sensitivity will increase as per the Qtouch data sheet. I will try this and hopefully it works. The LCD did not falsely trigger the Qtouch circuit which is good news but it might now that I am going to make it more sensitive but I guess the only way to really know is testing it so back to step 1 for me.

 

I will report again when i'm done. I also noticed that my LCD was connected incorrectly so the seven segments were not displaying correctly. i will need to make another PCB now fixing this along with changing the Cs cap value.

Last Edited: Mon. Apr 18, 2016 - 09:08 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Here are some pictures, you can see the copper pad I put behind the screen. I think what might also help is if I superglue the copper pad to the back of the screen next time.

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So i got another speedometer built this weekend and unfortunately it doesn't work:( strangely though it works when i disconnect the TSOP IR receiver. So i am guessing the IR receiver creates too much noise for the Qtouch chip to actually work. It was fun doing all of this. I have refined my etching process to get finer tracks more reliably so at least that was good news.

 

I have another plan though, I am hoping you guys can give me your opinions though if this would work or not. I want to connects a small piece of wire to a transistor base so that when you touch the wire then a uC pin will see HIGH or LOW. I might need to connect two in a darlington pair to be sensitive enough or something.

 

"What you want is some ITO (indium tin oxide) film" this film is unfortunately not available to me so i cannot use it. As a last resort I guess i will need to use an actual mechanical button. But i am hoping my transistor idea will work. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You'd be surprised where you can find ITO film. It is also pretty cheap. 

Another alternative is window film - some of these are conductive.

Why would you need a transistor when the input to the micro is much high impedance? Use a 10M resistor from port pin to 0V. Touch that and see what happens.

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Kartman wrote:
Why would you need a transistor when the input to the micro is much high impedance? Use a 10M resistor from port pin to 0V. Touch that and see what happens.

 

I will do this and see what happens. Thanks for the idea.

 

The reason why i wanted to use a transistor or thought i need to use a transistor was because i thought my finger touch will not create a high enough voltage to sufficiently turn on the port pin. Now that i actually sketched it out i see that i would actually need to use a PNP transistor to let the port pin see a high 5v when i touch the wire. but then again you need to ground the base for the PNP transistor to come on.

 

I believe that your method would work but i do not understand how it will work. I will def do it and see what happens. 

 

Here is a sketch of what i wanted to do which now does not make sense 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The circuit makes more sense than using a pnp. You can use the internal pullup. Have you ever put your finger on the probe for a oscilloscope? You normally get quite a few volts. So my suggestion has a better chance of working than yours. In the olden days we used 4000 series cmos chips for touch switches. Since the AVR is cmos, then no need for a transistor. You can even breathe on the AVR and detect it with a floating input.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Kartman wrote:
The circuit makes more sense than using a pnp. You can use the internal pullup. Have you ever put your finger on the probe for a oscilloscope? You normally get quite a few volts. So my suggestion has a better chance of working than yours. In the olden days we used 4000 series cmos chips for touch switches. Since the AVR is cmos, then no need for a transistor. You can even breathe on the AVR and detect it with a floating input.

 

Ok that is great news thanks Kartman. By just using the uC pin i will also reduce the amount of parts i use which will help me layout the pcb easier. So just to clarify i must use a 10M resistor to a PORT Pin set as input floating? or to ground?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The 10M from port pin to 0V to stop it floating. 1M might work also. You want to stop the pin from floating so you don't falsely trigger but not provide too much of a load to stop it from working.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Alright i understand thanks, i will try this and report back how it went. 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

So it works perfectly with a 10M resistor. Thanks Kartman! One question, this works and is extremely simple so why bother with a capacitive touch? I mean the methods are different but the results are simular. I used a 100M and it became very sensitive like I would just wave my hand passed the wire and it would register a HIGH, obviously got false triggers as well and remained HIGH for some time before registering LOW.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The capacitive touch methods work better with insulators.
100M is getting towards the leakage resistance of your circuit. Consider the time constant when the pin input capacitance is around 5pF.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

How are you going to deal with condensation?

#1 This forum helps those that help themselves

#2 All grounds are not created equal

#3 How have you proved that your chip is running at xxMHz?

#4 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand." - Heater's ex-boss