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

    Pymakr does not connect to LoPy using WiFi

    Scheduled Pinned Locked Moved Pymakr
    11 Posts 6 Posters 3.2k Views 6 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.
    • P Offline
      PatSenn
      last edited by

      I am experiencing the same problem. I am currently attached thru the USB and have been for 5 hours. The default WiFi address either connects and immediately drops out, or it never connects at all.

      1 Reply Last reply Reply Quote 0
      • R Offline
        Ralph
        last edited by

        Hi @robert-hh, @PatSenn,

        Do the two of you have any wifi connection code in the boot.py? You might have the same issue as in this topic, where I posted the solution (second response).

        Let me know if that solves it or if the problem remains.

        1 Reply Last reply Reply Quote 0
        • robert-hhR Offline
          robert-hh
          last edited by robert-hh

          I do not know what you want to tell me.
          If I start a session in Telnet, and then issue soft reset, the telnet session simply stalls. I guess
          that is what happens with pymakr. An here is in my boot.py:

          # boot.py -- run on boot-up
          import os
          from machine import UART
          uart = UART(0, 115200)
          os.dupterm(uart)
          

          What should I change or add?
          Update: Interestingly, it's the input to the device which get's locked. The output from lopy is still delivered.

          1 Reply Last reply Reply Quote 0
          • R Offline
            Roberto @robert-hh
            last edited by

            Hi @robert-hh,

            We released a new firmware version today that might help you with your problem since it includes several stability updates.
            Please download it at
            https://www.pycom.io/support/supportdownloads/
            and follow the instructions

            Best,
            Roberto

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

              @ralph Hi, our LoPy's connect over WiFi with PyMakr and 1.9.4.b1 without any issue until the 'Stacked Widget' error message appears in PyMakr. After that it seems to disconnect and refuse to reconnect again.

              1 Reply Last reply Reply Quote 0
              • robert-hhR Offline
                robert-hh
                last edited by robert-hh

                Hello @roberto,
                I tried this firmware already yesterday evening, when it was published. While it fixes the ftp issue, it does not fix the telnet issue. Telnet works until I push Ctrl.D for soft reset, the same pymakr does. After that, input to lopy is locked, but the output from lopy is still received. Closing telnet does not close the session, so I have to reset lopy.
                Regards, Robert

                1 Reply Last reply Reply Quote 1
                • P Offline
                  PatSenn
                  last edited by

                  I just tested it. I can attach through the COM port, but if I try 192.168.4.1, then I get "error communicating". If I hit reset and then try 192.168.4.1, it attaches for a moment then it gives "QStackedWidget::setCurrentWidget: widget 0x6a0a1e0 not contained in stack" followed by "error communicating.

                  1 Reply Last reply Reply Quote 0
                  • robert-hhR Offline
                    robert-hh
                    last edited by robert-hh

                    Hello @PatSenn and @Roberto, I do not get this message because:

                    a) I modified the file pyboard.py of pymakr (/usr/share/pymakr/modules/Plugins/PycomDevice/pyboard.py) in the telnet section at about line 290, such that the function keep_alive() always returns True. That allows a WiPy 1 with the recent firmware form the micropython site to deal with pymakr. It does not help with lopy, but may suppress the error message others receive (just the message).
                    b) Since pymakr is using a telnet session, I'm testing with a simple telnet client. You may use the command line telnet version or for instance putty. That is a simple and robust set-up. pymakr may have it's own bugs too.

                    1 Reply Last reply Reply Quote 0
                    • FridaF Offline
                      Frida
                      last edited by Frida

                      On serial it works ok, but on wifi I get:

                      Exception in thread Thread-1:
                      Traceback (most recent call last):
                        File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
                          self.run()
                        File "/usr/lib/python2.7/threading.py", line 754, in run
                          self.__target(*self.__args, **self.__kwargs)
                        File "/usr/share/pymakr/modules/Plugins/PycomDevice/pyboard.py", line 110, in on_timer
                          callback()
                        File "/usr/share/pymakr/modules/Plugins/PycomDevice/pyboard.py", line 446, in _keep_alive
                          self.__disconnected_callback(Pyboard.LOST_CONNECTION)
                      AttributeError: Pyboard instance has no attribute '_Pyboard__disconnected_callback''
                      

                      on latest software

                      1 Reply Last reply Reply Quote 0
                      • R Offline
                        Ralph
                        last edited by

                        hi @robert-hh, @Frida, After robert posted his response here an hour ago, I went on to do some tests and found that a telnet session (from terminal) indeed gets stuck after a soft reboot. The same thing over serial works fine. It happens on the latest firmware versions of both the lopy and wipy2. So it's definitely a but on the firmware side. Since Pymakr is sending soft reboots on connect, this is causing the connection issue with a lot of people. We'll try to find a solution asap.

                        We started reporting the issues on github. You can find and subscribe to update for this issue here

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

                        Pycom on Twitter

                        Pycom