Shop OBEX P1 Docs P2 Docs Learn Events
Potentiometer controlling variable — Parallax Forums

Potentiometer controlling variable

FarramanFarraman Posts: 5
edited 2009-12-26 17:04 in BASIC Stamp
I am wondering if there is a way to have a potentiometer control a single variable based on the position of the knob. I have a bs2 stamp and would like some help. Thanks.

Comments

  • LeonLeon Posts: 7,620
    edited 2009-12-26 13:01
    There is a technique for reading the value of a resistance in an RC circuit connected to a pin. Alternatively, you could use an ADC.

    Leon

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Amateur radio callsign: G1HSM
  • kf4ixmkf4ixm Posts: 529
    edited 2009-12-26 13:22
    Read the stampworks manual found here...

    http://www.parallax.com/Portals/0/Downloads/docs/books/sw/Web-SW-v2.1.pdf

    See page 40.
  • PJAllenPJAllen Banned Posts: 5,065
    edited 2009-12-26 13:44
    ???

    The "position of the knob" --·or the resistance there?

    You can "read" the value of a pot using the RCTIME command.· (That's in PBASIC Help.)
  • FarramanFarraman Posts: 5
    edited 2009-12-26 17:04
    I got it guys, thanks. And sorry for not fully exploring other means first, I just didn't know where to start. I'm kinda new
Sign In or Register to comment.