🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    M5StampS3:GPIO3 Analog input don't work

    Scheduled Pinned Locked Moved Modules
    3 Posts 3 Posters 1.7k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G Offline
      gohan_oishii
      last edited by

      I am using the analogue input with the M5Stamp S3, but GPIO3 is constantly outputting 4095.
      Other outputs give the correct values.
      I use Arduino IDE 2.3.3, and the code is

      void setup() {
        Serial.begin(115200); 
        for(int i=1;i<=15;i++){
            pinMode(i,ANALOG);
        }
      }
      void loop() {
          
         int index = 0; 
      
        for (int pin = 1; pin <= 15; pin++) {
          v[index] = analogReadMilliVolts(pin); 
          Serial.print(String(v[index]));
      
          if (index < 13) { 
            Serial.print(",");
          }
      
          index++; 
        }
      
        Serial.println(); 
        delay(1000);
          
      }
      
      
      
      
      felmueF teastainT 2 Replies Last reply Reply Quote 0
      • felmueF Online
        felmue @gohan_oishii
        last edited by

        Hello @gohan_oishii

        GPIO3 on the ESP32S3 is a strapping pin (see here) and is pulled up via external 10 k resistor (see schematic here).

        Thanks
        Felix

        GPIO translation table M5Stack / M5Core2
        Information about various M5Stack products.
        Code examples

        1 Reply Last reply Reply Quote 0
        • teastainT Offline
          teastain @gohan_oishii
          last edited by teastain

          This post is deleted!
          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • First post
            Last post