• Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    "time"-value for Digital Input on unipi?

    Scheduled Pinned Locked Moved Evok API
    2 Posts 2 Posters 717 Views
    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.
    • L
      Lasse
      last edited by

      It is not:

      • Epoch
      • Seconds/Milliseconds since last change
        So what is it?
        I would like to check when the value last changed, to implement some delay in later processing to slow down the effect of a flapping input, but cannot understand what 'time' is related here.
        This is one example:
      {"bitvalue": 1, "glob_dev_id": 0, "value": 1, "circuit": "1", "time": 1012811606, "debounce": 0, "counter_mode": false, "dev": "input"}
      
      $ date --date @1012811606
      Mon 04 Feb 2002 08:33:26 AM UTC
      

      Like 18 years off...
      The same parameter on the 1-wire looks correct:

      {"interval": 3.0, "value": 31.55, "circuit": "28FA2A790B00001C", "address": "28FA2A790B00001C", "time": 1606155885.72539, "typ": "DS18B20", "lost": false, "dev": "temp"}
      
      1 Reply Last reply
      Reply Quote 0
      • M
        martin_triska
        last edited by

        Hello @Lasse ,

        this value is Unipi 1.1 specific and comes from pigpio subsystem tick value. From documentation:

        tick: the number of microseconds since system boot. It wraps around after 1h12m
        
        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
        • First post
          Last post