Device and method for acquiring power consumption of electronic equipment

文档序号:1963623 发布日期:2021-12-14 浏览:20次 中文

阅读说明:本技术 电子设备耗电量获取装置及方法 (Device and method for acquiring power consumption of electronic equipment ) 是由 姚毅 于 2021-09-15 设计创作,主要内容包括:本公开公开了一种电子设备耗电量获取装置,涉及电子设备性能测试领域,尤其涉及电子设备耗电量测试领域,可以用于同款软件产品升级前后或同类软件产品的耗电量测试等场景。具体实现方案为:包括:供电装置,用于模拟电子设备的电源模块,并在特定应用场景下取代电源模块为电子设备供电;电流采集装置,与供电装置串联,用于在电子设备通过供电装置供电时实时获取对应的工作电流;以及控制装置,与电流采集装置的输出端连接,用于根据电流采集装置实时获取的工作电流进行计算以获得电子设备的实时耗电量。(The utility model discloses an electronic equipment power consumption acquisition device relates to the electronic equipment capability test field, especially relates to electronic equipment power consumption test field, can be used for with the scene such as power consumption test of money software product upgrading front and back or similar software product. The specific implementation scheme is as follows: the method comprises the following steps: the power supply device is used for simulating a power supply module of the electronic equipment and replacing the power supply module to supply power to the electronic equipment in a specific application scene; the current acquisition device is connected with the power supply device in series and is used for acquiring corresponding working current in real time when the electronic equipment is powered by the power supply device; and the control device is connected with the output end of the current acquisition device and is used for calculating according to the working current acquired by the current acquisition device in real time so as to obtain the real-time power consumption of the electronic equipment.)

1. An electronic device power consumption acquisition apparatus comprising:

the power supply device is used for simulating a power supply module of the electronic equipment and replacing the power supply module to supply power to the electronic equipment under a specific application scene;

the current acquisition device is connected with the power supply device in series and is used for acquiring corresponding working current in real time when the electronic equipment is powered by the power supply device; and

and the control device is connected with the output end of the current acquisition device and is used for calculating according to the working current acquired by the current acquisition device in real time so as to obtain the real-time power consumption of the electronic equipment.

2. The acquisition device of claim 1, further comprising:

and the current divider is connected with the current acquisition device in parallel and is used for dividing the real-time working current of the electronic equipment.

3. The acquisition device of claim 1, wherein the control device is further configured to:

and packaging the real-time power consumption into a corresponding digital real-time power consumption signal through a Modbus protocol, and transmitting the digital real-time power consumption signal to next-level equipment for real-time power consumption recording.

4. The acquisition apparatus according to claim 1, wherein a specification of the power supply apparatus is in accordance with a specification of a power supply module of the electronic device.

5. The acquisition device of claim 1, further comprising:

the power plug is matched with a power line socket of the electronic equipment, and the power supply device is connected into the electronic equipment for use when the power plug is plugged into the power line socket.

6. The acquisition device according to claim 1, wherein the power module is a lithium battery.

7. The acquisition device according to claim 1, wherein the power supply device comprises a voltage transformation device.

8. The acquisition apparatus as set forth in claim 1, wherein the electronic device comprises a system-enclosed electronic device.

9. A method of obtaining power consumption of an electronic device, comprising:

disconnecting a power module in the electronic equipment from a power line;

connecting a power supply device with a power line of the electronic equipment, wherein the power supply device is used for simulating the power supply module and replacing the power supply module to supply power to the electronic equipment under a specific application scene;

acquiring corresponding working current in real time under the condition that the electronic equipment passes through the power supply device; and

and calculating according to the working current acquired in real time to obtain the real-time power consumption of the electronic equipment.

10. The method of claim 9, further comprising:

and packaging the real-time power consumption into a corresponding digital real-time power consumption signal through a Modbus protocol, and transmitting the digital real-time power consumption signal to next-level equipment for real-time power consumption recording.

11. An electronic device, comprising:

at least one processor; and

