CN107290950A - A kind of system time setting method and device - Google Patents

A kind of system time setting method and device Download PDF

Info

Publication number
CN107290950A
CN107290950A CN201610190969.9A CN201610190969A CN107290950A CN 107290950 A CN107290950 A CN 107290950A CN 201610190969 A CN201610190969 A CN 201610190969A CN 107290950 A CN107290950 A CN 107290950A
Authority
CN
China
Prior art keywords
equipment
time zone
time
zone parameter
parameter
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN201610190969.9A
Other languages
Chinese (zh)
Inventor
李贤利
余颖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Priority to CN201610190969.9A priority Critical patent/CN107290950A/en
Priority to PCT/CN2017/074160 priority patent/WO2017166950A1/en
Publication of CN107290950A publication Critical patent/CN107290950A/en
Withdrawn legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G04HOROLOGY
    • G04GELECTRONIC TIME-PIECES
    • G04G5/00Setting, i.e. correcting or changing, the time-indication

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Electric Clocks (AREA)

Abstract

The invention discloses a kind of system time setting method and device.This method includes:Read the hardware timeout of equipment;Determine the corresponding time zone parameter of the equipment;According to the hardware timeout and the time zone parameter, system time and the display of the equipment are calculated.The present invention can be it is determined that after the corresponding time zone parameter of equipment, the system time of automatic setting equipment makes system time adapt to the time zone residing for equipment, it is to avoid to there is the time difference between the local zone time in geographical position residing for the system time and equipment of equipment.

Description

