Newbie needs help with POT...


Closed Thread
Results 1 to 4 of 4
  1. #1

    Default Newbie needs help with POT...

    Hey guys, don't mean to be a bother with stupid questions, but I'm just getting started in PB and I want to get some code working.

    I'm working with a 16F628A running 20 mHz. I'm working on building a simple PWM motor controller that links the position of a pot to the HPWM duty cycle (if anybody has any code already written up for something like this, a link would be awesome).

    Anyway (this is probably the 1000th time or so that you've heard this), I'm looking for the best way to read the pot. I'm mainly looking at using the POT command, but I'm unsure what to use for the SCALE value. Is there a chart of some sort comparing pot values to scale values?

    Any help would be greatly appreciated. Thanks!

  2. #2
    Join Date
    Jul 2007
    Posts
    53


    Did you find this post helpful? Yes | No

    Default adcin maybe ?

    If your chip as ADC, then you should have a look at PBP ADCIN command.

    J-P

  3. #3
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,648


    Did you find this post helpful? Yes | No

    Talking POT Chart

    Hi,

    It exists one chart !!!

    The book is " Basic Stamp " from C.Kühnel and K. Zahnert ... Newnes publications. ( results are the same w/PbP ...)

    The "Optimum" setting is Scale @ 53 ... that gives a 200 units scale ( NOT 255 !!! , you'll never have 255 steps !!! )

    Now, there is a bad non linearity hard to avoid ...


    Soooooo, RCTime is MUCH,MUCH,MUCH better to use ... and an ADC is THE Linear solution !!!

    Alain

    PS: I've forgotten POT exists for about ... 10 years !!!
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Thanks guys. Don't know much about ADC, so I'll start reading up on it. Sounds like it's the way to go.

Similar Threads

  1. Using the Pot command.
    By timseven in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 17th August 2009, 20:23
  2. Can't get POT work on P12f675 - Newbie
    By berslan in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 26th March 2008, 21:22
  3. A/D, Pot, Input, A,B So lost now....
    By Helmutt in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 9th March 2008, 22:23
  4. Replies: 4
    Last Post: - 24th January 2007, 22:20
  5. pot controlled pwm -- help
    By docwisdom in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 29th January 2006, 12:29

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

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