a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,

the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of claim 9 or 10.

12. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of claim 9 or 10.

13. A computer program product comprising a computer program which, when executed by a processor, implements the method according to claim 9 or 10.

Technical Field

The utility model relates to an electronic equipment capability test field especially relates to electronic equipment power consumption test field, can be used to scene such as power consumption test of software product before and after the upgrading of the same money or similar software product.

Background

In the field of electronic device performance testing or App performance testing, the power consumption of an electronic device in unit time or the power consumption of an App in unit time is often an important index for representing the performance of the electronic device or the App.

Disclosure of Invention

The disclosure provides an electronic equipment power consumption acquisition device, a method for acquiring the power consumption of electronic equipment and a mobile phone power consumption acquisition device.

According to an aspect of the present disclosure, there is provided an electronic device power consumption acquisition apparatus including: the power supply device is used for simulating a power supply module of the electronic equipment and replacing the power supply module to supply power to the electronic equipment under a specific application scene; the current acquisition device is connected with the power supply device in series and is used for acquiring corresponding working current in real time when the electronic equipment is powered by the power supply device; and the control device is connected with the output end of the current acquisition device and used for calculating according to the working current acquired by the current acquisition device in real time so as to acquire the real-time power consumption of the electronic equipment.

According to another aspect of the present disclosure, there is provided a method for acquiring power consumption of an electronic device, including: disconnecting a power module in the electronic equipment from a power line; connecting a power supply device with a power line of the electronic equipment, wherein the power supply device is used for simulating the power supply module and replacing the power supply module to supply power to the electronic equipment under a specific application scene; under the condition that the electronic equipment passes through the power supply device, acquiring corresponding working current in real time through a current acquisition device connected with the power supply device in series; and calculating by a control device connected with the output end of the current acquisition device according to the working current acquired by the current acquisition device in real time to obtain the real-time power consumption of the electronic equipment.

According to another aspect of the present disclosure, there is provided a device for acquiring power consumption of a mobile phone, including: the power supply device is used for simulating a battery of the mobile phone and replacing the battery to supply power to the mobile phone in a specific application scene; the current acquisition device is connected with the power supply device in series and is used for acquiring corresponding working current in real time when the mobile phone is powered by the power supply device; and the control device is connected with the output end of the current acquisition device and is used for calculating according to the working current acquired by the current acquisition device in real time so as to acquire the real-time power consumption of the mobile phone.

According to another aspect of the present disclosure, there is provided an electronic device including: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of the embodiments of the present disclosure.

According to another aspect of the present disclosure, there is provided a non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method according to the embodiments of the present disclosure.

According to another aspect of the present disclosure, a computer program product is provided, comprising a computer program which, when executed by a processor, implements a method according to embodiments of the present disclosure.

It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present disclosure, nor do they limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.

Drawings

The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:

FIG. 1 illustrates a system architecture suitable for embodiments of the present disclosure;

fig. 2 illustrates a block diagram of an electronic device power consumption amount acquisition apparatus according to an embodiment of the present disclosure;

FIG. 3 illustrates a schematic diagram of acquiring and recording power consumption of an electronic device in real time according to an embodiment of the disclosure;

FIG. 4 illustrates a flow chart of a method of obtaining power consumption of an electronic device according to an embodiment of the disclosure;

fig. 5 illustrates a block diagram of a mobile phone power consumption acquisition apparatus according to an embodiment of the present disclosure;

fig. 6 illustrates a schematic diagram of a real-time power consumption recording result of a mobile phone according to an embodiment of the disclosure; and

fig. 7 illustrates a block diagram of a single chip microcomputer for implementing an embodiment of the present disclosure.

Detailed Description

Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.

It should be understood that some electronic devices are currently closed systems that do not provide a software interface for obtaining their power consumption. In this case, it is almost impossible to obtain the power consumption of the electronic device per unit time by software.