A kind of system time setting method and device
Technical field
The present invention relates to field of embedded technology, more particularly to a kind of system time setting method and device.
Background technology
With the development of science and technology embedded software hardware technology is developed rapidly.In the field of communications, it is right The application of embedded device gradually increases, and requirement of the user to embedded device is also in raising progressively, at present Some embedded devices carry time display function, so that user is checked by display or backstage instrument System time.
Tend in economic development under the situation of globalization, the business scope of equipment manufacturer is also radiated the whole world, Delivered with a product for the whole world, still, existing embedded device, especially Power Supply Monitoring equipment System time is confined to show the local zone time of specific region, and the time conversion under different time zone is not considered, Due to the time difference relation in region, the system time that equipment backstage is obtained is still the time of grown place, Er Feixiao The time on ground is sold, so as to have influence on Consumer's Experience and the processing to data.
The content of the invention
The technical problem to be solved in the present invention is to provide a kind of system time setting method and device, to solve The problem of time that existing equipment does not account under different time zone changes.
For above-mentioned technical problem, the present invention is solved by the following technical programs.
The invention provides a kind of system time setting method, including:Read the hardware timeout of equipment;It is determined that The corresponding time zone parameter of the equipment;According to the hardware timeout and the time zone parameter, the equipment is calculated System time and display.
Wherein it is determined that the corresponding time zone parameter of the equipment, including:It is pre-configured with multiple time zone parameters;Will The time zone parameter of user's selection is used as the corresponding time zone parameter of the equipment.
Wherein it is determined that the corresponding time zone parameter of the equipment, including:Obtain the geographical position of the equipment; Determine the corresponding time zone parameter in the geographical position.
Wherein, during the system time of the equipment is shown, in addition to:Detect the equipment correspondence Time zone parameter whether change;If it is, being joined according to the time zone after current hardware timeout and change Number, corrects system time and the display of the equipment.
Wherein, the equipment includes:Power Supply Monitoring equipment.
Present invention also offers a kind of system time setting device, including:Read module, for reading equipment Hardware timeout;Determining module, for determining the corresponding time zone parameter of the equipment;Calculate and display module, For according to the hardware timeout and the time zone parameter, calculating system time and the display of the equipment.
Wherein, the determining module specifically for:It is pre-configured with multiple time zone parameters;By user select when Area's parameter is used as the corresponding time zone parameter of the equipment.
Wherein, the determining module specifically for:Obtain the geographical position of the equipment;Determine the geography The corresponding time zone parameter in position.
Wherein, the calculating and display module, are additionally operable to during the system time of the equipment is shown, Detect whether the corresponding time zone parameter of the equipment changes;If it is, according to current hardware timeout With the time zone parameter after change, system time and the display of the equipment are corrected.
Wherein, the equipment includes:Power Supply Monitoring equipment.
The present invention has the beneficial effect that:
The present invention can be it is determined that after the corresponding time zone parameter of equipment, the automatic system time for setting equipment, System time is set to adapt to the time zone residing for equipment, it is to avoid geographical position residing for the system time and equipment of equipment There is the time difference between local zone time.
Brief description of the drawings
Fig. 1 is the flow chart of system time setting method according to an embodiment of the invention;
Fig. 2 is the particular flow sheet of system time setting method according to an embodiment of the invention;
Fig. 3 is the structure chart of system time setting device according to an embodiment of the invention.
Embodiment
Below in conjunction with accompanying drawing and embodiment, the present invention will be described in further detail.It should be appreciated that this The specific embodiment of place description does not limit the present invention only to explain the present invention.
The embodiments of the invention provide a kind of system time setting method, Fig. 1 is according to one embodiment of the invention System time setting method flow chart.
Step S110, reads the hardware timeout of equipment.
The equipment is embedded device.For example:Equipment is for the power supply for the working condition for monitoring communication power supply Monitoring device.
Hardware timeout works according to the frequency of the quartz oscillator on equipment mainboard, after equipment shutdown, firmly The part time is still run.Hardware timeout is set to GMT (Greenwich Mean Time, abbreviation GMT the standard time in), i.e. zero zone time.
Step S120, determines the corresponding time zone parameter of equipment.
Time zone parameter is used for the parameter for representing the affiliated time zone in geographical position of equipment.
Time zone parameter includes:GMT+0, GMT+1~GMT+12, GMT+3.5, GMT+4.5, GMT+5.5, GMT+9.5, GMT-1~GMT-12, GMT-3.5, totally 30 time zone parameters.One time zone parameter correspondence One time zone.GMT in the parameter of time zone can regard hardware timeout as, and numeral is the time zone where equipment. Hardware timeout+time zone parameter=system time.When being added, the hour in hardware timeout is set to add time zone.
Obtain the geographical position of the equipment;The geographical position is that user sets the either equipment Location data;Determine the corresponding time zone parameter in the geographical position;Or, it is pre-configured with multiple time zone parameters; The time zone parameter that user is selected is used as the corresponding time zone parameter of the equipment.
Further, area file when being pre-configured with multiple;Wherein, when area file includes one when each described Area's parameter;The when area file selected according to user in area file when the multiple, determines the equipment correspondence Time zone parameter.For example:There are 30 time zones, then area file when correspondence configures 30, each time zone text Part includes the time zone parameter in correspondence time zone;When which user selects area file just by when area file in time zone join Number is used as the corresponding time zone parameter of equipment.
Step S130, according to the hardware timeout and the time zone parameter, calculates system time and the display of the equipment.
System time refers to:The time of the operating system of equipment.The system time is generally geography where equipment The local zone time of position.
After hardware timeout and time zone parameter is obtained, default time zone processing function is called, calculating is needed The system time to be shown.For example processing function in the time zone makes hardware timeout+time zone parameter=system time.
During the system time of the equipment is shown, whether the corresponding time zone parameter of the equipment is detected Change;If it is, current hardware timeout is read, after current hardware timeout and change Time zone parameter, corrects system time and the display of the equipment.Time zone parameter after change can be according to current Hardware timeout and current system time determine, can also be determined according to the selection of user.
According to embodiments of the present invention can be it is determined that after the corresponding time zone parameter of equipment, equipment be set automatically System time, makes system time adapt to the time zone residing for equipment, it is to avoid residing for the system time and equipment of equipment The problem of there is time difference initiation between the local zone time in geographical position.
In order that the present invention becomes apparent from, a more specific embodiment is given below, to enter to the present invention Row is further described through.The present embodiment is by taking Power Supply Monitoring equipment as an example, and the Power Supply Monitoring equipment carries liquid crystal Show device and hardware real time clock chip module.There is provided hard for hardware real time clock chip module operation hardware clock The part time.
As shown in Fig. 2 being the particular flow sheet of the system time setting method according to one embodiment of the invention.
Step S210, the power supply monitoring system of startup power supply monitoring device reads hardware timeout.
After power supply monitoring system starts, hardware timeout is read from hardware real time clock chip module.
The form of hardware timeout is:Year/Month/Day/when/point/second.For example:When 2016/March/10 day/15/30 Divide/20 seconds.The form of certain hardware timeout can be adjusted according to the custom of user.
Step S220, determines area file and time zone parameter when Power Supply Monitoring equipment is corresponding, and set up time zone ginseng Number and when area file relation array.
Initialising subscriber parameter;Obtain the geographical position that the Power Supply Monitoring equipment of user's selection is presently in;Root The geographical position being presently according to Power Supply Monitoring equipment, determines area file when the geographical position is corresponding, namely It is area file when Power Supply Monitoring equipment is corresponding;Time zone parameter is obtained in area file at this, to determine power supply The corresponding time zone parameter of monitoring device;The time zone parameter and this when area file between set up mapping relations, and It is stored among relation array.
For example:Initialize the geographical position residing for Power Supply Monitoring equipment and system time;It is user in advance Geographical location choice menu is set, the geographical position that user chooses in selection menu, such as Beijing is determined;Root The geographical position chosen according to user determines area file during correspondence eastern 8th area of the geographical position, the area time zones of Gai Dong eight text The time zone parameter stored in part is GMT+8;The area file at time zone parameter 8th area of GMT+8 and Gai Dong Between set up mapping relations, and be stored in array, obtain [GMT+8, area file during eastern 8th area].
Step S230, according to time zone parameter and hardware timeout, calculates the system time of Power Supply Monitoring equipment and shows Show.
The system time is the time of power supply monitoring system.
Numeral in the parameter of time zone is added with the hour in hardware timeout, the system for obtaining Power Supply Monitoring equipment Time.The form of system time is identical with the form of hardware timeout.
Step S240, while showing the system time, whether detection relation array changes;If so, Then perform step S250;If it is not, then continuing executing with step S240.
Area file when being reselected due to user, can cause relation array to change, so real time scan is closed Coefficient sets, judge whether the content in relation array changes, and that is to say and are selected the last time compared to user When area file, judge whether the when area file that user currently selects changes.
Step S250, is modified according to the time zone parameter after change to system time.
The Current hardware time is read, using the time zone parameter after change and Current hardware time, during update the system Between, and show revised system time.
Using the method for the invention, field maintenance person can be the corresponding time zone of Power Supply Monitoring device configuration Parameter, power supply monitoring system can update system time automatically according to time zone parameter and show in a liquid crystal display Show, reduce the time required for system initial launch, and cause communication power supply foreground monitoring software and The time format of background net management is consistent, is not in the time difference, improves the experience of user.
It is to be implemented according to the present invention one as shown in Figure 3 present invention also offers a kind of system time setting device The structure chart of the system time setting device of example.
The device includes:
Read module 310, the hardware timeout for reading equipment.The equipment includes:Power Supply Monitoring equipment.
Determining module 320, for determining the corresponding time zone parameter of the equipment.
Calculate and display module 330, for according to the hardware timeout and the time zone parameter, calculating described The system time of equipment and display.
In one embodiment, determining module 320, specifically for being pre-configured with multiple time zone parameters;It will use The time zone parameter of family selection is used as the corresponding time zone parameter of the equipment.
In another embodiment, determining module 320, the geographical position specifically for obtaining the equipment;Really Determine the corresponding time zone parameter in the geographical position.
In another embodiment, calculate and display module 330, be additionally operable to when showing the system of the equipment Between during, detect whether the corresponding time zone parameter of the equipment changes;If it is, according to work as Time zone parameter after preceding hardware timeout and change, corrects system time and the display of the equipment.
The function of device described in the present embodiment is retouched in the embodiment of the method shown in Fig. 1-Fig. 2 State, therefore not detailed part in the description of the present embodiment, the related description in previous embodiment is may refer to, This is not repeated.
Although being example purpose, the preferred embodiments of the present invention are had been disclosed for, those skilled in the art will Recognize that various improvement, increase and substitution are also possible, therefore, the scope of the present invention should be not limited to State embodiment.

