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 Atom Plugin released

    Scheduled Pinned Locked Moved Announcements & News
    pymakrpluginatom
    91 Posts 29 Posters 63.5k Views 26 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.
    • RobTuDelftR Offline
      RobTuDelft @RobTuDelft
      last edited by

      @RobTuDelft To update on my own post, it did manage to connect today. After that I tried some commands and clicked 'close' to close the panel in Atom. This seems to be the source of the problem, the telnet connection will stay active on the Lopy, but not in Atom. When you want to reopen again you will get the password timed out error.

      Without data you're just another person with an opinion.
      Hackster | About me

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

        @RobTuDelft Normally if a connection is still active to the device, you'll get a connection refused. if you get a 'password timed out' means that it reaches the device but something goes wrong during authentication. I've had this error a lot when the router at our office was not cooperating well and it just timed out. I'll do some testing on telnet today to see if I can reproduce it.
        Which firmware version do you have running on your lopy?

        RobTuDelftR 1 Reply Last reply Reply Quote 0
        • RobTuDelftR Offline
          RobTuDelft @Ralph
          last edited by

          @Ralph v1.6.12.b1. Thanks.

          Without data you're just another person with an opinion.
          Hackster | About me

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

            0_1492162908815_upload-2710d56b-9b6e-4793-9d8c-04c7a5c238f9

            Here are the errors:

            Failed to load the Pymakr package
            Cannot find module 'serialport'
            Hide Stack Trace
            Error: Cannot find module 'serialport'
            at Module._resolveFilename (module.js:455:15)
            at Module._resolveFilename (/Applications/Atom.app/Contents/Resources/electron.asar/common/reset-search-paths.js:35:12)
            at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app.asar/src/module-cache.js:383:52)
            at Function.Module._load (module.js:403:25)
            at Module.require (module.js:483:17)
            at require (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:50:27)
            at Object.<anonymous> (/Users/robincole/.atom/packages/Pymakr/lib/connections/pyserial.js:4:16)
            at Module._compile (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:109:30)
            at Object.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:216:21)
            at Module.load (module.js:473:32)
            at tryModuleLoad (module.js:432:12)
            at Function.Module._load (module.js:424:3)
            at Module.require (module.js:483:17)
            at require (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:50:27)
            at Object.<anonymous> (/Users/robincole/.atom/packages/Pymakr/lib/board/pyboard.js:3:34)
            at Module._compile (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:109:30)
            at Object.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:216:21)
            at Module.load (module.js:473:32)
            at tryModuleLoad (module.js:432:12)
            at Function.Module._load (module.js:424:3)
            at Module.require (module.js:483:17)
            at require (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:50:27)
            at Object.<anonymous> (/Users/robincole/.atom/packages/Pymakr/lib/main.js:7:21)
            at Module._compile (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:109:30)
            at Object.value [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/compile-cache.js:216:21)
            at Module.load (module.js:473:32)
            at tryModuleLoad (module.js:432:12)
            at Function.Module._load (module.js:424:3)
            at Module.require (module.js:483:17)
            at require (/Applications/Atom.app/Contents/Resources/app.asar/src/native-compile-cache.js:50:27)
            The error was thrown from the Pymakr package. This issue has already been reported.
            View Issue

            R 2 Replies Last reply Reply Quote 0
            • R Offline
              Ralph @robmarkcole
              last edited by

              @robmarkcole This is the error you get when anything goes wrong during installation of the dependencies, either of the serialport library or somewhere else during installation. If you remove the node_modules folder, the serialport library is the first one it will encounter and throw this error.

              I noticed that everybody who got this error is on Atom 1.16, while I'm still on Atom 1.15 (on El Capitan). Possibly there is a compatibility issue there, which I'll check out.

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

                @robmarkcole This issue has been solved in this github issue. The problem is that for some users, atom is using python 3.x while the compiler for serialport needs python 2.x (you can check it using apm --version).

                I've added an explanation on the bottom of the readme file in the develop branch on github. The short story is, until we've automated it, the issue is solved by running the folling command and then re-installing Pymakr.

                echo "python=/usr/bin/python2.7" >> ~/.atom/.apmrc

                R mmbermudezaM 2 Replies Last reply Reply Quote 2
                • R Offline
                  robmarkcole @Ralph
                  last edited by

                  @Ralph Thanks Ralph, working now!

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

                    @Ralph There is an error in your getting started doc, WLAN has not been imported. Is there a better way to provide this kind of feedback, e.g. Github? Cheers

                    0_1492236162455_upload-b6ef2a46-a893-4ee6-8582-c8a24c57dd4f

                    https://docs.pycom.io/pycom_esp32/pycom_esp32/getstarted.html#creating-a-project

                    B 1 Reply Last reply Reply Quote 1
                    • B Offline
                      bucknall @robmarkcole
                      last edited by

                      @robmarkcole thanks! We'll get this fixed :)

                      Developer Evangelist - Pycom

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        smssms @robmarkcole
                        last edited by

                        @robmarkcole

                        +1 for this error (on Linux Mint 18 64-bit). I've tried all the solutions listed but they did not work.

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

                          Been getting a strange error after Atom loses connection to my board (e.g. when I sleep my mac):

                          0_1492333353906_upload-37d0f0db-22aa-42db-9387-3d8074ef0211

                          TypeError: _this.view.synchronize is not a function
                          at atom-workspace.pymakrSynchronize (/Users/robincole/.atom/packages/Pymakr/lib/main.js:21:45)
                          at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:259:29)
                          at CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:3:59)
                          at CommandRegistry.module.exports.CommandRegistry.dispatch (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:160:19)
                          at AtomEnvironment.module.exports.AtomEnvironment.dispatchApplicationMenuCommand (/Applications/Atom.app/Contents/Resources/app.asar/src/atom-environment.js:1179:28)
                          at EventEmitter.outerCallback (/Applications/Atom.app/Contents/Resources/app.asar/src/application-delegate.js:312:25)
                          at emitThree (events.js:116:13)
                          at EventEmitter.emit (events.js:194:7)

                          Upon reconnection I not see the option to sync my code:

                          0_1492333417576_upload-94a8e32c-3345-47b0-8c5f-23742e51af53

                          However upon restarting Atom everything is normal again.

                          0_1492333499708_upload-6fc324dd-b00f-4f36-967d-c3c85cff0120

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

                            V0.9.3 has been released with some minor fixes:

                            • Improved sync stability and speed over serial
                            • Solved disappearing line in terminal (github issue #3)
                            • Other small bugfixes
                            • Logger class for easier debugging
                            1 Reply Last reply Reply Quote 2
                            • R Offline
                              Ralph @robmarkcole
                              last edited by

                              @robmarkcole Thanks for the report, it was simply a wrong method name in the handling of the short-key ctrl-alt-s to do a sync. It has been fixed in the development branch on github and will be included in the next release. Unfortunately I released 0.9.3 today just before reading about your issue, so it'll be in 0.9.4 in a few days.

                              The missing sync and run button are a known issue, which I'm still investigating

                              1 Reply Last reply Reply Quote 1
                              • mmbermudezaM Offline
                                mmbermudeza @Ralph
                                last edited by

                                @Ralph This solution didn't actually work for me even having python 2.7.
                                Tried the npm install of serialport in node_modules but the versioning was wrong.
                                At the end had to copy the folder from another computer and has been working ok since then

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

                                  @mmbermudeza Good to hear you got it working. We're considering pre-compiling the library and shipping it with the plugin, so we will prevent these kinds of problems. We'll have to do some testing though to see if it works for all operating systems.

                                  1 Reply Last reply Reply Quote 0
                                  • M Offline
                                    MaSePreetz Pybytes Beta
                                    last edited by

                                    I have one improvement for the plugin:

                                    After a normal install the Plugin is always active and tries to connect to a Board with the last active settings.

                                    This is fine in case Atom is only used as PyCon IDE.

                                    But i use it as well as a normal editor and then the plugin window is in my way and thus reducing the amount of available screen space.

                                    Is it possible to have a setting/checkbox in the preferences of the plugin to prevent the auto-start/auto-connection?

                                    For me it would be fine to activate the plugin via the menu or even in the preferences when i need it.

                                    Anyway, thanks a lot for the plugin!

                                    I feel with you about the serialport problems on the different platforms. Native node.js libraries are not easy at all.

                                    Kind regards,
                                    Marc

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

                                      Hi @MaSePreetz, Thanks for your feedback. At the moment there are already 2 ways to do this:

                                      • In the Pymakr settings screen or you packages overview, you can Disable the entire plugin
                                      • Click the 'close' button of the terminal and leave it closed. When restarting atom it'll remember this state and will not connect. The 'open' button will stay on the bottom of the screen so you can open it at any time.

                                      Is this what you were looking for?

                                      M 1 Reply Last reply Reply Quote 0
                                      • M Offline
                                        MaSePreetz Pybytes Beta @Ralph
                                        last edited by

                                        Hi @Ralph, thanks for the swift response.

                                        You are right, i forgot about the disable button.

                                        But the second method does not work for me when the plugin is enabled.
                                        Atom always opens the plugin window with auto-connect when i open Atom (Atom 1.16.0 on Windows 7 64Bit),
                                        regardless of the previous state of the plugin...

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

                                          @MaSePreetz You are right, the behaviour is a little less straight forward. Turns out Atom stores this state per project. So if you have one project open, close the terminal and then close atom, the terminal will still be closed when opening that same project. But when opening another project, the state will be set to 'open' again.

                                          Considering that, it might be useful for some people to have a 'don't open on startup' setting for the plugin, so it will always stay closed by default.

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

                                            Hi @Ralph I see you have a lot on your plate, but I wonder if it will also be possible to one day program via a Jupyter notebook? This would be fantastic for rapid expolration of data generated by the board.
                                            Of interest https://github.com/adafruit/jupyter_micropython_kernel

                                            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
                                            • 2
                                            • 3
                                            • 4
                                            • 5
                                            • 2 / 5
                                            • First post
                                              Last post

                                            Pycom on Twitter

                                            Pycom