Welcome to the Pycom forum Forum
    • \[\[global:header.categories\]\]
    • \[\[global:header.recent\]\]
    • \[\[global:header.tags\]\]
    • \[\[global:header.popular\]\]
    • Login

    Explore Pybytes | Official Documentation | Report a Firmware Bug/Issue | GitHub

    How to set a dhcp_hostname for a lopy in station mode.

    Scheduled Pinned Locked Moved LoPy
    pycommicropython.org
    12 Posts 7 Posters 3.1k Views 7 Watching
    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.
    • B Offline
      bucknall
      last edited by

      Hi @Andy12,

      Currently this isn't possible from our MicroPython Library. This feature (updating the device Hostname) is available through the Espressif IDF so we will be adding it in the near future! Thanks!

      Developer Evangelist - Pycom

      Charly86C 1 Reply Last reply Reply Quote 0
      • A Offline
        Andy12
        last edited by

        @bucknall Thank you. I hope this feature will be implemented soon because:

        1. It is difficult to identify the lopy's hostname eg if 5 of them are connected to the same router.
        2. Socket.getaddrinfo function returns random ip if wlan.ifconfig() is configured with static parameters instead of DHCP.
        B 1 Reply Last reply Reply Quote 0
        • B Offline
          bucknall @Andy12
          last edited by

          @Andy12 I 100% understand where you're coming from! I run into these issues as well - will keep you updated to any developments - shouldn't be too long as they are already available through the Espressif IDF!

          Developer Evangelist - Pycom

          1 Reply Last reply Reply Quote 0
          • I Offline
            illysky
            last edited by

            I know this is a bit late, but thought I'd share, I also needed to change the hostname appearing on my dhcp server, so I have forked pycom's repo and adjusted the WLAN class to accept "hostname" on instantiation.

            It adds a name to the underlying NETIF whether AP or STA.

            illysky/pycom-micropython-sigfox

            Just build as per pycom's instructions.

            Have a great day

            Dom

            Charly86C A sebS 3 Replies Last reply Reply Quote 1
            • Charly86C Offline
              Charly86 @illysky
              last edited by

              @illysky great, hoping to see it soon in official firmware ;-)

              1 Reply Last reply Reply Quote 0
              • A Offline
                Andy12 @illysky
                last edited by

                @illysky Thank you for the update

                1 Reply Last reply Reply Quote 0
                • sebS Offline
                  seb @illysky
                  last edited by

                  @illysky said in How to set a dhcp_hostname for a lopy in station mode.:

                  illysky/pycom-micropython-sigfox

                  Could you do a pull request and we can hopefully get this merged into the official firmware

                  1 Reply Last reply Reply Quote 0
                  • I Offline
                    illysky
                    last edited by

                    Hi, I’ve sent a pull request. Cheers, Dom

                    1 Reply Last reply Reply Quote 1
                    • Charly86C Offline
                      Charly86 @bucknall
                      last edited by

                      @bucknall does this feature is available? Can't find on documentation

                      J 1 Reply Last reply Reply Quote 0
                      • J Offline
                        jmarcelino @Charly86
                        last edited by

                        Hi @charly86
                        It's not there yet

                        1 Reply Last reply Reply Quote 0
                        • T Offline
                          Thosch42
                          last edited by

                          Just to bring it back on the workbench ;-)
                          What are the plans to implement this feature?

                          Cheers,
                          Thomas

                          1 Reply Last reply Reply Quote 1

                          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
                          • 1 / 1
                          • First post
                            Last post

                          Pycom on Twitter

                          Pycom