It should also be understood that although some systems of electronic devices are not closed, a software interface for obtaining the power consumption of the electronic devices is externally provided, and the power consumption of the electronic devices per unit time can be obtained by software. However, with this software method, it is only possible to record the current remaining percentage of battery power of the electronic device, record the remaining percentage of battery power of the electronic device at intervals, and calculate the power consumption of the electronic device in a specific time period according to the recorded results. Obviously, the accuracy of the power consumption information of the electronic equipment acquired and recorded in such a way is low, and the consumed time is too long.

For example, for a certain brand of mobile phone, the current power consumption software acquisition method commonly used in the industry is to acquire and record the power consumption software once every 20 seconds. The accuracy of the power consumption of the mobile phone obtained and recorded in this way is 1% of 10Watt (about 100 mW).

Furthermore, the above-described software acquisition approach may be technically at risk of being unavailable if the electronic device is subsequently upgraded.

Therefore, the embodiment of the present disclosure provides a scheme for acquiring power consumption of an electronic device in real time in a hardware manner, which can bypass a software acquisition manner, thereby overcoming the above drawbacks of the software acquisition manner.

The present disclosure will be described in detail below with reference to the drawings and specific embodiments.

A system architecture suitable for embodiments of the present disclosure is presented below.

FIG. 1 illustrates a system architecture suitable for embodiments of the present disclosure. It should be noted that fig. 1 is only an example of a system architecture to which the embodiments of the present disclosure may be applied to help those skilled in the art understand the technical content of the present disclosure, but does not mean that the embodiments of the present disclosure may not be used in other environments or scenarios.

As shown in fig. 1, the system architecture 100 in the embodiment of the present disclosure may include: the electronic device 110, the electronic device power consumption acquiring apparatus 120, and the computing device 130.

In the embodiment of the present disclosure, regardless of whether a system of the electronic device 110 is closed, that is, regardless of whether the electronic device 110 provides a software interface for acquiring the real-time power consumption of the electronic device, the real-time power consumption of the electronic device 110 may be acquired in a hardware manner in a specific application scenario, that is, by the electronic device power consumption acquiring device 120, and the acquired real-time power consumption is transmitted to the computing device 130 for real-time recording.

The specific method for obtaining the real-time power consumption of the electronic device 110 by using hardware will be described in detail in the following embodiments, which are not repeated herein.

Furthermore, in the embodiments of the present disclosure, the electronic device 110 may be various types of electronic devices, such as a smart phone, a tablet computer, a smart watch, and the like.

It should be understood that the number of electronic devices and computing devices in FIG. 1 is merely illustrative. There may be any number of electronic and computing devices, as desired for an implementation.

Application scenarios suitable for embodiments of the present disclosure are presented below.

It should be understood that the technical solutions provided by the embodiments of the present disclosure may be used in at least one of the following scenarios: for example, the method can be used for testing the power consumption of the electronic device, or testing and comparing the power consumption of similar software products, or testing and comparing the power consumption of similar products before and after upgrading, or providing data support for the situation of high power consumption of software products fed back by a user.

It should be understood that the specific application scenarios mentioned in the embodiments of the present disclosure include any one or more of the scenarios mentioned above.

According to an embodiment of the present disclosure, an electronic device power consumption acquisition apparatus is provided.

Fig. 2 illustrates a block diagram of an electronic device power consumption amount acquisition apparatus according to an embodiment of the present disclosure.

As shown in fig. 2, the electronic device power consumption amount acquisition apparatus 200 may include: a power supply device 210, a current collecting device 220 and a control device 230.

The power supply device 210 is configured to simulate a power module of an electronic device and replace the power module to supply power to the electronic device in a specific application scenario.

And the current acquisition device 220 is connected in series with the power supply device and is used for acquiring corresponding working current in real time when the electronic equipment is powered by the power supply device.

And the control device 230 is connected with the output end of the current acquisition device and used for calculating according to the working current acquired by the current acquisition device in real time so as to obtain the real-time power consumption of the electronic equipment.

