Connect with us

rotary encoder to 2 pulsed outputs

Discussion in 'Microcontrollers, Programming and IoT' started by zmconcepts, Oct 22, 2020.

Scroll to continue with content
  1. zmconcepts

    zmconcepts

    8
    0
    Oct 16, 2020
    I have a rotary encoder that I would like to drive 2 relays with, so basically when the knob is turned clockwise it will pulse the clockwise relay on and off, and counter clockwise will pulse the counter clockwise relay on and off, and always leaving the outputs low when the knob is not moving, does anyone have input on a circuit that will do this?
     
  2. Bluejets

    Bluejets

    4,277
    908
    Oct 5, 2014
    Rotary encoders tend to have quite a few on-off cycles per revolution and if your knob is spun fast enough any standard relay would have trouble keeping up.

    Keeping track of direction is quite easily done with say, an Arduino but the above may need a rethink.

    Might be best to provide an overall description of what it is intended for.
     
  3. zmconcepts

    zmconcepts

    8
    0
    Oct 16, 2020
    Ok I see, I’m a 12v guy so I’m used to using relays for everything, but I am open to any other solution, this is a basic schematic of what I have, the device is an infrared remote control with volume + and - buttons that I am needing to pulse with an encoder
     

    Attached Files:

  4. zmconcepts

    zmconcepts

    8
    0
    Oct 16, 2020
    Also if the output is steady in either direction when the knob is moved fast is ok, it would be just like holding the button down continuously which will still work, I also have no knowledge of Arduino or programming so I was hoping for a circuit that I could build to accomplish this, thank you
     
  5. Harald Kapp

    Harald Kapp Moderator Moderator

    10,591
    2,360
    Nov 17, 2011
    Using a microcontroller such as an Arduino is probably the simplest solution - maybe not the easiest for beginners. But there are ready made libraries that make programming the Arduino for an encoder easy, see e.g. here.

    There are spezialized decoder ICs, e.g. this one or its brother, for rotary encoders. This may be what you are looking for: generate up and down pulses from the rotary encoders signal. The examples in the datasheet use the outputs of this IC to signal to a microcontroller or to a digital potentiometer. You may use the outputs of the IC to drive the input of your infrared receiver directly. The IC can be used in a wide range of operating voltages from 2.0 V to 5.5 V so it is well suited to be used with e.g. 2 × AA batteries.

    A flip-flop and a pair of logic gates or 2 flip-flops can do the same job, but additional circuitry may be required to debounce the input signals from the rotary encoder if you use a mechanical encoder.
     
  6. zmconcepts

    zmconcepts

    8
    0
    Oct 16, 2020
    Awesome that’s exactly what I’m looking for, let me see what I can come up with, thank you!
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-