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

    IP in m5stack

    Core 2
    2
    6
    6.1k
    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.
    • J
      Javi
      last edited by

      Hi,

      How can I set a static IP to the device when I connect it to a wifi network ?

      Thanks.

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

        Hello @Javi

        try calling WiFi.config() before starting the network with WiFi.begin().

        See here for an example.

        Thanks
        Felix

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

        1 Reply Last reply Reply Quote 0
        • J
          Javi
          last edited by

          hi @felmue
          but that example only works for Arduino connection? I would like to do it in python.

          1 Reply Last reply Reply Quote 0
          • J
            Javi
            last edited by

            hi again @felmue
            Do you think there is any sense in using this in python "wifiCfg.wlan_sta.ifconfig()" setting the ip parametres inside the parenthesis?

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

              Hello @Javi

              yes, my suggestion is for Arduino. For Micropython I found this post.

              Thanks
              Felix

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

              1 Reply Last reply Reply Quote 0
              • J
                Javi
                last edited by

                Thank you @felmue I´ll try to use that.

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