Jump to content

SkySurveyBanner.jpg.21855908fce40597655603b6c9af720d.jpg

DIY Moon Phase Dial


Gina

Recommended Posts

Hmm...  Latest log -  21:00:16.  That's +16s in the last minute :(  (Clock 16s slow compared with real time.)  Thought the earlier results might have been too good to be true!  Oh well, see what the overnight log shows... (No not going to bed yet and wiill have a couple more readings tonight.)

 

Edited by Gina
Link to comment
Share on other sites

  Here's the latest log results.

  Time       Diff   Total
16:00:02              0
16:59:58    - 4     - 4
17:59:58      0     - 4
19:00:04    +6     +2
20:00:00    - 4     - 2
21:00:16   +16   +14
22:00:18    +2    +16

 

Edited by Gina
Link to comment
Share on other sites

  Here's the latest log results.

  Time       Diff   Total
 16:00:02             0
 16:59:58    -4    - 4
 17:59:58     0    - 4
 19:00:04   +6    +2
 20:00:00   - 4    - 2
 21:00:16  +16  +14
 22:00:18    +2  +16
 23:00:14    - 4  +12
  0:00:24   +10  +22
  1:00:24       0  +22
  2:00:28     +4  +26
  3:00:40    +12 +40
  4:00:38     - 2  +36
  5:00:48    +10 +46
  6:00:48       0  +46
  7:00:40     - 8  +38
  8:00:54   +14  +52
  9:00:58     +4  +56
 10:00:58       0  +56

Cumulative error is about a minute in 18 hours which is 1 in 1080 so we're ready now for the next level of correction, about 3s an hour.

Edited by Gina
Link to comment
Share on other sites

Two more log entries while I've been out this morning

 11:01:06  +8 +64
 12:01:02   -4 +60

So that's exactly one minute in 20 hours ie. 1 in 1200 or 3s in an hour.  Whist that could be corrected by setting to RTC every hour, we are getting up to 16s out by the end of the hour and that's too much so I shall apply another level of correction as before, of 1 in 1200.

Edited by Gina
Link to comment
Share on other sites

Theoretically the next level correction is given by 0.01321 - 0.013158 = 0.000052 or 1 in 19231 which is a lot less than the practical findings.  I don't know why this should be but if it works I'll put it down to the black magic of mechanisms :icon_rolleyes:  Now to see if I can work out the code required to apply the required correction...

Link to comment
Share on other sites

I'm thinking that the correction already applied of add a half-step every 76 intervals is not vastly different from the required extra correction of a half-step in 92 intervals and wondering if I can just reduce the 76 to add a half-step slightly more often.  1 in 76 = 0.013  1in 96 = 0.0104 adding them gives 0.0234 which is 1 in 74.6, nearest whole number = 75 so I'll try that.

Edited by Gina
Link to comment
Share on other sites

And we're off...  Clock looks right at 2:50.  A reason for some variation in the timing measured by reading the RTC, when the minute hand is sensed by the Hall sensor, may be that the gears driving the hours and the moon phase dial may cause some wobbling of the axle - it isn't very well supported.  I might see if I can improve it.

Link to comment
Share on other sites

Well, it was looking hopeful but then...

    Time      Diff   Total
 14:59:48               0
 16:00:04   +16   +16
 17:00:02     -2    +14
 18:00:02      0    +14
 19:00:10    +8    +22
 20:00:06     -4    +18
 21:00:24   +18   +36

Think I'll try reducing the 75 to 74 and see what happens - 'coz it's still losing.  Yes, that's right - losing - Time is the real time when the minute hand is at 12 o'clock so when RTC is on the hour the clock reads less.

Link to comment
Share on other sites

I keep increasing the correction by reducing the correction interval, and it's still losing :(  Fortunately, altering the sketch and re-running only takes a minute of my time.  Strange thing is that the timing doesn't seem to be getting any better.  BUT I've had a thought - the delay was 140ms per half-step and with 14 of these in 2s it's very close to overflowing and missing the next "tick".  140 x 14 = 1960 so I'm trying again with the delay at 130ms giving 1820ms.

56e2c84d27d91_LoggingTimeErrors09.JPG.77

Link to comment
Share on other sites

First hour has shown a small anount fast so hopeful but one sample has little meaning.  Trouble with this project ATM is that testing takes time...

Link to comment
Share on other sites

Still looking promising :)

    Time    Diff   Total
 13:59:51            0
 14:59:45    -6    - 6
 15:59:55  +10   +4
 16:59:45   -10   - 6
 17:59:41    -4   - 10

 

Link to comment
Share on other sites

Update - latest time value same as previous :)

    Time      Diff   Total
 13:59:51              0
 14:59:45    -6      -6
 15:59:55  +10    +4
 16:59:45   -10     -6
 17:59:41    -4    -10
 18:59:41     0    -10

