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

    Pin Module Doubts (Solved)

    Scheduled Pinned Locked Moved Discussion
    module pincallback methodpin.init
    3 Posts 2 Posters 394 Views 2 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.
    • nespressifN Offline
      nespressif
      last edited by nespressif

      Hi, everybody,

      I know that I can register an interruption with the callback method, but I don't see that there is a method to disable the interruption. How can I disable an interruption that I have previously registered with the callback method?

      pin.init(mode, pull, * , alt)
      I don't understand the third argument '*' nor how I can use the fourth argument, the alt function. I also don't understand the difference with this one called p = Pin('P10', mode=Pin.OUT, pull=None, alt=-1), any example with pin.init?

      I would appreciate any clarification.

      Regards,

      danD 1 Reply Last reply Reply Quote 0
      • danD Offline
        dan @nespressif
        last edited by

        @nespressif Hi, to disable the callback, set the handler to None. It's mentioned on the docs page as well.

        The * is the pin value (0 or 1), I have added that to the docs. alt is the functionality of the pin. For normal GPIO, just don't specify it and it'll be handled by the sw.

        1 Reply Last reply Reply Quote 0
        • nespressifN Offline
          nespressif
          last edited by

          @dan said in Pin Module Doubts:

          Hi, to disable the callback, set the handler to None. It's mentioned on the docs page as well.

          Ok, sorry, I had not see it.

          Thank you for your rapid response.

          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