Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 6 of 6

Thread: Coarse and fine control with a single encoder

  1. #1
    Junior Member
    Join Date
    Nov 2012
    Location
    Tasmania
    Posts
    17

    Coarse and fine control with a single encoder

    Using Teensy boards to build flight simulator interface hardware, I normally use two encoders - one for coarse changes, one for fine changes. For example, to set a heading, I have one encoder making 4° changes and another making 0.25° changes. This allows the setting to be made rapidly and with precision. But it's expensive of space - real aircraft use things like continuous-rotation 4-pole rheostats which allow rapid changes and precision to be accomplished with a single control. I'm not sure if anything like that is cheaply available for the electronics enthusiast?

    My idea is to use a single encoder, making coarse changes each time it's turned to a new detent. But if the encoder is only pushed partially, against the detent spring pressure, the sketch will apply continuous slow changes to the control.

    So to change a heading selection from 30° to 44.2°, I'd click clockwise through three detents to advance by 12 degrees to 42°. Then gently 'push' the encoder clockwise to slowly and gradually advance to 44.2°ish.

    Has this been done before? Encoders with stronger detent spring pressure will be easier to use with this technique obviously. I'll experiment with this tonight.

  2. #2
    Member
    Join Date
    Dec 2012
    Location
    Adelaide, SA
    Posts
    70
    I'd be surprised if you can reliably detect (momentary) motion between detents, but keep us posted.

    Alternatively, what about applying some sort of velocity-based non linearity, like mouse-acceleration say. Rotate the encoder fast, and it will make courser adjustments, where slow deliberate clicks will make smaller changes?

  3. #3
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    20,323
    The Agilent oscilloscopes use that velocity-based approach. Spin slowly for fine adjust, for faster for coarse.

  4. #4
    Junior Member
    Join Date
    Nov 2012
    Location
    Tasmania
    Posts
    17
    That's a good idea too. I'll check there isn't already an Arduino class for this, it seems like there ought to be one.

  5. #5
    Junior Member
    Join Date
    Feb 2013
    Posts
    19
    Maybe an encoder with a push switch like so:
    http://www.mouser.com/Search/Product...EC11-4220F-S24
    Use a switch push to change a state. You start in coarse adjustment mode, push the switch and you are in fine adjustment mode. Push the switch again for coarse adjustment mode. I'm doing something similar in my current project, using a push switch encoder to change modes so I get double-functionality out of encoder knobs.

  6. #6
    Junior Member
    Join Date
    Nov 2012
    Location
    Tasmania
    Posts
    17
    Ah yes, I have similar encoders. My current setup has two pushbutton encoders and a 16x2 LCD. The left encoder is coarse changes, the right encoder is fine changes, and clicking on the left or right encoder buttons (or both together) cycles through a list of different things the encoders can control. I'd forgotten, if it was a single-function encoder, I could just use the button to change sensitivity.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •