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

    100% battery is useless if your device isn't on

    M5 Stick/StickC
    2
    3
    31
    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.
    • M
      michael.koppelman
      last edited by

      I really love the M5 Stack. But then you run across things really hard to understand. Like, I dunno, this:

      You must set GPIO4 high within 100ms of the device powering on.
      If your code has delays before setting the pin, the device will
      shut down.
      

      So if you are powering down with 100% battery, it's BY DESIGN.

      Your first two lines in setup() must be:

      pinMode(4, OUTPUT);
      digitalWrite(4, HIGH);
      

      They are going to protect that battery even if they have to halt your code.

      easytargetE 1 Reply Last reply Reply Quote 0
      • easytargetE
        easytarget @michael.koppelman
        last edited by

        @michael-koppelman
        Maybe It's a form of watchdog that guards against the device powering on and then pointlessly flattening the battery while doing nothing because there is no code running. It protects the battery against wasted charge-cycles.
        Or maybe it's just a 'feature' of the power control circuit. ;-)

        M 1 Reply Last reply Reply Quote 0
        • M
          michael.koppelman @easytarget
          last edited by

          @easytarget Yes, that's exactly what it is. Which is what I disagree with! :)

          No other M5 device I'm aware of defaults to turning off. It's a terrible design decision and one that should exclude the Stick from consideration for anything that needs reliable, temporary battery power from the internal battery. You cannot rely on this thing staying on, regardless of how you interact with the "HOLD" pin.

          It works fine under any form of external power. The internal battery is useless.

          Which is sad because my use case was that when an external power source failed, it would go to the internal battery and software would notice the decline in voltage and alert. If your reboot took 110ms, instead of the normal 90ms (arbitrary, wrong), you are down.

          Just my opinion!
          M.

          1 Reply Last reply Reply Quote 0
          • First post
            Last post