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

[Feature]: support timezone configure #70

Open
2 tasks done
lida2003 opened this issue Jan 15, 2025 · 0 comments
Open
2 tasks done

[Feature]: support timezone configure #70

lida2003 opened this issue Jan 15, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@lida2003
Copy link

lida2003 commented Jan 15, 2025

Requirements

  • I have updated Configurator to the latest available version
  • I did a search to see if there is a similar issue or if a pull request is open.

Is your feature request related to a problem?

Describe the solution you'd like

  1. add timezone multi-list box
  2. initialize the box with current configured timezone
  3. user can select the timezone where he/she fly the FPV
  4. add a buttone to apply timezone

Related commands and zoneinfo see below:

daniel@daniel-nvidia:~/Work/OpenIPC-Adaptive-Link$ ls /usr/share/zoneinfo
Africa      Australia  Cuba     Etc      GMT+0      Iceland      Japan              MET      NZ-CHAT     PRC        SystemV    UTC           Zulu
America     Brazil     EET      Europe   GMT-0      Indian       Kwajalein          Mexico   Pacific     PST8PDT    Turkey     WET
Antarctica  Canada     Egypt    Factory  GMT0       Iran         leapseconds        MST      Poland      right      tzdata.zi  W-SU
Arctic      CET        Eire     GB       Greenwich  iso3166.tab  leap-seconds.list  MST7MDT  Portugal    ROC        UCT        zone1970.tab
Asia        Chile      EST      GB-Eire  Hongkong   Israel       Libya              Navajo   posix       ROK        Universal  zonenow.tab
Atlantic    CST6CDT    EST5EDT  GMT      HST        Jamaica      localtime          NZ       posixrules  Singapore  US         zone.tab
daniel@daniel-nvidia:~/Work/OpenIPC-Adaptive-Link$ ls /usr/share/zoneinfo/Asia/
Aden       Atyrau   Brunei      Damascus   Hebron       Jerusalem  Kolkata       Makassar      Phnom_Penh  Saigon         Tashkent  Ujung_Pandang  Yangon
Almaty     Baghdad  Calcutta    Dhaka      Ho_Chi_Minh  Kabul      Krasnoyarsk   Manila        Pontianak   Sakhalin       Tbilisi   Ulaanbaatar    Yekaterinburg
Amman      Bahrain  Chita       Dili       Hong_Kong    Kamchatka  Kuala_Lumpur  Muscat        Pyongyang   Samarkand      Tehran    Ulan_Bator     Yerevan
Anadyr     Baku     Choibalsan  Dubai      Hovd         Karachi    Kuching       Nicosia       Qatar       Seoul          Tel_Aviv  Urumqi
Aqtau      Bangkok  Chongqing   Dushanbe   Irkutsk      Kashgar    Kuwait        Novokuznetsk  Qostanay    Shanghai       Thimbu    Ust-Nera
Aqtobe     Barnaul  Chungking   Famagusta  Istanbul     Kathmandu  Macao         Novosibirsk   Qyzylorda   Singapore      Thimphu   Vientiane
Ashgabat   Beirut   Colombo     Gaza       Jakarta      Katmandu   Macau         Omsk          Rangoon     Srednekolymsk  Tokyo     Vladivostok
Ashkhabad  Bishkek  Dacca       Harbin     Jayapura     Khandyga   Magadan       Oral          Riyadh      Taipei         Tomsk     Yakutsk
daniel@daniel-nvidia:~/Work/OpenIPC-Adaptive-Link$ sudo ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
daniel@daniel-nvidia:~/Work/OpenIPC-Adaptive-Link$ ls -l /etc/localtime
lrwxrwxrwx 1 root root 33 11月  7 08:40 /etc/localtime -> /usr/share/zoneinfo/Asia/Shanghai

For OpenIPC firmware, which timezone is trimmed, following commands can be used.

$ echo "GMT-8" > /etc/TZ
$ export TZ=$(cat /etc/TZ)

Describe alternatives you've considered

Time sync with the configurator

Additional context

1. No Offset GMT Time Zones

Configuration Description
GMT0 Greenwich Mean Time, no offset.
UTC0 Equivalent to GMT0, no offset.

2. Eastern Time Zones (UTC+X)
Eastern time zones are ahead of UTC, with a positive offset (+X).

Configuration Offset Example Regions
GMT-1 UTC+1 hr Central European Time (e.g., France, Germany).
GMT-2 UTC+2 hrs South Africa Standard Time.
GMT-3 UTC+3 hrs Moscow Standard Time.
GMT-4 UTC+4 hrs Dubai Standard Time.
GMT-5 UTC+5 hrs Pakistan Standard Time.
GMT-6 UTC+6 hrs Bangladesh Standard Time.
GMT-7 UTC+7 hrs Thailand Standard Time.
GMT-8 UTC+8 hrs China Standard Time (Beijing).
GMT-9 UTC+9 hrs Japan Standard Time.
GMT-10 UTC+10 hrs Australian Eastern Standard Time.
GMT-11 UTC+11 hrs Solomon Islands Time.
GMT-12 UTC+12 hrs New Zealand Standard Time.

3. Western Time Zones (UTC-X)
Western time zones are behind UTC, with a negative offset (-X).

Configuration Offset Example Regions
GMT+1 UTC-1 hr Azores Standard Time.
GMT+2 UTC-2 hrs Mid-Atlantic Standard Time.
GMT+3 UTC-3 hrs Brasília Standard Time.
GMT+4 UTC-4 hrs Atlantic Standard Time.
GMT+5 UTC-5 hrs Eastern Standard Time (USA).
GMT+6 UTC-6 hrs Central Standard Time (USA).
GMT+7 UTC-7 hrs Mountain Standard Time (USA).
GMT+8 UTC-8 hrs Pacific Standard Time (USA).
GMT+9 UTC-9 hrs Alaska Standard Time.
GMT+10 UTC-10 hrs Hawaii Standard Time.
GMT+11 UTC-11 hrs Samoa Standard Time.
GMT+12 UTC-12 hrs Baker Island Time.
@lida2003 lida2003 added the enhancement New feature or request label Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant