CN110320992B - Method for configuring and managing power consumption - Google Patents
Method for configuring and managing power consumption Download PDFInfo
- Publication number
- CN110320992B CN110320992B CN201910584013.0A CN201910584013A CN110320992B CN 110320992 B CN110320992 B CN 110320992B CN 201910584013 A CN201910584013 A CN 201910584013A CN 110320992 B CN110320992 B CN 110320992B
- Authority
- CN
- China
- Prior art keywords
- operating system
- hardware
- value
- power consumption
- temporary
- 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.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3206—Monitoring of events, devices or parameters that trigger a change in power modality
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3234—Power saving characterised by the action undertaken
- G06F1/3237—Power saving characterised by the action undertaken by disabling clock generation or distribution
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Power Sources (AREA)
Abstract
The embodiment of the invention relates to a method for configuring and managing power consumption, which is characterized by comprising the following steps: acquiring a first power consumption configuration instruction; generating first and second instruction parameters; when the first instruction parameter is a single device identifier, performing single device power consumption management processing, generating a first instruction state according to an execution result, and sending the first instruction state to the upper computer; and when the first instruction parameter is a full-equipment identifier, performing full-equipment power consumption management processing, generating a first result list according to an execution result, and when the first result list is not empty, sending the first result list to the upper computer. The power consumption configuration instruction of the method can be used for carrying out clock shutdown or on-off on a single hardware device, and can also be used for carrying out batch clock operation on all hardware devices on the singlechip in a configuration file mode. The singlechip using the method of the invention does not need to upgrade software and hardware under the working environment with different power consumption requirements, and can complete the complete machine power consumption state switching only by setting a configuration file.
Description
Technical Field
The invention relates to the field of singlechip design, in particular to a method for configuring and managing power consumption.
Background
In the application of the financial payment industry, a plurality of singlechips are integrated with a plurality of hardware functional modules. In the financial payment industry, requirements on the execution speed or the power consumption state of a hardware module of the device are different due to different application scenes of the device. The equipment applied to the data center has high requirements on the execution performance of a hardware module and is insensitive to the power consumption requirement; the device applied to the merchant or the device in the mobile payment field has lower requirements on the execution performance of the hardware module and higher requirements on power consumption; the method is applied to the field of special passwords, and requires that part of hardware modules are in a high-performance state and part of hardware modules are in a low-power consumption state. In the prior art, for a single chip microcomputer integrating multiple hardware modules, different models can be provided to meet the requirements on the same hardware module integration level: a full-load high-performance product, a low-power product and a part of low-power products. The method invisibly increases the design and maintenance cost of products for production manufacturers and also reduces the difficulty of updating and updating application equipment.
Disclosure of Invention
The present invention provides a method for configuring and managing power consumption, which can respectively open and close clocks of each hardware module on a single chip, and can also perform unified deployment of opening/closing clocks for all hardware modules in batch at one time. Therefore, the combination of various schemes such as full power consumption reduction, full maximum performance reduction, selective power consumption reduction and the like on the same single chip microcomputer is realized: in a use environment which always needs high-performance configuration, the method can be realized by configuring a full switch; in the use environment requiring low power consumption, the switch can be completely closed or a front switch and a rear switch are used.
To achieve the above object, the present invention provides a method for configuring and managing power consumption, comprising:
the method comprises the steps that an operating system obtains a first power consumption configuration instruction sent by an upper computer;
the operating system disassembles the first power consumption configuration instruction to generate a first instruction parameter and a second instruction parameter;
when the first instruction parameter is a single device identifier, the operating system performs single device power consumption management processing according to the second instruction parameter; generating a first instruction state according to an execution result of the single-device power consumption management; sending the first instruction state to the upper computer;
when the first instruction parameter is a full-equipment identifier, the operating system performs full-equipment power consumption management processing according to the second instruction parameter; generating a first result list according to the execution result of the full equipment power consumption management; and when the first result list is not empty, the operating system sends the first result list to the upper computer.
Further, the method further comprises:
and when the first result list is empty, the operating system quits the processing and sends error information that the result list is empty to the upper computer.
Further, the operating system disassembles the first power consumption configuration instruction to generate a first instruction parameter and a second instruction parameter, and specifically includes:
the operating system disassembles the first power consumption configuration instruction, acquires a first instruction parameter byte, and generates a first instruction parameter; and acquiring a second instruction parameter byte and generating the second instruction parameter.
Further, when the first instruction parameter is a single device identifier, the operating system performs single device power consumption management processing according to the second instruction parameter; generating a first instruction state according to an execution result of the single-device power consumption management; and sending the first instruction state to the upper computer, specifically including:
when the first instruction parameter is a single device identifier, the operating system extracts all bytes of the first instruction parameter according to the first instruction parameter to generate a first hardware identifier, and extracts all bytes of the second instruction parameter according to the second instruction parameter to generate a first switch;
the operating system carries out single-device power consumption management processing on the hardware specified by the value of the first hardware identifier according to the first switch;
the operating system generates the first instruction state according to the execution result of the single-device power consumption management;
and the operating system sends the first instruction state to the upper computer.
Preferably, the operating system performs, according to the first switch, single device power consumption management processing on the hardware specified by the value of the first hardware identifier, specifically including:
when the value of the first switch is the starting clock, the operating system carries out clock starting processing on a clock input signal of the hardware specified by the value of the first hardware identifier;
and when the value of the first switch is the closing clock, the operating system carries out clock closing processing on the clock input signal of the hardware specified by the value of the first hardware identifier.
Further, when the first instruction parameter is a full device identifier, the operating system performs full device power consumption management processing according to the second instruction parameter; generating a first result list according to the execution result of the full equipment power consumption management; when the first result list is not empty, the operating system sends the first result list to the upper computer, and the method specifically includes:
when the first instruction parameter is a full-equipment identifier, the operating system extracts all bytes of the second instruction parameter according to the second instruction parameter to generate a first configuration file identifier;
the operating system acquires all configuration record bytes of the first configuration file according to the first configuration file specified by the value of the first configuration file identifier, and generates a first hardware list;
when the first hardware list is not empty, the operating system performs power consumption management processing of the whole equipment according to the first hardware list, and generates a first result list according to an execution result of the power consumption management of the whole equipment;
and when the first result list is not empty, the operating system sends the first result list to the upper computer.
Preferably, the operating system obtains all configuration record bytes of the first configuration file according to the first configuration file specified by the value of the first configuration file identifier, and generates the first hardware list, specifically including:
step 71, the operating system obtains the total number of file records of the first configuration file according to the first configuration file, and generates a first total number of records;
step 72, the operating system initializes the value of the first record index to 0, and initializes the first temporary list to null;
step 73, the operating system acquires the first record index configuration record byte of the first configuration file according to the first configuration file, and generates a first configuration record;
step 74, the operating system adds the first configuration record to the first temporary manifest;
step 75, the operating system adds 1 to the value of the first record index;
step 76, determining whether the value of the first record index is greater than the value of the first total number of records, and going to step 77 when the value of the first record index is greater than the value of the first total number of records; when the value of the first record index is less than or equal to the value of the first record total number, go to step 73;
and 77, the operating system extracts all bytes of the first temporary list according to the first temporary list to generate the first hardware list.
Preferably, when the first hardware list is not empty, the operating system performs a full device power consumption management process according to the first hardware list, and generates the first result list according to an execution result of the full device power consumption management, which specifically includes:
step 81, when the first hardware list is not empty, the operating system obtains the total number of file records of the first hardware list according to the first hardware list, and generates a second total number of records;
step 82, initializing a value of a second record index to be 0 and initializing the second temporary list to be null by the operating system;
step 83, the operating system obtains the second record index configuration record byte of the first hardware list according to the first hardware list, and generates a second configuration record;
step 84, the operating system disassembles the second configuration record, extracts the first temporary hardware identifier byte of the second configuration record to generate a first temporary hardware identifier, and extracts the first temporary switch byte of the second configuration record to generate a first temporary switch;
step 85, the operating system performs clock switching processing on the hardware specified by the value of the first temporary hardware identifier according to the first temporary switch, and generates a first temporary state according to an execution result of the clock switching;
step 86, the operating system performs sequential byte splicing processing on the first temporary hardware identifier, the first temporary switch and the first temporary state to generate a first temporary result record;
step 87, the operating system adds the first temporary result record to the second temporary list;
step 88, the operating system adds 1 to the value of the second record index;
step 89, judging whether the value of the second record index is greater than the value of the second record total number, and turning to step 90 when the value of the second record index is greater than the value of the second record total number; when the value of the second record index is less than or equal to the value of the second record total number, go to step 83;
and step 90, the operating system extracts all bytes of the second temporary list according to the second temporary list to generate the first result list.
Further preferably, in the step 85, the performing, by the operating system, clock switching processing on the hardware specified by the value of the first temporary hardware identifier according to the first temporary switch, and generating a first temporary state according to an execution result of the clock switching specifically includes:
when the value of the first temporary switch is a start clock, the operating system performs clock start processing on a clock input signal of hardware specified by the value of the first temporary hardware identifier, and generates the first temporary state according to an execution result of the clock start;
and when the value of the first temporary switch is the closing clock, the operating system performs clock closing processing on a clock input signal of the hardware specified by the value of the first temporary hardware identifier, and generates the first temporary state according to an execution result of the clock closing.
The invention provides a method for configuring and managing power consumption, which provides different equipment power consumption configuration modes by identifying whether a first parameter of a power consumption configuration instruction is a single equipment identifier or a full equipment identifier: single device configuration mode and full device configuration mode. The single device configuration mode is to perform on/off operation on a clock input signal of a single hardware module; the full-equipment configuration mode is to carry out on/off operation on clock input signals of all hardware modules according to a first hardware list provided by a configuration file.
Drawings
FIG. 1 is a schematic diagram of a power consumption configuration instruction according to the present invention;
FIG. 2 is a schematic diagram of a configuration file provided by the present invention;
fig. 3 is a schematic diagram illustrating an operation of a method for configuring and managing power consumption according to an embodiment of the present invention;
fig. 4 is a schematic diagram illustrating an operation of a method for configuring and managing power consumption according to a second embodiment of the present invention;
fig. 5 is a schematic diagram illustrating an operation of a method for configuring and managing power consumption according to a third embodiment of the present invention;
FIG. 6 is a diagram of a result list provided by the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The single chip microcomputer integrates a plurality of hardware modules, and the whole power consumption is superposed by the independent power consumption of the hardware modules forming the single chip microcomputer. For each hardware module, the power consumption is highest in the working state, and the internal circuit power consumption can be stopped by closing the clock input signal of the module in the non-working state, so that the purpose of reducing the power consumption is achieved. The specific implementation is realized by setting a clock switch through a clock gating circuit. In the prior art, although hardware modules are provided with clock gating circuits, a flexible management mechanism is lacked in the aspect of a hardware management layer of an upper operating system, so that a single chip microcomputer is initialized once in a fixed configuration mode when leaving a factory. Aiming at the technical defects, the method of the invention fully utilizes the settability of the clock gating circuit to establish a set of management mechanism which can carry out flexible configuration through software and configuration files, and the mechanism provides a special power consumption configuration instruction for a user to operate.
Fig. 1 is a schematic diagram of the power consumption configuration instruction provided by the present invention, where the power consumption configuration instruction includes two parameters: a first instruction parameter and a second instruction parameter. The method of the invention distinguishes two configuration modes through the value of the first instruction parameter: when the value of the first instruction parameter is a specific full-equipment identifier, configuring a mode for the full equipment; and when the value of the first instruction parameter is not the specific full equipment identification, the single equipment mode is adopted. Here, the value of the full device identification is generally defined as a constant of one fixed value.
In the single device mode, the value of the first instruction parameter characterizes a hardware identification and the value of the second instruction parameter characterizes a switch. The value of the hardware identifier is used for uniquely marking a hardware module in the single chip, and the value of the switch is used for representing the specific opening or closing operation requirement of the clock gating circuit on the clock input signal of the hardware module. When the value of the switch is to start the clock, the clock gating circuit is used for carrying out clock starting processing on the clock input signal of the hardware module; and when the value of the switch is closed, performing clock closing processing on a clock input signal of the hardware module through the clock gating circuit. After the operation of the clock input signal is finished, the operating system sends the execution return state of the clock operation as power consumption configuration instruction execution return information to the upper computer.
In the full device mode, the value of the second instruction parameter represents the file identifier of the configuration file, and the operating system locates the configuration file through the second instruction parameter. As shown in fig. 2, which is a schematic diagram of a configuration file provided by the present invention, the configuration file is composed of a plurality of configuration records, and each configuration record is composed of two fixed data items: hardware identification and switches. Each record corresponds to the clock operation of a unique hardware module, and is equivalent to an independent power consumption configuration instruction in the single-device mode. The operating system extracts all records of the configuration file to generate a hardware list, wherein the structure of the hardware list is completely consistent with the configuration file; according to the hardware identifier and the switching parameter of each record in the hardware list, sequentially carrying out clock on/off operation on the hardware module corresponding to the record; after each record operation is completed, an execution result is generated for the execution return state of each record, and the hardware identification, the switch and the execution result are sequentially assembled to form a result record and are added into a result list; after all operations of the hardware list are completed, the operating system sends the complete result list as power consumption configuration instruction execution return information back to the upper computer.
In an embodiment of the present invention, as shown in fig. 3, which is a working schematic diagram of a method for configuring and managing power consumption provided in the first embodiment of the present invention, the method includes the following steps:
and step 111, the operating system acquires a first power consumption configuration instruction sent by the upper computer.
the method specifically comprises the following steps: the operating system disassembles the first power consumption configuration instruction, acquires a first instruction parameter byte and generates a first instruction parameter; and acquiring a second instruction parameter byte and generating a second instruction parameter.
200, the operating system performs single-device power consumption management processing according to the first instruction parameter and the second instruction parameter; generating a first instruction state according to an execution result of the power consumption management of the single device; and sends a first instruction state to the upper computer.
In the second embodiment of the present invention, as shown in fig. 4, which is a working schematic diagram of a method for configuring and managing power consumption provided in the second embodiment of the present invention, the method includes the following steps:
in step 211, the operating system obtains a first power consumption configuration instruction sent from the upper computer.
the method specifically comprises the following steps: the operating system disassembles the first power consumption configuration instruction, acquires a first instruction parameter byte and generates a first instruction parameter; and acquiring a second instruction parameter byte and generating a second instruction parameter.
the method specifically comprises the following steps: when the value of the first switch is the starting clock, the operating system carries out clock starting processing on a clock input signal of the hardware specified by the value of the first hardware identifier; and when the value of the first switch is the closing clock, the operating system carries out clock closing processing on the clock input signal of the hardware specified by the value of the first hardware identifier.
In step 215, after the single device power management process is successfully executed, the operating system generates a first instruction state according to the execution result of the single device power management.
In a third embodiment of the present invention, as shown in fig. 5, which is a working schematic diagram of a method for configuring and managing power consumption provided in the third embodiment of the present invention, the method includes the following steps:
in step 322, the operating system obtains a first power consumption configuration instruction sent from the upper computer.
the method specifically comprises the following steps: the operating system disassembles the first power consumption configuration instruction, wherein an instruction structure of the first power consumption configuration instruction is shown in fig. 1, the operating system extracts a first instruction parameter byte to generate a first instruction parameter, and extracts a second instruction parameter byte to generate a second instruction parameter.
In step 324, when the value of the first parameter is the full device identifier, the operating system extracts all bytes of the second instruction parameter according to the second instruction parameter to generate a first configuration file identifier.
the method specifically comprises the following steps: step A1, the operating system obtains the total number of file records of the first configuration file according to the first configuration file, and generates a first total number of records;
step A2, the operating system initializes the value of the first record index to 0 and initializes the first temporary list to null;
step A3, the operating system obtains the first record index record byte of the first configuration file according to the first configuration file, and generates a first configuration record;
step A4, adding a first configuration record to the first temporary list by the operating system;
step A5, the operating system adds 1 to the value of the first record index;
step A6, determining whether the value of the first record index is greater than the value of the first record total number, and if the value of the first record index is greater than the value of the first record total number, turning to step A7; when the value of the first record index is less than or equal to the value of the first record total number, go to step a 3;
step A7, the operating system extracts all bytes of the first temporary list according to the first temporary list to generate a first hardware list.
the method specifically comprises the following steps: step B1, when the first hardware list is not empty, the operating system obtains the total number of file records of the first hardware list according to the first hardware list, and generates a second total number of records;
step B2, the operating system initializes the value of the second record index to 0 and initializes the second temporary list to null;
step B3, the operating system obtains the second record index record byte of the first hardware list according to the first hardware list, and generates the second configuration record;
step B4, the operating system disassembles the second configuration record, extracts the first temporary hardware identification byte of the second configuration record to generate a first temporary hardware identification, extracts the first temporary switch byte of the second configuration record to generate a first temporary switch;
step B5, the operating system performs clock switching processing to the hardware specified by the value of the first temporary hardware identifier according to the first temporary switch, and generates a first temporary state according to the execution result of the clock switching,
the method specifically comprises the following steps: step C1, when the value of the first temporary switch is to start the clock, the operating system performs clock start processing on the clock input signal of the hardware specified by the value of the first temporary hardware identifier, and generates a first temporary state according to the execution result of the clock start;
step C2, when the value of the first temporary switch is to close the clock, the operating system closes the clock to the clock input signal of the hardware appointed by the value of the first temporary hardware identification, and generates the first temporary state according to the execution result of the clock closing;
step B6, the operating system carries out sequential byte splicing processing on the first temporary hardware identifier, the first temporary switch and the first temporary state to generate a first temporary result record;
step B7, the operating system adds the first temporary result record to the second temporary list;
step B8, the operating system adds 1 to the value of the second record index;
step B9, determining whether the value of the second record index is greater than the value of the second record total number, and going to step B10 when the value of the second record index is greater than the value of the second record total number; when the value of the second record index is less than or equal to the value of the second record total number, go to step B3;
in step B10, the operating system extracts all bytes of the second temporary list according to the second temporary list to generate a first result list, and the data structure of the first result list is as shown in fig. 6.
The main reason for the occurrence of the error is that the first configuration file fails to be located; or the first configuration file fails to be read; or the first profile content is empty.
The main reason for the occurrence of such errors is that adding a record to a record list in the configuration process fails; or after the configuration process fails and no return leads to timeout, the system forcibly ends the configuration process.
The embodiment of the invention provides a method for configuring and managing power consumption, which can be used for setting and switching each hardware module on a single chip microcomputer to reduce the power consumption and can also be used for setting and switching in batches at one time. By the configuration management method provided by the embodiment of the invention, the combination of various states such as full low power consumption, full high performance, selectivity high performance and the like is realized on the same singlechip. The design and production and manufacturing cost of the equipment is further reduced, and the autonomous flexibility of upgrading and maintaining is improved.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied in hardware, a software module executed by a processor, or a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The above-mentioned embodiments are intended to illustrate the objects, technical solutions and advantages of the present invention in further detail, and it should be understood that the above-mentioned embodiments are merely exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made within the spirit and principle of the present invention should be included in the scope of the present invention.
Claims (8)
1. A method of configuration management power consumption, the method comprising:
the method comprises the steps that an operating system obtains a first power consumption configuration instruction sent by an upper computer;
the operating system disassembles the first power consumption configuration instruction to generate a first instruction parameter and a second instruction parameter;
when the first instruction parameter is a single device identifier, the operating system performs single device power consumption management processing according to the second instruction parameter; generating a first instruction state according to an execution result of the single-device power consumption management; sending the first instruction state to the upper computer;
when the first instruction parameter is a full-equipment identifier, the operating system performs full-equipment power consumption management processing according to the second instruction parameter; generating a first result list according to the execution result of the full equipment power consumption management; when the first result list is not empty, the operating system sends the first result list to the upper computer;
when the first instruction parameter is a full-equipment identifier, the operating system performs full-equipment power consumption management processing according to the second instruction parameter; generating a first result list according to the execution result of the full equipment power consumption management; when the first result list is not empty, the operating system sends the first result list to the upper computer, and the method specifically includes: when the first instruction parameter is the all-equipment identifier, the operating system extracts all bytes of the second instruction parameter according to the second instruction parameter to generate a first configuration file identifier; the operating system acquires all configuration record bytes of the first configuration file according to the first configuration file specified by the value of the first configuration file identifier, and generates a first hardware list; when the first hardware list is not empty, the operating system performs power consumption management processing of the whole equipment according to the first hardware list, and generates a first result list according to an execution result of the power consumption management of the whole equipment; and when the first result list is not empty, the operating system sends the first result list to the upper computer.
2. The method of claim 1, further comprising:
and when the first result list is empty, the operating system quits the processing and sends error information that the result list is empty to the upper computer.
3. The method according to claim 1, wherein the operating system disassembles the first power consumption configuration instruction to generate a first instruction parameter and a second instruction parameter, specifically comprising:
the operating system disassembles the first power consumption configuration instruction, acquires a first instruction parameter byte, and generates a first instruction parameter; and acquiring a second instruction parameter byte and generating the second instruction parameter.
4. The method according to claim 1, wherein when the first instruction parameter is a single device identifier, the operating system performs single device power consumption management processing according to the second instruction parameter; generating a first instruction state according to an execution result of the single-device power consumption management; and sending the first instruction state to the upper computer, specifically including:
when the first instruction parameter is a single device identifier, the operating system extracts all bytes of the first instruction parameter according to the first instruction parameter to generate a first hardware identifier, and extracts all bytes of the second instruction parameter according to the second instruction parameter to generate a first switch;
the operating system carries out single-device power consumption management processing on the hardware specified by the value of the first hardware identifier according to the first switch;
the operating system generates the first instruction state according to the execution result of the single-device power consumption management;
and the operating system sends the first instruction state to the upper computer.
5. The method according to claim 4, wherein the operating system performs, according to the first switch, single device power consumption management processing on the hardware specified by the value of the first hardware identifier, specifically including:
when the value of the first switch is the starting clock, the operating system carries out clock starting processing on a clock input signal of the hardware specified by the value of the first hardware identifier;
and when the value of the first switch is the closing clock, the operating system carries out clock closing processing on the clock input signal of the hardware specified by the value of the first hardware identifier.
6. The method according to claim 1, wherein the operating system obtains all configuration record bytes of the first configuration file according to the first configuration file specified by the value of the first configuration file identifier, and generates a first hardware manifest, specifically including:
step 71, the operating system obtains the total number of file records of the first configuration file according to the first configuration file, and generates a first total number of records;
step 72, the operating system initializes the value of the first record index to 0 and initializes the first temporary list to null;
step 73, the operating system obtains the first record index record byte of the first configuration file according to the first configuration file, and generates a first configuration record;
step 74, the operating system adds the first configuration record to the first temporary manifest;
step 75, the operating system adds 1 to the value of the first record index;
step 76, determining whether the value of the first record index is greater than the value of the first total number of records, and going to step 77 when the value of the first record index is greater than the value of the first total number of records; when the value of the first record index is less than or equal to the value of the first record total number, go to step 73;
and 77, the operating system extracts all bytes of the first temporary list according to the first temporary list to generate the first hardware list.
7. The method according to claim 1, wherein when the first hardware list is not empty, the operating system performs a full device power consumption management process according to the first hardware list, and generates the first result list according to an execution result of the full device power consumption management, specifically including:
step 81, when the first hardware list is not empty, the operating system obtains the total number of file records of the first hardware list according to the first hardware list, and generates a second total number of records;
step 82, the operating system initializes the value of the second record index to 0 and initializes the second temporary list to null;
step 83, the operating system obtains the second record index record byte of the first hardware list according to the first hardware list, and generates a second configuration record;
step 84, the operating system disassembles the second configuration record, extracts the first temporary hardware identifier byte of the second configuration record to generate a first temporary hardware identifier, and extracts the first temporary switch byte of the second configuration record to generate a first temporary switch;
step 85, the operating system performs clock switching processing on the hardware specified by the value of the first temporary hardware identifier according to the first temporary switch, and generates a first temporary state according to an execution result of the clock switching;
step 86, the operating system performs sequential byte splicing processing on the first temporary hardware identifier, the first temporary switch and the first temporary state to generate a first temporary result record;
step 87, the operating system adds the first temporary result record to the second temporary list;
step 88, the operating system adds 1 to the value of the second record index;
step 89, judging whether the value of the second record index is greater than the value of the second record total number, and turning to step 90 when the value of the second record index is greater than the value of the second record total number; when the value of the second record index is less than or equal to the value of the second record total number, go to step 83;
and step 90, the operating system extracts all bytes of the second temporary list according to the second temporary list to generate the first result list.
8. The method according to claim 7, wherein in step 85, the operating system performs clock switching processing on the hardware specified by the value of the first temporary hardware identifier according to the first temporary switch, and generates a first temporary state according to an execution result of the clock switching, specifically including:
when the value of the first temporary switch is a start clock, the operating system performs clock start processing on a clock input signal of hardware specified by the value of the first temporary hardware identifier, and generates the first temporary state according to an execution result of the clock start;
and when the value of the first temporary switch is the closing clock, the operating system performs clock closing processing on a clock input signal of the hardware specified by the value of the first temporary hardware identifier, and generates the first temporary state according to an execution result of the clock closing.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910584013.0A CN110320992B (en) | 2019-06-28 | 2019-06-28 | Method for configuring and managing power consumption |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910584013.0A CN110320992B (en) | 2019-06-28 | 2019-06-28 | Method for configuring and managing power consumption |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110320992A CN110320992A (en) | 2019-10-11 |
CN110320992B true CN110320992B (en) | 2020-12-04 |
Family
ID=68121508
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910584013.0A Active CN110320992B (en) | 2019-06-28 | 2019-06-28 | Method for configuring and managing power consumption |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110320992B (en) |
Family Cites Families (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8010640B2 (en) * | 2006-11-03 | 2011-08-30 | Smartsynch, Inc. | Systems and methods for auto-configuration of a generic data device coupled to a utility meter on a wireless network |
CN101581961A (en) * | 2009-06-15 | 2009-11-18 | 北京红旗胜利科技发展有限责任公司 | CPU and method for reducing CPU power consumption |
CN103294376B (en) * | 2012-02-24 | 2016-08-17 | 联想(北京)有限公司 | Electronic equipment and display packing and terminal unit and the method for switch mode |
CN104461460B (en) * | 2014-11-11 | 2017-07-28 | 盛科网络(苏州)有限公司 | The method and device of multiple core registers is configured simultaneously |
CN104484197A (en) * | 2014-12-04 | 2015-04-01 | 深圳长城开发科技股份有限公司 | Management method, management device and management system based on configuration file |
CN104570846B (en) * | 2014-12-04 | 2017-10-24 | 中国航空工业集团公司第六三一研究所 | FPGA reconfiguration control methods |
CN104850516B (en) * | 2015-05-25 | 2017-09-26 | 福州瑞芯微电子股份有限公司 | A kind of DDR Frequency Conversion Designs method and apparatus |
CN107222527B (en) * | 2017-05-16 | 2020-05-05 | 浙江工业大学 | Method for controlling internet of things equipment to operate in different modes through configuration file |
CN107168721B (en) * | 2017-06-20 | 2020-07-31 | 中国电子科技集团公司第三十六研究所 | Device and method for centralized storage and loading of satellite-borne multiprocessor software and updating method |
CN107450948B (en) * | 2017-07-28 | 2019-10-08 | 西安电子科技大学 | A kind of FPGA adaptive allocation method and system of low-power consumption |
CN108469895A (en) * | 2018-03-29 | 2018-08-31 | 联想(北京)有限公司 | Data processing method and data processing system |
-
2019
- 2019-06-28 CN CN201910584013.0A patent/CN110320992B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN110320992A (en) | 2019-10-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3355223B1 (en) | Unlock method and mobile terminal | |
EP1457922B1 (en) | Smart card that can be configured for debugging and software development using secondary communication port | |
US9921569B2 (en) | Field device commissioning system and method | |
CN110941323B (en) | Computer implementation method, computing device and computer readable storage medium | |
CN114003538B (en) | Identification method of intelligent network card and intelligent network card | |
CN104220958B (en) | Computer device and method for converting working mode of universal serial bus connector of the computer device | |
CN111130962B (en) | Automatic configuration method, equipment, system and storage medium for switch | |
CN109032623A (en) | A kind of initial method and BIOS mirror image of BIOS mirror image | |
CN112996020B (en) | Bluetooth-based automatic test method and device and Bluetooth test terminal | |
JPH0760382B2 (en) | Automatic switching device for CPU logic | |
CN117519836B (en) | Method and device for controlling starting of server and server | |
CN102799248A (en) | Wake-on-local access network (LAN) device, computer and wake-on-LAN method | |
CN113177063B (en) | Thermal reset method and related device of PCI bus equipment | |
CN110320992B (en) | Method for configuring and managing power consumption | |
CN112732427B (en) | Data processing method, system and related device based on Redis cluster | |
US6266725B1 (en) | Communications protocol for asynchronous memory card | |
CN111240775A (en) | BIOS Setup interface control method, system, terminal and storage medium | |
CN113377418A (en) | File loading method, storage medium and equipment | |
CN111027104A (en) | Method, device and mainboard for preventing loss of network card identification data | |
EP3991035A1 (en) | Storing post codes in electronic tags | |
CN109739565A (en) | A kind of method, apparatus, computer equipment and storage medium for guaranteeing Bootrom and operating normally | |
US11861991B2 (en) | Method of communication between two sub-systems constituting a modular payment terminal | |
CN110955455A (en) | Terminal initialization configuration method and device, electronic equipment and storage medium | |
CN117112308B (en) | Dual basic input/output system switching method and system of intelligent network card, terminal, medium and network card | |
CN103971038A (en) | Computer system |
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 | ||
CB02 | Change of applicant information | ||
CB02 | Change of applicant information |
Address after: 100080, Beijing, Suzhou Street, Haidian District No. 20, building 2, on the north side of the four floor Applicant after: Zhaoxun Hengda Technology Co., Ltd Address before: 100080, Beijing, Suzhou Street, Haidian District No. 20, building 2, on the north side of the four floor Applicant before: MEGAHUNT MICROELECTRONIC TECH. (BEIJING) Co.,Ltd. |
|
GR01 | Patent grant | ||
GR01 | Patent grant |