In the embodiment of the present disclosure, in a specific application scenario, the electronic device power consumption obtaining apparatus 200 may be used to obtain real-time power consumption of the electronic device, and transmit data obtained by the electronic device power consumption obtaining apparatus 200 to a next-stage computing device in real time, so as to achieve automatic obtaining and recording of the real-time power consumption of the electronic device.

For example, when the electronic device is used, the electronic device may be disconnected from the original power module, and then the power supply device 210 of the power consumption obtaining device 200 of the electronic device may be connected to the power line of the electronic device. Because the power supply device 210 is configured to simulate the original power module of the electronic device, in a specific application scenario, the power supply device 210 can be used to replace the original power module of the electronic device to supply power to the electronic device, and authenticity and reliability of the acquired and recorded data can be ensured.

In addition, as an alternative embodiment, the electronic device power consumption obtaining apparatus 200 may be configured to obtain the power consumption of an electronic device whose power module is a lithium battery in real time in a specific application scenario.

It should be understood that, because the voltage of the lithium battery is generally fixed, in a scenario where the power module of the electronic device is a lithium battery, the following advantages are obtained by using the present scheme: firstly, the power supply device 210 with relatively consistent specification and parameters is designed conveniently through a power module of the analog electronic equipment, and secondly, the authenticity and reliability of the acquired and recorded data can be ensured on the basis of the first step.

Further, as an alternative embodiment, the power supply device 210 may include a voltage transformation device.

In addition, as an alternative embodiment, the power supply device in the electronic device power consumption obtaining device 200 may be designed as a power supply device that conforms to the specification of the power module of the electronic device, so that it can be ensured that the data obtained by the electronic device power consumption obtaining device 200 during operation can be as true and reliable as possible.

For example, assuming that the original power module of the electronic device is a lithium battery whose voltage is DC3.8V, in the embodiment of the present disclosure, the commercial power may provide a relatively stable voltage, i.e., DC3.8V, through the voltage transformation device.

In addition, as an optional embodiment, in the case that the electronic device is a closed-system electronic device, the electronic device power consumption obtaining apparatus 200 provided by the present disclosure may obtain the power consumption of the electronic device in real time in a specific application scenario.

It should be appreciated that the real-time power of an electronic device is equal to the product of its real-time operating voltage and its real-time operating current. Further, the real-time power consumption of the electronic device is equal to the product of its power and the corresponding time.

Therefore, in the embodiment of the present disclosure, the current collection device 220 and the power supply device 210 are connected in series to the electronic device, so that the working current of the electronic device when the power is supplied by the power supply device 220 can be obtained in real time, and then the real-time power consumption of the electronic device can be obtained through calculation according to the above calculation logic.

In the embodiment of the present disclosure, the current collecting device 220 with a suitable range can be selected according to actual needs. It should be appreciated that in one instance, it may be possible that the operating current of the electronic device is small and the range of the current collection device 220 is selected to be moderate, in which case the operating current of the electronic device does not exceed the range of the current collection device 220. In another case, it is also possible that the operating current of the electronic device is large, but the range of the current collection device 220 is selected to be small, in which case the operating current of the electronic device is likely to exceed the range of the current collection device 220.

Therefore, in an embodiment, in a case that the operating current of the electronic device is small and the range of the selected current collection device 220 is moderate, the electronic device power consumption obtaining device 200 may be designed such that the current collection device 220 is connected in series with the power supply device 210.

In another embodiment, in the case that the operating current of the electronic device is large but the selected range of the current collection device 220 is small, a current divider may be further added to the power consumption obtaining device 200 of the electronic device, and the current divider and the current collection device 220 are connected in parallel to divide the current, so as to solve the problem that the range of the current collection device 220 does not match the actual operating current of the electronic device. This scheme will be described in detail in the following embodiments, which are not described herein again.

It should be understood that, for the problem that the real-time power consumption of the electronic device obtained through the software interface provided by the electronic device cannot be adapted to the electronic device with a closed system, the embodiment of the present disclosure adopts a hardware manner, that is, the real-time power consumption of the electronic device is obtained through the hardware manner, so that the software manner can be bypassed, and further, the disadvantages of the software obtaining manner can be overcome.

