10-12-2016, 18:32
(10-12-2016, 02:54)Barrow4491 Wrote: In the config file for the daylight saving, if there is no daylight saving, (as is the case in Queensland Australia), I assume "Timezone myTZ (aEDT, aEST);" is the correct thing to do , but what is the format for the TimeChangeRule sections.
Hi
The configuration on the TimeChangeRule is very simple for any place:
Taking the example given on the code:
Code:
// Example for Australia Eastern Time Zone (Sydney, Melbourne)
TimeChangeRule aEDT = {"AEDT", First, Sun, Oct, 2, 660}; //UTC + 11 hours
TimeChangeRule aEST = {"AEST", First, Sun, Apr, 3, 600}; //UTC + 10 hours
Timezone myTZ(aEDT, aEST);This is for a zone which starts the summer time, on the first Sunday of April, and the zone is 10 hours ahead of UTC
also, this zone ends summer time on the first Sunday of October, starting to be 11 hours ahead of UTC.
Now, for the cases, as is yours, where the Summer Time does not apply, just configure the first line, defining the amount of time your zone is ahead or behind the UTC time, and then pass the same rule twice to the constructor, for example:
Code:
Timezone myTZ(aEDT, aEDT);There is a readme file in the timezone library folder, where you can find more info.
On the Pro2 PLUS, no matter the place you are, the internal RTC is always set to run in UTC, so its very important to correctly set your time zone.

