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

Add commands to check if actual time is in DST or not #1429

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

MaxineMuster
Copy link
Contributor

New command clock_calcDST nthWeekEnd monthEnd dayEnd hourEnd nthWeekStart monthStart dayStart hourStart
to set the DST start and end rule.

Examples:
Australia / Sydney CLOCK_calcDST 1 4 1 3 1 10 1 2
Amsterdam (EU) CLOCK_calcDST 0 10 1 3 0 3 1 2

$isDST will return 1 if DST is active, 0 else

It's enabled with

#define ENABLE_NTP_DST 1

New command "clock_calcDST nthWeekEnd monthEnd dayEnd hourEnd nthWeekStart monthStart dayStart hourStart"
to set the DST start and end rule.

$isDST will return 1 if DST is active, 0 else

It's enabled with
@giedriuslt
Copy link
Contributor

careful with this, I see it's already to big for bl602, probably because of strftime use

@MaxineMuster
Copy link
Contributor Author

MaxineMuster commented Nov 17, 2024

probably because of strftime use

That could be easily solved, it's only used for informational purposes. And in any case we don't need to enable this on BL602.

It's really time my BL602 arrives, so I can do my own tests...

Is this a result from testing or is there a known size limit?

@openshwprojects
Copy link
Owner

I think I can merge it, but can you disable it by default, since it seems to raise flash uasge a bit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants