Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

manual switch prob

Status
Not open for further replies.

jm1

New Member
im a college student. we just finished lecturing, and making a basic op amp (used as a comparator) ckt.as a final proj,we were given a circuit today,(by ouir prof) that concerns manually turning on-and-off a switch and counting the # of times we turned it "on".the circiut is a manual operated voltmeter; an led lights up when the right value of the counter is reached.The counter will indicate the value of the the voltage measured by the voltmeter.anyway, our prof told us that we should anticipate a prob in the switch.. that is, there is a tendency that whenever the switch is pressed(and released), the conductor unnoticebly,bounces and hits the other conductor, creating two(or more) counters instead of one.we(group project) havent really started the proj yet so im not yet sure if this is really a or will be a prob.

is there a circuit/component/advice/site that might help us in this prob?

just a an followup question:what does a 4bit counter do?ive seen so many data sheets; what is synchronous and asynchronous?its just that we're having trouble picking the right 4bitcounter for the ckt.tnx
 
It sounds like the problem is to determine what the count is. Well, you sure don't have to build the circuit to get that information. If the LED is connected to count pin #3, your count number is 4 (I'm not sure why but the first count is usually called "0")

Anyway, counters are perfectly accurate ASSUMING you have a perfect signal (e.g., a square wave). A really good push button with sealed contacts will give you a fighting chance of success but a cheap switch with exposed/corroded contacts . . . forget it. What happens is that as you press a switch and the plunger moves down, it may actually make and break several times before it bottoms out - the counter chip sees each of these "makes" as a pulse to be counted.

I have never tried it (because counters are made to be driven by pulse generators - not push buttons) but I believe you can minimize bounce by placing a capacitor across your push button leads.

Would like to know what college you are attending...
 
What you're saying is that you need to "debounce" the switch. You can do this with a 555 configured as a monostable vibrator, a.k.a. "one shot". You get one pulse for each press of the button or flip of the switch. This circuit may be useful:**broken link removed**
 
you can also use a resistor capacitor, wich will trigger the ciruit nd hold the bit at H for some time so in case you have a short time disconnect due to the sw, it will not sense it. but this has also got disadvantages. the 555 version too.
anyway, what do you turn on with the sw?
you can use a photo resistor of you use the sw to turn on a lamp, and it will not be boddered by the old sw problem.
or, another solution, get another sw. :)
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top