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

    do pytrack-2 and pycoproc 0.0.4 work (wake on accel interrupt)

    Scheduled Pinned Locked Moved Expansion Board
    5 Posts 4 Posters 91 Views 5 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.
    • H Offline
      hgoldwire
      last edited by hgoldwire

      Hi gang,

      I've got a GPy and a pytrack v2, and I can't get them to wake on accelerometer interrupt. Does anyone have this working?

      I'm on GPY 1.20.2.r1, with a freshly-formatted littlefs filesystem and freshly-erased nvram. Libraries are from https://github.com/pycom/pycom-libraries/tree/master/pytrack-2/lib

      I'm trying

      from pytrack import Pytrack
      from LIS2HH12 import LIS2HH12
      
      py = Pytrack()
      acc = LIS2HH12(py)
      
      py.read_hw_version()          
      # 6
      py.read_fw_version()            
      # 15
      py.read_product_id()
      # 61459
      os.uname()     
      # (sysname='GPy', nodename='GPy', release='1.20.2.r1', version='v1.11-a5aa0b8 on 2020-09-09', machine='GPy with ESP32', pybytes='1.6.0')
      
      acc.enable_activity_interrupt(200, 200)     # this works before I go_to_sleep
      py.setup_int_wake_up(rising=True, falling=False)       # attempt to wake on activity
      
      py.setup_sleep(300)
      py.go_to_sleep()
      

      Once asleep, the pytrack button wakes it instantly, or RTC wakes it eventually, but no amount of shaking will cause the accelerometer to wake it. In related news, it seems pycoproc 0.0.4 has removed get_wake_reason() and get_sleep_remaining(). Does this library actually work?

      Thanks,
      Henry

      ivas9090I 1 Reply Last reply Reply Quote 0
      • ivas9090I Offline
        ivas9090 @hgoldwire
        last edited by

        @hgoldwire I am having a similar issue with my external interrupt using a sensor. I paid money for a 1 hour consultation with pycom and they stopped responding. Very unprofessional in my opinion.

        https://forum.pycom.io/topic/6370/pytrack2-external-pic-interrupt

        1 Reply Last reply Reply Quote 0
        • G Offline
          Gijs
          last edited by

          Hi,
          We are working on fixing this issue!
          Gijs

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

            Hello,

            I've also got the GPy and a Pytrack V2, and I experience the same issue. I also tried to add the get_wake_reason and get_sleep_remaining from an older version of pycoproc, but they both return zero. (While there should be some value in it). It only wakes on the timer, not on the accelerometer.

            @Gijs Is there already some news about this issue?

            1 Reply Last reply Reply Quote 0
            • G Offline
              Gijs
              last edited by

              We hope to publish something soon!

              In the meantime, I can give you a sneak preview here:

              https://github.com/pycom/pycom-libraries/issues/132#issuecomment-748895114

              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