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

Thread: Connecting 100K Trim pot to Teensy 3.6

  1. #1
    Junior Member
    Join Date
    Feb 2020
    Posts
    3

    Connecting 100K Trim pot to Teensy 3.6

    I would like to connect a 100K trim pot to my teensy 3.6 but I read that the 3.3V pin can only handle 250mA max. If the resistance is set to the lowest, will it cause an over current draw?

    I was planning to hook up from left to right: 3.3V , A0 , GND.

    This was the code I was planning to use:

    Code:
    void setup()
    {                
      Serial.begin(38400);
    }
    
    int val;
    
    void loop()                     
    {
      val = analogRead(0);
      Serial.print("analog 0 is: ");
      Serial.println(val);
      delay(250);
    }

  2. #2
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,115
    No worries on the current. No significant current flows into the Teensy pin when it's an analog input. So the only current is 3.3V / 100Kohm, which is only 33 uA.

    But 100K is a little on the high side. Teensy's analog inputs want lower impedance. Best to use 10K or 5K pots if you can. Otherwise, if the readings are too noisy, try adding a ceramic capacitor between the analog input pin and AGND. Values between 470 pF to 0.1 uF usually help.

  3. #3
    Junior Member
    Join Date
    Feb 2020
    Posts
    3
    Quote Originally Posted by PaulStoffregen View Post
    No worries on the current. No significant current flows into the Teensy pin when it's an analog input. So the only current is 3.3V / 100Kohm, which is only 33 uA.

    But 100K is a little on the high side. Teensy's analog inputs want lower impedance. Best to use 10K or 5K pots if you can. Otherwise, if the readings are too noisy, try adding a ceramic capacitor between the analog input pin and AGND. Values between 470 pF to 0.1 uF usually help.
    Thank you for your quick reply! I will obtain a 10K or 5K pot for my circuit. I can use either AGND or GND as the grounding point for my setup?

  4. #4
    Senior Member PaulStoffregen's Avatar
    Join Date
    Nov 2012
    Posts
    22,115
    Either will work. AGND sometimes gives lower noice performance for analog circuits. Always use regular GND for digital stuff. AGND is meant for sensitive analog.

  5. #5
    Junior Member
    Join Date
    Feb 2020
    Posts
    3
    Quote Originally Posted by PaulStoffregen View Post
    Either will work. AGND sometimes gives lower noice performance for analog circuits. Always use regular GND for digital stuff. AGND is meant for sensitive analog.
    Ok Thank you!

Posting Permissions

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