In addition, in the embodiment of the disclosure, because a hardware acquisition mode is adopted, software is not relied on any more, and even if subsequent electronic equipment is upgraded, the hardware acquisition mode cannot be unavailable theoretically.

In addition, compared with the problems of low precision and long time consumption in the software acquisition mode, the embodiment of the disclosure adopts the hardware acquisition mode, and since the current acquisition device 220 can provide the current acquisition frequency of 50Hz (i.e. 50 times/s), the acquisition and recording precision of the real-time power consumption can reach 0.001% of 10Watt (about 1 mW).

As an alternative embodiment, as shown in fig. 3, the electronic device power consumption obtaining apparatus 200 may further include, in addition to the power supply apparatus 210, the current collecting apparatus 220, and the control apparatus 230: and the current divider 240 is connected in parallel with the current collecting device 220 and is used for dividing the real-time working current of the electronic equipment 1.

For example, in the case that the operating current of the electronic device 1 is large, but the range of the current collection device 220 provided in the electronic device power consumption acquisition apparatus 200 is small, the current divider 240 may be added to the electronic device power consumption acquisition apparatus 200, and the current divider 240 and the current collection device 220 are connected in parallel to divide the current, so as to solve the problem that the range of the current collection device 220 is not matched with the actual operating current of the electronic device.

It should be understood that with shunt, the real-time power of the electronic device is equal to the product of its real-time operating voltage and its real-time operating current (the operating current is the sum of the current split by the shunt and the current measured by the current collection device 220). Further, the real-time power consumption of the electronic device is equal to the product of its power and the corresponding time.

Through the embodiment of the disclosure, the scheme is particularly suitable for the condition that the actual working current of the electronic equipment far exceeds the range of the current acquisition device 220.

As an optional embodiment, the control device may be further configured to encapsulate the real-time power consumption into a corresponding digital real-time power consumption signal according to a Modbus protocol, and transmit the digital real-time power consumption signal to the next-stage device for real-time power consumption recording.

It should be understood that, in this embodiment, the current value acquired by the current acquisition device provided in the power consumption obtaining device of the electronic device is an analog quantity, so that in order to facilitate recording of the real-time power consumption in the next-stage computing device, the analog quantity may also be converted into a digital quantity by the control device in the power consumption obtaining device of the electronic device, and then the digital quantity real-time power consumption signal is encapsulated by the Modbus protocol and transmitted to the next-stage computing device for recording of the real-time power consumption.

For example, as shown in fig. 3, the electronic device power consumption obtaining apparatus 200 may include a power supply unit 210, a current collecting unit 220, a control unit 230, and a shunt 240, and the control unit 230 may be further configured to package the real-time power consumption into a corresponding digital real-time power consumption signal according to a Modbus protocol and transmit the real-time power consumption signal to a next device (e.g., computing device 2) for real-time power consumption recording.

In this embodiment, the electronic device power consumption obtaining apparatus 200 may transmit the real-time power consumption signal to the computing device 2 through the USB communication protocol or the TCP/IP network protocol to perform real-time power consumption recording. After receiving the real-time power consumption signal from the electronic device power consumption acquiring apparatus 200, the computing device 2 analyzes the Modbus protocol to acquire the real-time power consumption of the electronic device, thereby implementing automatic recording of the real-time power consumption of the electronic device.

For example, the electronic device power consumption amount obtaining apparatus 200 may transmit the real-time power consumption amount signal of the electronic device to the computing device 2 at the next stage through the RS485 serial port.

Through the embodiment of the disclosure, the electronic equipment power consumption acquisition device can expand different communication interfaces so as to communicate with the downstream computing equipment in multiple ways.

