Announcement

Collapse
No announcement yet.

Help with clock setting from the web ... nettime

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Just use the DNSLOOKUP instruction in Do-more. Remember to configure the DNS Server in your Do-more IP Configuration (along with the Gateway Address). Then you can use the URL string (say in SS42, possibly have that be entered via C-more?). You can initialize SS42 via the STRPRINT instruction.

    Basically, every time you want to sync, do the DNSLOOKUP and have the On Success of DNSLOOKUP drive the NETTIME instruction.
    There are 10 kinds of people in this world, those who know binary, and those who do not.

    Comment


    • #17
      WOW .... AD tech got back to me today .... had some really good ideas!

      Rather then worry about tying to enter a time server, he suggested using DNSLOOKUP

      I had my tire trigger this command ... I used the name "time.nist.gov" and gave it a register of D2 to put the IP into. There is a done bit on this ... I use it to trigger the NETTIME command.

      Watching the IP (I am triggering ever minute for testing) I can see it chooses different IP's all the time!

      Mike

      Comment


      • #18
        Originally posted by xtal_01 View Post
        WOW .... AD tech got back to me today .... had some really good ideas!

        Rather then worry about tying to enter a time server, he suggested using DNSLOOKUP

        I had my tire trigger this command ... I used the name "time.nist.gov" and gave it a register of D2 to put the IP into. There is a done bit on this ... I use it to trigger the NETTIME command.

        Watching the IP (I am triggering ever minute for testing) I can see it chooses different IP's all the time!

        Mike
        Not sure how precise your timekeeping needs are, but you can probably scale the NETTIME sync back to daily or even weekly. The BRX keeps pretty accurate time.

        Comment


        • #19
          Originally posted by xtal_01 View Post
          WOW .... AD tech got back to me today .... had some really good ideas!

          Rather then worry about tying to enter a time server, he suggested using DNSLOOKUP

          I had my tire trigger this command ... I used the name "time.nist.gov" and gave it a register of D2 to put the IP into. There is a done bit on this ... I use it to trigger the NETTIME command.

          Watching the IP (I am triggering ever minute for testing) I can see it chooses different IP's all the time!

          Mike
          You should use the error bit on both the DNS lookup and net time instructions to go to a counter input. Once the counter hits a certain number it should turn on an alarm bit that lets the user know a network communication problem has occurred. Reset the error counter with the success bit of one or both instructions.

          If you wanted to get more advanced, when the error counter is done, it could go to a PING instruction before it turns on an alarm bit. The ping checks for connectivity to the local router and depending on whether that is a success or an error it would turn on a different alarm. One for saying that LAN connection doesnt work, and another for saying that it is an internet side issue beyond the router. This is what I do with my NetTime instruction for doing temperature logging on warehouse storage.
          Last edited by MikeN; 07-22-2019, 12:30 PM.

          Comment

          Working...
          X