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

    Can't enable external power on the PowerBus using the M5 Stack Core 2 using ESP-IDF.

    SOFTWARE
    2
    2
    1.7k
    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.
    • O
      oetzevandenbroek
      last edited by

      We are using the M5 Core 2 that has a stack layer with the SIM7600.

      We can't to power the M5 Core2 using the external power from the SIM7600 Layer.
      We are using the M5Unified libraries and are calling M5.Power.setExtPwr(true).

      When the USB isn't plugged in the device is constantly rebooting itself and making a ticking noise.

      We assume we have to enable the setPowerBus mode, but can't seem to get it working.

      How would we enable external power here?

      We are Using ESP-IDF as our build platform.

      1 Reply Last reply Reply Quote 0
      • felmueF
        felmue
        last edited by

        Hello @oetzevandenbroek

        I think you are close. Try M5.Power.setExtPwr(false). Below is how it is defined:

            /// Set power supply to external ports.
            /// @param enable true=output / false=input
            /// @param port_mask for M5Station. ext_port (bitmask).
            void setExtPower(bool enable, ext_port_mask_t port_mask = (ext_port_mask_t)0xFF);
        

        In your case you want to set it as input to the M5Core2.

        Thanks
        Felix

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

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