Sunrise/Sunset hands

Hi

I’m trying to make 2 hands (1 for sunrise, 1 for sunset) to rotate on the outside ring of the watch face (over the rick marks)

I tired to use #WSUNRISE# & #WSUNSET# but they only work to show digits

Any help on the expression to use is appreciated

Hi mate the only problem i can see is that you will only be able to show the hour and not the mins to show the hour use ((#WRh#/12)*360) that changes the 1-12 hours into rotation for a hand ok.

Or you could use
(((#WRh#/12)*360)+(#WRm#/60)*30)
that will give you the position the hour hand would be in if it was on a clock face at the time of the sunrise

just replace the WRm With WSm and the WRh With WSh For Sunset ok

3 Likes

Thank you @dazstacey, much appreciated…

Works great in 12 hour format. How about on a 24 hour clock face? Every change I made to get it to work had me off by an hour.

Thanks!

((#WRH#/23)*360)

Try that it should work remember when working with 24hr clock divide by 23 not 24 as the first number should be 0 ok

Here’s my sunrise and sunset:

(((#WRH#/23)*360)+(#WRm#/60)*30)

(((#WSH#/23)*360)+(#WSm#/60)*30)

It’s still off. For example, it showed this morning’s sunrise at about 8am when it should have been about 7am. Could it be a DST issue?

Thanks!

-M

1 Like

My guess would be, that if you change the hours to 24, a minute would also be less, so *15 instead of *30
(((#WRH#/23)*360)+(#WRm#/60)*15)
(((#WSH#/23)*360)+(#WSm#/60)*15)

1 Like

Hi there, I know this is an old post, but I’m trying to do something very similar and even though it looked great using your code, it somehow doesn’t work on my Fossil Carlyle (WearOS).

I’m a total Noob when it comes to tags and coding, so help would be highly appreciated! :slight_smile:

This is the watch face I’m working on:

Here is a short explanation how my dials are supposed to work. Hope that helps:

((((#WSUNRISEH24#/24)*360)+(#WSUNRISEM#/60)*15)+180)

((((#WSUNSETH24#/24)*360)+(#WSUNSETM#/60)*15)+180)

the +180 is because 24 is on the bottom instead of the top. If you make a face with 24 or top, then remove the +180

2 Likes

Thank you so much for your help @kvansant ! Your code does work perfectly!

I just published the watch face :slight_smile:

All the best!

Great! I probably got these from @ThaMattie a long time ago so he deserves the credit.

1 Like

That is why i use the long WSUNRISEH24 tags instead of the short WRH tags… They don’t seem to work on my Carlyle either (but I have seen them work on other people’s Carlyle…)

Hi @DigitalWatchmaker . Please forgive me coming to the Party so Late. I wonder with this scheme what happens after the Spring Equinox when there are more than 12 hours of Daylight . Where I am we expect 16 and a half hours at the Summer Solstice . I am posting a link to a face I did some time ago and have quite forgotten who helped me because I could not have come up with it on my own I don’t think ?
Look for the " Night Time Filter " Arc Shape . I am wondering if you could use that over your white daylight ring.
I like the unconventional 24hrs dial you use . The classic being midnight at 12 .
Nice job . Shame they are not so popular .