Link to comment
Share on other sites

Now getting the expected gaining.  20s in 6h is 1/3m in 360m = 1 in 1080.  I think I'll take the third correction back to the theoretical 76 and see what that gives.  I believe I found the problem.

    Time      Diff   Total
 13:59:51              0
 14:59:45    -6       -6
 15:59:55  +10     +4
 16:59:45   -10      -6
 17:59:41    -4      -10
 18:59:41     0      -10  
 19:59:31   -10     -20

Link to comment
Share on other sites

Overnight results :-

    Time    Diff  Total
 20:59:56            0
 22:00:00  +4    +4
 22:59:54   -6     -2
  0:00:04   +8    +6
  1:00:04     0    +6
  2:00:08   +4   +10
  3:00:20   +1   +22
  4:00:18    -2   +20
  5:00:32  +14  +34
  6:00:26    -6   +28
  7:00:24    -2   +26
  8:00:34  +10  +36

36s slow in 10 hours = 3.6s per hour (3600s) or 1 in 1000.  We are now about the same amount but in the opposite direction compared with last time.  Changed from 31 to 76 for third correction so let's try half way at 53.  OTOH averaging the correction by adding 1/31 to 1/76 and dividing by 2 and gives 1/34.  Hmmm...

 

Link to comment
Share on other sites

My intuition was right - clock is gaining slightly so the correction period needs to be more than 35.  Think I might try 50 :D

   Time     Diff  Total
   9:59:50          0
 10:59:40  -10  -10
 11:59:44  +4    -6
 12:59:38  -16  -22

I've been reading through my giant clock thread, forerunner of this one, and there was a suggestion of a complete gear train from seconds to hours and driving the seconds.  I rejected this as I wanted to use a 28BYJ-48 stepper motor with gearbox but what if I used a NEMA type motor? - I wonder if these run fast enough to set the clock in a reasonable time.  I know from my 3D printers that these motors can run quite fast.  Maybe I'll work out how fast the seconds shaft would need to rotate.  The motor could drive the intermediate gear though.

I think ten minutes to set the clock from startup would be tolerable.  That's 10m for 12 hours... could we stretch to 12m - I guess so.  So that's an hour in a minute or 60 rpm - one revolution in a second.  I'm pretty sure the NEMA motors can do this :)

Edited by Gina
typos
Link to comment
Share on other sites

I've been wondering what to do about the seconds.  With the current system there is no spare time to drive a second stepper motor - I'm using processor cycles for the step delay.  I thought of the possibility of using a digital display of the seconds but that goes against the analogue theme.

OTOH if I were to use a sweep second hand synchronised to the minute hand I could have what I want.  So let's look at the timing...  these motors have 1.8° step angle.  If the seconds shaft were to be driven directly we would want 6° per second.  6 / 1.8 = 3.33 recurring.  OH!!  Not direct drive then, we want a 3:10 gearing or maybe 6:10 or 12:10.  From a bit of Googling it seems these stepper motors will easily do 120rpm so we could afford a small step down from motor to seconds shaft.  Gearing would make construction easier.

A gear ratio of 5:6 using say 20t and 24t gears would mean the motor shaft would want to rotate 6° x 6/5 degrees per second or 6° x 6/5 /1.8 steps per second = 6x6 / (5x1.8) = 36 / 9 = 4. Thus normal clock operation would require 4 steps per second and the seconds hand would advance exactly a second in the one second interval.  No messing about with correction for a strange gearbox ratio. 

In fast mode for setting the clock or for "changing the clocks" every six months the second hand will be rotating at 2 revs per second or more and setting up would take around 6 minutes or less and changing the hour would take 30 seconds (I think) :)  I think I like it :D

 

Link to comment
Share on other sites

To drive the stepper motor I could use a standard RepRap 3D printer Pololu A4988 Stepper Motor Driver module which connects directly to an Arduino and which I have available.  Simple STEP and DIRECTION are the only data lines required though it has an ENABLE line as well so that the driver can be turned off if required.  The microstepping lines can be hard wired as we only want full stepping.

When using the full speed mode it might be desirable to accelerate and decelerate at beginning and end of the setting operation - time will tell.

I think I'm going with this idea and simply dump the idea of using the 28BYJ-48 as not suitable for purpose.  I could make it work  but...

Edited by Gina
Link to comment
Share on other sites

I shall be rebuilding this clock - well some of it - to use a standard stepper motor without gearbox and with a well known and accurate step angle.  As mentioned above, this will need no correction - it should give precise timing with no error other than slight inaccuracy of the RTC.  I might add in the time data radio receiver to provide UTC accuracy.  Once I've got the design sorted out I think I shall start a new thread as this one has become incongruously long due to abortive attempts to make things work with the 28BYJ-48 stepper motor with it's pecular gearbox.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. By using this site, you agree to our Terms of Use.