Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Libraries : add sunset/sunrise time #244

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,6 @@
path = lib/LUA
url = https://github.com/lua/lua.git
branch = v5.3
[submodule "lib/sunset"]
path = lib/sunset
url = https://github.com/buelowp/sunset
2 changes: 2 additions & 0 deletions include/osw_config_keys.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ extern OswConfigKeyBool timeFormat;
extern OswConfigKeyShort timeZone;
extern OswConfigKeyShort dualTimeZone;
extern OswConfigKeyShort resetDay;
extern OswConfigKeyDouble latitudeCoord;
extern OswConfigKeyDouble longtitudeCoord;
#if OSW_PLATFORM_ENVIRONMENT_ACCELEROMETER == 1
extern OswConfigKeyShort configHeight;
extern OswConfigKeyShort configWeight;
Expand Down
1 change: 1 addition & 0 deletions lib/sunset
Submodule sunset added at 653fe8
3 changes: 3 additions & 0 deletions src/osw_config_keys.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ OswConfigKeyShort timeZone("h", "Date & Time", "Timezone", "Number of offset hou
OswConfigKeyShort dualTimeZone("h1", "Date & Time", "Dual-Timezone", "Number of offset Dual-hours (e.g. 9 = Seoul).", 0);
OswConfigKeyShort resetDay("r", "Date & Time", "Day of the week",
"Choose the day of the week to reset the number of steps (e.g. 1-7 are days, 0 is disabled).", 0);
OswConfigKeyDouble latitudeCoord("t1", "Date & Time", "Latitude for Sunset", "latitude of your location - to the 5th decimal place (e.g. 37.32103)", 37.78243);
OswConfigKeyDouble longtitudeCoord("t2", "Date & Time", "Longtitude for Sunset", "longtitude of your location - to the 5th decimal place (e.g. 127.10901)", -122.39122);
#if OSW_PLATFORM_ENVIRONMENT_ACCELEROMETER == 1
OswConfigKeyShort configHeight("f4", "Fitness", "User Height", "E.g 175.7 cm -> 175 (Rounds off)", 175);
OswConfigKeyShort configWeight("f5", "Fitness", "User Weight", "E.g 70.3 kg -> 70 (Rounds off)", 70);
Expand Down Expand Up @@ -100,6 +102,7 @@ OswConfigKey* oswConfigKeys[] = {
// date + time
&OswConfigAllKeys::dateFormat, &OswConfigAllKeys::daylightOffset, &OswConfigAllKeys::timeZone,
&OswConfigAllKeys::dualTimeZone, &OswConfigAllKeys::timeFormat, &OswConfigAllKeys::resetDay,
&OswConfigAllKeys::latitudeCoord,&OswConfigAllKeys::longtitudeCoord,
// colors
&OswConfigAllKeys::themeBackgroundColor, &OswConfigAllKeys::themeBackgroundDimmedColor,
&OswConfigAllKeys::themeForegroundColor, &OswConfigAllKeys::themeForegroundDimmedColor,
Expand Down