Claims (10)

1. a kind of system time setting method, it is characterised in that including:
Read the hardware timeout of equipment;
Determine the corresponding time zone parameter of the equipment;
According to the hardware timeout and the time zone parameter, system time and the display of the equipment are calculated.
2. the method as described in claim 1, it is characterised in that determine the corresponding time zone ginseng of the equipment Number, including:
It is pre-configured with multiple time zone parameters;
The time zone parameter that user is selected is used as the corresponding time zone parameter of the equipment.
3. the method as described in claim 1, it is characterised in that determine the corresponding time zone ginseng of the equipment Number, including:
Obtain the geographical position of the equipment;
Determine the corresponding time zone parameter in the geographical position.
4. the method as described in claim 1, it is characterised in that showing the system time of the equipment During, in addition to:
Detect whether the corresponding time zone parameter of the equipment changes;
If it is, according to the time zone parameter after current hardware timeout and change, correct the equipment is The system time simultaneously shows.
5. the method as any one of claim 1-4, it is characterised in that the equipment includes: Power Supply Monitoring equipment.
6. a kind of system time setting device, it is characterised in that including:
Read module, the hardware timeout for reading equipment;
Determining module, for determining the corresponding time zone parameter of the equipment;
Calculate and display module, for according to the hardware timeout and the time zone parameter, calculating the equipment System time and display.
7. device as claimed in claim 6, it is characterised in that the determining module specifically for:
It is pre-configured with multiple time zone parameters;
The time zone parameter that user is selected is used as the corresponding time zone parameter of the equipment.
8. device as claimed in claim 6, it is characterised in that the determining module specifically for:
Obtain the geographical position of the equipment;
Determine the corresponding time zone parameter in the geographical position.
9. device as claimed in claim 6, it is characterised in that the calculating and display module, is also used During the system time for showing the equipment, whether the corresponding time zone parameter of the detection equipment is sent out Changing;If it is, according to the time zone parameter after current hardware timeout and change, correcting the equipment System time and display.
10. the device as any one of claim 6-9, it is characterised in that the equipment includes: Power Supply Monitoring equipment.
CN201610190969.9A 2016-03-30 2016-03-30 A kind of system time setting method and device Withdrawn CN107290950A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201610190969.9A CN107290950A (en) 2016-03-30 2016-03-30 A kind of system time setting method and device
PCT/CN2017/074160 WO2017166950A1 (en) 2016-03-30 2017-02-20 System time setting method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610190969.9A CN107290950A (en) 2016-03-30 2016-03-30 A kind of system time setting method and device

