How to keep a signal to high state?

Discussion in 'The Projects Forum' started by engkeat, Apr 10, 2009.

  1. engkeat

    Thread Starter Member

    Aug 18, 2008
    11
    0
    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?
     
  2. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,347
    Hello,

    Do you want High state when the switch is NOT pressed and Low state when the switch is pressed ?
    Use a resistor to pull the pin of the micro high, and a contact closure to ground will give the low state.
    A resistor between 1K and 10K will do.

    Greetings,
    Bertus
     
  3. beenthere

    Retired Moderator

    Apr 20, 2004
    15,815
    282
    That isn't much to work with, but a resistor to Vcc may be able to maintain the high state at the input. 20 -47K would work for CMOS, 4.7K for TTL.
     
  4. RiJoRI

    Well-Known Member

    Aug 15, 2007
    536
    26
    Look into R-S latch or J-K flip-flop. The R-S will stay in one state from the time one button is pressed until the time the other button is pressed. The J-K will change state on every button press.

    And don't forget buttons bounce.

    --Rich
     
  5. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    It would help us to help you better if you would explain more completely what it is that you are trying to do.

    Can you post a schematic diagram of your circuit as it is? .PNG format images work well, as they are not "lossy" like .jpg format images are.
     
  6. Wendy

    Moderator

    Mar 24, 2008
    20,766
    2,536
    .gif works well too, though the colors can shift in them.
     
Loading...