OpenSprinkler Forums Hardware Questions Router Causes clock to jump back

  • This topic is empty.
Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #23042

    VBigger
    Member

    Gentlemen, When I connect my OS to a router (netgear) that is NOT internet-connected, the internal OS time will jump back randomly. It will jump back 12 seconds here, a couple seconds there. Then all of a sudden it will realize it’s behind and jump ahead to the correct time.

    When I unplug the router cable, it works just great. So for normal operations I just unplug the cable and when I want to change a setting, I plug it in, make the change, and unplug it. I also get frequent connection errors (i.e. check password… etc.) when making changes, but can usually select whatever function again and it will save the changes I made.

    Any ideas why the router is apparently messing with my OS clock? Is it associated with my intermittent connection issue?

    #27506

    Ray
    Keymaster

    If your router is not Internet connected, you should turn off the NTP sync option. Once this option is off, you can also manually set a time if it doesn’t already have the correct time. These can be done using the web interface.

    Alternatively, if your router can function as NTP sync server, you can change the NTP ip on the controller to use your router’s ip. The NTP ip can only be changed on the controller (by pressing and holding B3 while powering up).

    #27507

    VBigger
    Member

    I have two OS’s still not working well. I have four units total; two are working well, two are not. All DIY kits.

    Troubleshooting OS #1 (Using a single program to run 4 stations for 10 seconds sequentially). Without being connected to a router, it kept good time both with w/NTP “ON” and “OFF”. When connected to a non-internet connected router (with NTP “OFF”), it started sporadic time-keeping (seconds sporadic, but overall kept within a minute of the right time). 10 second station times became 26 seconds long and station indicators on LCD screen moved very slowly. The clock self-corrected after hanging on a minute too long, then jumped ahead to correct time. As a result, the remaining stations did not turn on (program ended). This occurred with NTP “ON” as well. When I connected back to an internet-connected LAN, all worked with NTP “ON” and “OFF”. I unplugged it entirely for a couple hours and it had the correct time when I plugged it back in.

    Troubleshooting OS #2: (Same program: Single program to run 4 stations for 10 seconds sequentially). It seemed to work fine w/NTP “ON” and connected to internet-connected router. It auto-corrected the time when I plugged it in. I unconnected the LAN cable. It kept good time with NTP still “ON”. I turned NTP “OFF” and it took a long time to get past “connecting”. Oddly it still showed three bars (strong signal strength) with no “x” while unconnected. It seemed to work fine otherwise. I connecting to a router w/o internet connection (NTP still “OFF”), and the clock immediately stalled and cycled between 1815 and 1814. I turned NTP “ON” and reset. It took time “connecting” again and the clock was still stalled, cycling between 1815 and 1814. I disconnected the non-internet router and the OS stayed stalled between 1815 and 1814. I plugged back in to the internet-connected router, (NTP “OFF”) and there was no change in the clock, but it “connected” very fast. I turned NTP “ON” and reset, and it synced up to correct time. It lost several minutes over the next couple hours (NTP “ON” and connected to internet-connected LAN) and when I reset in (OFF-ON) in re-synced to the correct time. I left it “OFF” for the night and when I turned it on it showed the correct time right away; before going through the connecting routine. It lost time again what left “ON” and again when connected to internet-LAN ( a few minutes each hour)
    Hope this isn’t too much detail… Thank you Ray.

    #27508

    Ray
    Keymaster

    What you described sounded like ‘impossible situations’ to me… Let’s look at the details you described about the first device:

    Without being connected to a router, it kept good time both with w/NTP “ON” and “OFF”. When connected to a non-internet connected router (with NTP “OFF”), it started sporadic time-keeping..

    This is very puzzling. Technically the firmware performs time-keeping in the following way: every time the controller restarts, and every 24 hours since that it perform an NTP syncing, unless if NTP sync option is turned off. Once synced, the time is written to the RTC. Every minute the microcontroller reads the RTC and refreshes its time. So the time stored in the RTC determines the accuracy of the device timing. Given this, whether the router is connected to the Internet or not should have no effect on the clock running faster, slower, or stalling.

    One thing I thought about is: you should check if the CR1220 battery is installed reliably. If the battery is not installed or does not have correct voltage (needs to be around 3V), that can cause strange behaviors on the RTC.

    Also, please specify your firmware version so we can check if the issue is reproducible.

    #27509

    VBigger
    Member

    I was out of town for a week: Here’s the latest info:

    OS#2: Firmware ver. 205 Battery checked 2.9VDC. After a week of being off, I connected to internet LAN and time showed all zeros (I had removed the battery to check voltage). NTP synced up to correct time and date, but wrong day (Thurs instead of Monday). Turned unit off, disconnected LAN cable and turned back on: time started again at 00:00 and day/date at 01-01. This occurred twice; once with NTP “ON” and again with NTP “OFF”. Every time I turn the machine off and then back on, the time starts again at 00:00.

    OS#1. Battery checked good. I found that station 5 was always on (w/o any LCD or program indication). I re-soldered all the leads to station 5 and it worked like a champ hooked up to a internet-less router…. thought everything was peachy but it hung up at 1457-1456 the following afternoon. So I turned on RTP, hooked up to home LAN w/internet. It re-synced fine. Turned RTP “OFF” and reconnected to internet-less router. I’ll see how long it lasts. It seems to work well until I connect my iphone… More to come…

    #27510

    Ray
    Keymaster

    After a week of being off, I connected to internet LAN and time showed all zeros

    This is typically due to a soldering problem on the battery holder, causing the battery to be disconnected from the RTC. Without battery the RTC will reset to 00:00 on start up. Check the solder joints of the battery holder and see if a pin may be lifted. Re-soldering it should solve the problem.

    #27511

    VBigger
    Member

    Ray,
    I checked the battery pins; looked good; re-soldered anyway; no joy. I’m getting voltage to (what I think is) the RTC (1/4″chip dead center of the board; second pin in from the bottom right corner). I rechecked everything for solder problems (looked fine but re-soldered crystals because they looked a little iffy…), dissembled to check the GND-VCC and GND-VIN resistance, both above 1k. GND-VCC and GND-VIN volts both check good as well. Reassembled and it still comes up all zeros until it syncs up with NTP.

    Also, the other OS (#1); it works great most of the time, but somehow got “stuck” again last night. On my iPhone APP the “current status” showed stuck at “Thurs 20 Dec 2058 at 17:18” and the LCD display showed the same except “Sat” instead of “Thurs”. It had been connected to non-internet router with NTP “off”. I re-synced w/internet (NTP ON); it re-synced ok. I turned NTP “OFF” and reconnected to the other router. It stayed on time for a minute of two, then the day on the LCD turned back to “Sat”. I noticed whenever it goes to “sat” I could not connect with my iPhone and I was unable to bring up the IP address by pressing B1 (or B2). I reset it again and its been staying on track, even through a power outage last night (July 31). Update (1 Aug) still good at 11PM tonight.

    #27512

    HFTobeason
    Participant

    I noticed today that the iPhone app was relaying a random date/time in the year 2036 from my OpenSprinkler 2.x unit. NTP sync is “ON”. I forced a reboot through the iPhone app twice to no avail. I then turned NTP Sync “OFF”, rebooted, turned NTP Sync back “ON”, rebooted, and the correct time showed up. I don’t know how long the wrong time has been showing – it might have been over a month.

    #27513

    Ray
    Keymaster

    @VBigger: the only reason that the RTC cannot ‘remember’ time is when the backup battery is under voltage or is not connected well. Of course, if the battery is plugged in reversely, that would also cause the same problem. Make sure the battery’s positive (+) side is visible.

    #27514

    VBigger
    Member

    Double checked the battery again just to make sure. It is in correctly (I can read the + when I look at the board) and I am still getting 3v on one pin of a small 8-pin chip on the board indicating that the solder connections are good.

    Also, the station 5 “ON” icon (expanding bubble) starts off ok, but after a few minutes gets VERY slow indicating something besides (or in addition to) thew RTC problem. You can see two videos of the problem at:

    https://www.youtube.com/watch?v=pmYht0MnMPc&list=UUPLuCCWdBoUTCDQEFCmdavg
    and
    https://www.youtube.com/watch?v=MVzm6e8ZJmA&list=UUPLuCCWdBoUTCDQEFCmdavg

    #27515

    Ray
    Keymaster

    OK. Thanks for posting the video. Helped a lot to see the problem. There are two possibilities I can think of:
    1. The 12MHz crystal (for microcontroller) is not soldered well or defective, causing the system clock to slow down significantly.
    2. There is an issue with RTC (either loose connection or defective chip) that causes the microcontroller to have difficulty reading the RTC.

    This is a rather unusual problem, you can send an email to [email protected] to arrange for support.

Viewing 11 posts - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.

OpenSprinkler Forums Hardware Questions Router Causes clock to jump back