Publications (1)

Publication Number Publication Date
CN107290950A true CN107290950A (en) 2017-10-24

Family

ID=59963393

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610190969.9A Withdrawn CN107290950A (en) 2016-03-30 2016-03-30 A kind of system time setting method and device

Country Status (2)

Country Link
CN (1) CN107290950A (en)
WO (1) WO2017166950A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156233A (en) * 2017-12-20 2018-06-12 惠州Tcl家电集团有限公司 Data processing method, device and computer readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11136755A (en) * 1997-10-28 1999-05-21 Fujitsu Ltd Time correction method and portable telephone terminal used for the method
CN1407417A (en) * 2001-09-10 2003-04-02 英华达股份有限公司 Method for changing time of communication device with global positioning system
CN1812451A (en) * 2005-01-28 2006-08-02 乐金电子(中国)研究开发中心有限公司 Time set method of mobile termial
CN101631375A (en) * 2009-08-03 2010-01-20 深圳华为通信技术有限公司 Method for indicating change of time zone and movable terminal with function for indicating change of time zone
CN101867867A (en) * 2009-04-16 2010-10-20 深圳富泰宏精密工业有限公司 System time automatic updating system and method
CN102100111A (en) * 2008-07-16 2011-06-15 诺基亚公司 Methods, apparatuses and computer program products for providing temporal information

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW502161B (en) * 2001-04-24 2002-09-11 Inventec Appliances Corp Method of automatically updating time to a local time when reaching a new time zone
US7197635B2 (en) * 2003-09-04 2007-03-27 International Business Machines Corporation Method and apparatus for providing updated time at a data processing system
CN101287004A (en) * 2008-05-29 2008-10-15 宇龙计算机通信科技(深圳)有限公司 Mobile terminal, method and system for updating system time thereof
CN102830611B (en) * 2012-09-05 2014-10-22 飞亚达(集团)股份有限公司 Time source
CN103077067B (en) * 2012-12-26 2016-03-30 华为技术有限公司 Dummy machine system time defining method, device and equipment
CN105407219A (en) * 2015-10-30 2016-03-16 努比亚技术有限公司 Time updating method and device of mobile terminal

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11136755A (en) * 1997-10-28 1999-05-21 Fujitsu Ltd Time correction method and portable telephone terminal used for the method
CN1407417A (en) * 2001-09-10 2003-04-02 英华达股份有限公司 Method for changing time of communication device with global positioning system
CN1812451A (en) * 2005-01-28 2006-08-02 乐金电子(中国)研究开发中心有限公司 Time set method of mobile termial
CN102100111A (en) * 2008-07-16 2011-06-15 诺基亚公司 Methods, apparatuses and computer program products for providing temporal information
CN101867867A (en) * 2009-04-16 2010-10-20 深圳富泰宏精密工业有限公司 System time automatic updating system and method
CN101631375A (en) * 2009-08-03 2010-01-20 深圳华为通信技术有限公司 Method for indicating change of time zone and movable terminal with function for indicating change of time zone

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156233A (en) * 2017-12-20 2018-06-12 惠州Tcl家电集团有限公司 Data processing method, device and computer readable storage medium

