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.

How to keep a signal to high state?

Status
Not open for further replies.

engkeat

New Member
I am using two push on button as a limit switch, when i press the push button, it will send a signal to the controller, but the signal will cut off when unpressed.. is there any method to keep the signal to high-state when the push button is unpressed?
 
You can use a jk flip flop to make each press of the button trigger a state transition, or depending on the 'controller' you're talking about you may be able to change code to do it in software.
 
I am using two push on button as a limit switch, when i press the push button, it will send a signal to the controller, but the signal will cut off when unpressed.. is there any method to keep the signal to high-state when the push button is unpressed?

Generally, that is done with a resistor, called a pull-up resistor, connecting the input of the controller to the power feeding the controller. Some controllers have internal pull-up resistors when an I/O pin is configured as an input.
 
No ccurits he's trying to use momentary switches as latching switches. Pullups are not what the poster is looking for, unless they badly miss-stated their intention.
He wants the switch press to reverse the direction of the device, and a subsequent switch press at the other end to stop the device.
That's as I read it.
 
You say you have TWO N/O (Normally Open) push buttons on the limit end? (i.e. when pressed the contacts close hence applied voltage to the controller)

If the one switch is used for the ON latching and the other is to be used for the OFF latching, then that can be simply done in the controller (I assume this is a µController) by using the one input to Set an internal bit High, and the other to Reset.

The J-K flip-flop (mentioned by Sceadwian) can be used externally to the controller (where one switch will operate the "J" and the other the "K"). The Q will then be used as input to the µ

By wiring the J-K into a D-Latch, only one switch can be used for both the setting and resetting, but then the switch will have to be presses once to Set, and then be pressed again to "Reset"
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top