In addition, according to the embodiment of the present disclosure, the original power module of the electronic device is simulated, and the simulated power supply device is used to replace the original power module of the electronic device to supply power to the electronic device in a specific application scenario, that is, when the original power module of the electronic device is disconnected, the simulated power supply device is connected to the electronic device, and is connected in series to the dc current collecting device, so that the current collecting device can transmit the analog real-time dc current collected by the current collecting device to the control device (which may be a single chip) in the power consumption obtaining device of the electronic device, the control device converts the analog dc current signal into a digital current signal, and then calculates to obtain a corresponding real-time power consumption signal based on Modbus protocol encapsulation, and outputs the real-time power consumption signal to the computing device of the next stage which converts the Modbus protocol into the USB communication protocol or the Modbus protocol into the TCP/IP network protocol in the form of RS485 serial port, therefore, the automatic recording of the real-time power consumption of the electronic equipment is realized.

By adopting the Modbus protocol encapsulation technology, the method and the device can be adapted to various next-level computing devices adopting different data transmission protocols.

As an optional embodiment, the electronic device power consumption obtaining apparatus may further include: and a power plug. The power supply device is connected with the electronic equipment for use when the power plug is inserted into the power line socket.

Illustratively, as shown in fig. 3, the electronic device power consumption obtaining apparatus 200 includes a power supply device 210, a current collecting device 220, a control device 230, a current divider 240, and a power plug 250. The power plug 250 may be designed by simulating a plug of an original power module of the electronic device 1. Thus, the positive electrode "+" of the power plug 250 is inserted into the positive electrode "+" of the power line socket of the electronic device 1, and the negative electrode "-" of the power plug 250 is inserted into the negative electrode "-" of the power line socket of the electronic device 1, so that the power supply device 210 can replace the original power module of the electronic device 1 and be connected to the electronic device 1 for use.

In the embodiment of the present disclosure, the power plug 250 in the device 200 for acquiring power consumption of the electronic device is obtained by simulating the plug design of the original power module of the electronic device 1, so that after the power supply device 210 is connected to the electronic device 1, the electronic device 1 may identify the power supply device 210 as the original power module of itself as soon as possible, thereby ensuring that the electronic device 1 can work normally even when the power supply device 210 supplies power.

According to an embodiment of the present disclosure, a method for obtaining power consumption of an electronic device is provided.

Fig. 4 illustrates a flowchart of a method for obtaining power consumption of an electronic device according to an embodiment of the present disclosure.

As shown in fig. 4, a method 400 of obtaining power consumption of an electronic device may include: operations S410 to S440.

In operation S410, a power module in an electronic device is disconnected from a power line.

In operation S420, a power supply device is connected to a power line of the electronic device, wherein the power supply device is used for simulating a power module and supplying power to the electronic device instead of the power module in a specific application scenario.

In operation S430, in the case that the electronic device passes through the power supply device, a corresponding operating current is acquired in real time. For example, the corresponding working current is obtained in real time through a current acquisition device connected with the power supply device in series.

In operation S440, a calculation is performed according to the operating current acquired in real time to obtain a real-time power consumption of the electronic device. For example, the control device connected to the output end of the current collection device calculates the working current obtained by the current collection device in real time to obtain the real-time power consumption of the electronic device.

As an alternative embodiment, the method may further comprise: and packaging the real-time power consumption into a corresponding digital real-time power consumption signal through a Modbus protocol, and transmitting the digital real-time power consumption signal to the next-stage equipment for real-time power consumption recording. For example, the control device encapsulates the real-time power consumption into a corresponding digital real-time power consumption signal through a Modbus protocol and transmits the digital real-time power consumption signal to the next-level device for real-time power consumption recording.

It should be understood that, in the embodiment of the present disclosure, the method 400 for acquiring power consumption of an electronic device is the same as or similar to the method for acquiring power consumption of an electronic device by using the power consumption acquiring apparatus of an electronic device in the foregoing embodiment, and details of this embodiment are not repeated herein.

It should be understood that the embodiments of the method portion of the present disclosure are the same as or similar to the embodiments of the apparatus portion of the present disclosure, and the technical problems to be solved and the technical effects to be achieved are also the same as or similar to each other, and the detailed description of the present disclosure is omitted.