Also Published As

Publication number Publication date
WO2017166950A1 (en) 2017-10-05

Similar Documents

Publication Publication Date Title
CN105957125B (en) A kind of processing method and mobile terminal of icon text
US20100088498A1 (en) System and method for managing hardware configuration parameters
WO2016192188A1 (en) Method and terminal for adjusting cpu operation parameter
CN106444451B (en) Food taking and placing prompting method and device in intelligent electric cooker
CN102981551B (en) A kind of temperature compensation system for real-time clock and method
CN107290950A (en) A kind of system time setting method and device
JP2009031041A (en) Positioning error occurrence determination method, located position output control method, positioning method, program, storage medium and positioning device
US20190149156A1 (en) Method and Device for Calibrating RC Oscillator, Storage Medium and Processor
CN109040820A (en) Method for synchronizing time, device, smart television and computer readable storage medium
CN105634473A (en) Method and device for adjusting frequency of mobile terminal
CN105227195A (en) A kind of automatic frequency calibration system and calibration steps and mobile terminal
CN107222269A (en) A kind of GSM APC quick accurate calibration implementation methods based on saturation PA
CN115268564B (en) Method, system, apparatus, and medium for calibrating chip circuits
US20180007635A1 (en) Closed-loop clock calibration method, terminal and computer storage medium
CN109799872A (en) Improve the method, apparatus and electronic equipment of low-res real-time clock waking-up precision
CN109581859A (en) A kind of automatic correcting time method and device
KR101367261B1 (en) Wireless Module appling Time synchronization Embedded Blood Glucose Test Meter system
CN105099582B (en) A kind of load setting method and system
CN113014724B (en) Dual-connection mode starting method and device, mobile terminal and readable storage medium
CN110876178A (en) Calibration method and device for 32K clock
CN107977224B (en) Application program configuration method, device, server and storage medium
CN112416756A (en) Clock error testing method, device and equipment for vehicle-mounted system
CN106130815A (en) Board level test method and device
US20060133553A1 (en) Method for automatically detecting the clock frequency of a system clock pulse for the configuration of a peripheral device
US20140163917A1 (en) Multi-sensing-elements calibration system, multi-sensing-elements calibration method and recording medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication

Application publication date: 20171024

WW01 Invention patent application withdrawn after publication