According to the embodiment of the disclosure, the disclosure further provides a device for acquiring the power consumption of the mobile phone.

Fig. 5 illustrates a block diagram of a mobile phone power consumption acquisition apparatus according to an embodiment of the present disclosure.

As shown in fig. 5, the device 500 for acquiring power consumption of a mobile phone may include: a power supply device 510, a current collection device 520 and a control device 530.

The power supply device 510 is used for simulating a battery of the mobile phone and replacing the battery to supply power to the mobile phone in a specific application scene.

And the current acquisition device 520 is connected with the power supply device in series and is used for acquiring the corresponding working current in real time when the mobile phone is powered by the power supply device.

And the control device 530 is connected with the output end of the current acquisition device and is used for calculating according to the working current acquired by the current acquisition device in real time so as to obtain the real-time power consumption of the mobile phone.

It should be understood that, in the embodiment of the present disclosure, a method for acquiring real-time power consumption of a mobile phone by a hardware manner, that is, by using a device for acquiring power consumption of a mobile phone, is described as an example of a mobile phone. The apparatus and the corresponding method are the same as or similar to the apparatus for acquiring power consumption of an electronic device and the method for acquiring power consumption of an electronic device in the foregoing embodiments, and are not repeated herein.

Fig. 6 may be referred to for real-time power consumption data obtained and recorded by the hardware obtaining method provided in the embodiment of the present disclosure.

According to the embodiment of the disclosure, the disclosure also provides a single chip microcomputer.

It should be understood that the control device in the foregoing embodiment may be a single chip microcomputer in the present embodiment. The single chip microcomputer is used for realizing the method realized by the control device, and the description of the embodiment is omitted.

FIG. 7 shows a schematic block diagram of an example single-chip microcomputer 700 that can be used to implement embodiments of the present disclosure. A single chip computer is intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The single-chip may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.

As shown in fig. 7, the one-chip microcomputer 700 includes a calculation unit 701 that can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM)702 or a computer program loaded from a storage unit 708 into a Random Access Memory (RAM) 703. In the RAM703, various programs and data required for the operation of the one-chip microcomputer 700 can also be stored. The computing unit 701, the ROM 702, and the RAM703 are connected to each other by a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.

A plurality of components in the single chip microcomputer 700 are connected to the I/O interface 705, including: an input unit 706 such as a keyboard, a mouse, or the like; an output unit 707 such as various types of displays, speakers, and the like; a storage unit 708 such as a magnetic disk, optical disk, or the like; and a communication unit 709 such as a network card, modem, wireless communication transceiver, etc. The communication unit 709 allows the device 700 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.

Computing unit 701 may be a variety of general purpose and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The computing unit 701 executes the respective methods and processes described above, such as the method implemented by the control device. For example, in some embodiments, the control device implemented method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 708. In some embodiments, part or all of a computer program may be loaded onto and/or installed onto device 700 via ROM 702 and/or communications unit 709. When the computer program is loaded into the RAM703 and executed by the computing unit 701, one or more steps of the method implemented by the control device described above may be performed. Alternatively, in other embodiments, the computing unit 701 may be configured by any other suitable means (e.g., by means of firmware) to perform the method implemented by the control device.

Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.

Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.

In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.

The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.

The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The Server may be a cloud Server, which is also called a cloud computing Server or a cloud host, and is a host product in a cloud computing service system, so as to solve the defects of high management difficulty and weak service extensibility in a traditional physical host and a VPS service ("Virtual Private Server", or "VPS" for short). The server may also be a server of a distributed system, or a server incorporating a blockchain.

In the technical scheme of the disclosure, the related data are recorded, stored, applied and the like, which all accord with the regulations of related laws and regulations and do not violate the good customs of the public order.

It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel, sequentially, or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and the present disclosure is not limited herein.

The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the scope of protection of the present disclosure.

16页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种告警场景挖掘方法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!