Lamp charging method and device
By dynamically adjusting the charging current by obtaining the display status of the lamp, the problems of low charging flexibility and large battery loss when charging while using the low-power lighting products are solved, and efficient charging is achieved.
Patent Information
- Application Number
- CN202210999254.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-19
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2042-08-19
AI Technical Summary
When charging at the same time in the prior art, the charging of the small and medium-power lighting products with fixed current values leads to low charging flexibility and large battery loss.
By obtaining the current display status of the lamp, determining whether it is the illuminated state, and determining the duty cycle of the first pulse signal according to the illuminated state, dynamically adjusting the charging current to achieve flexible charging.
It improves the charging efficiency of lamp batteries, reduces battery losses, and achieves flexible charging.
Smart Images

Figure CN115377534B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of smart lamps, and in particular to a lamp charging method and device. Background Art
[0002] Currently, some low-power lighting products (such as nightlights and cool lights) are charged through integrated circuits. The charging current is determined by the size of the IC's external resistors, meaning the charging current is fixed. Whether these products are charged via an adapter or a Universal Serial Bus (USB) interface, the charging current remains fixed while in use. However, with a fixed external power input (such as USB 5V / 1A), these solutions must simultaneously charge the battery and power the light source circuit. The combined power cannot exceed 5V / 1A. Circuit design forces either sacrificing LED output power to maintain charging time, or reducing charging time to maintain power to the light source circuit. This compromise is not possible, resulting in reduced charging flexibility and significant battery loss.
[0003] To address the above-mentioned problems, no effective solutions have been proposed so far. Summary of the Invention
[0004] Embodiments of the present invention provide a lamp charging method and device to at least solve the technical problems of low charging flexibility and high battery loss caused by using a fixed current value to charge the battery in the lamp when the lamp is charged while in use in the prior art.
[0005] According to one aspect of an embodiment of the present invention, a lamp charging method is provided, comprising: obtaining a current display state of the lamp; determining whether the current display state is a lighting state; if the current display state is the lighting state, determining a first pulse signal corresponding to the lighting state, wherein a duty cycle of the first pulse signal is used to determine a charging current corresponding to a rechargeable battery in the lamp; and controlling the charging of the rechargeable battery according to the first pulse signal.
[0006] Optionally, the above-mentioned charging of the rechargeable battery according to the above-mentioned first pulse signal control includes: determining the target resistance value corresponding to the above-mentioned rechargeable battery based on the above-mentioned first pulse signal; determining the first current signal corresponding to the above-mentioned rechargeable battery based on the above-mentioned target resistance value; and charging the above-mentioned rechargeable battery using the above-mentioned first current signal.
[0007] Optionally, the lamp includes: a resistance circuit corresponding to the rechargeable battery, the resistance circuit includes a first resistance branch and a second resistance branch, the first resistance branch and the second resistance branch are connected in parallel, and the target resistance value corresponding to the rechargeable battery is determined based on the first pulse signal, including: determining the first resistance value corresponding to the first resistance branch based on the first pulse signal; obtaining the second resistance value corresponding to the second resistance branch; and obtaining the target resistance value based on the first resistance value and the second resistance value.
[0008] Optionally, the above-mentioned first resistance branch includes a first resistor and a transistor, and the above-mentioned determination of the first resistance value corresponding to the above-mentioned first resistance branch based on the above-mentioned first pulse signal includes: determining the current conduction state of the above-mentioned transistor based on the above-mentioned first pulse signal; and determining the above-mentioned first resistance value based on the above-mentioned current conduction state.
[0009] Optionally, in the case where the above-mentioned lamp includes multiple light source circuits, the above-mentioned determination of the first pulse signal corresponding to the above-mentioned lighting state includes: obtaining second pulse signals corresponding to the above-mentioned multiple light source circuits respectively, wherein the above-mentioned second pulse signals correspond to the lighting states of the above-mentioned multiple light source circuits; processing the second pulse signals corresponding to the above-mentioned multiple light source circuits respectively to obtain the above-mentioned first pulse signal.
[0010] Optionally, the method further includes: if the current display state is off, charging the rechargeable battery using a predetermined current signal.
[0011] According to another aspect of an embodiment of the present invention, a lamp charging device is also provided, including: an acquisition module for acquiring the current display status of the lamp; a judgment module for judging whether the above-mentioned current display status is the lighting state; a determination module for determining a first pulse signal corresponding to the above-mentioned lighting state if the above-mentioned current display state is the above-mentioned lighting state, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; and a control module for controlling the charging of the above-mentioned rechargeable battery according to the above-mentioned first pulse signal.
[0012] According to another aspect of an embodiment of the present invention, a non-volatile storage medium is provided. The non-volatile storage medium stores a plurality of instructions. The instructions are suitable for being loaded by a processor and executed by any one of the above-mentioned lamp charging methods.
[0013] According to another aspect of an embodiment of the present invention, an electronic device is also provided, comprising one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any one of the above-mentioned lamp charging methods.
[0014] According to another aspect of an embodiment of the present invention, a lamp is further provided, and the lamp is used to execute any one of the above lamp charging methods.
[0015] In an embodiment of the present invention, the current display state of the lamp is obtained; it is determined whether the above-mentioned current display state is the lighting state; if the above-mentioned current display state is the lighting state, a first pulse signal corresponding to the above-mentioned lighting state is determined, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; the charging of the above-mentioned rechargeable battery is controlled according to the above-mentioned first pulse signal, thereby achieving the purpose of obtaining the corresponding pulse signal according to the lighting state of the lamp and dynamically adjusting the charging current of the battery through the pulse signal, thereby achieving the technical effect of improving the charging efficiency of the lamp battery, reducing battery loss, and realizing flexible charging, thereby solving the technical problem of low charging flexibility and large battery loss caused by using a fixed current value to charge the battery in the lamp when the lamp is used and charged in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0017] Figure 1 is a flow chart of a lamp charging method according to an embodiment of the present invention;
[0018] Figure 2 is a schematic diagram of the circuit structure of an optional cool light according to an embodiment of the present invention;
[0019] Figure 3 is a schematic diagram of the circuit structure of an optional cool light according to an embodiment of the present invention;
[0020] Figure 4 is a schematic structural diagram of a lamp charging device according to an embodiment of the present invention;
[0021] Figure 5 FIG. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0022] In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.
[0023] It should be noted that the terms "first", "second", etc. in the description and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0024] According to an embodiment of the present invention, an embodiment of a method for charging a lamp is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0025] Figure 1 FIG. 1 is a flow chart of a lamp charging method according to an embodiment of the present invention. Figure 1 As shown, the method includes the following steps:
[0026] Step S102, obtaining the current display status of the lamp;
[0027] Step S104, determining whether the current display state is a lit state;
[0028] Step S106, if the current display state is the lighting state, determining a first pulse signal corresponding to the lighting state, wherein the duty cycle of the first pulse signal is used to determine a charging current corresponding to the rechargeable battery in the lamp;
[0029] Step S108 , charging the rechargeable battery according to the first pulse signal control.
[0030] In an embodiment of the present invention, the current display state of the lamp is obtained; it is determined whether the above-mentioned current display state is the lighting state; if the above-mentioned current display state is the lighting state, a first pulse signal corresponding to the above-mentioned lighting state is determined, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; the charging of the above-mentioned rechargeable battery is controlled according to the above-mentioned first pulse signal, thereby achieving the purpose of obtaining the corresponding pulse signal according to the lighting state of the lamp and dynamically adjusting the charging current of the battery through the pulse signal, thereby achieving the technical effect of improving the charging efficiency of the lamp battery, reducing battery loss, and realizing flexible charging, thereby solving the technical problem of low charging flexibility and large battery loss caused by using a fixed current value to charge the battery in the lamp when the lamp is used and charged in the prior art.
[0031] Optionally, the above-mentioned current display state includes a lighting state and an off state, and different current display states correspond to different charging methods. For example, when the above-mentioned current display state is the off state, a predetermined current signal is used to charge the above-mentioned rechargeable battery. The above-mentioned predetermined current signal may be, but is not limited to: all the voltages that the external power supply can provide are output to the rechargeable battery, and the external power supply is used to directly charge the above-mentioned rechargeable battery. This achieves dynamic improvement of charging efficiency when the light is not on. When the above-mentioned current display state is the above-mentioned lighting state, the first pulse signal corresponding to the lamp in the lighting state is obtained, and the charging current corresponding to the rechargeable battery in the above-mentioned lamp is determined according to the duty cycle of the above-mentioned first pulse signal, and the above-mentioned rechargeable battery is charged using the charging current. In this way, the purpose of dynamically charging the rechargeable battery is achieved, while improving the charging efficiency, reducing the loss of the rechargeable battery, and increasing the service life of the rechargeable battery.
[0032] Optionally, the lighting state includes multiple different lighting states, which may be light brightness, light hue, etc. For example, warm light hue, cool light hue, strong light brightness, weak light brightness, etc. The first pulse signal is determined by the lighting state of the lamp, and under different lighting states, the first pulse signal corresponds to different duty cycles.
[0033] Optionally, the above-mentioned lamps can be, but are not limited to, rechargeable low-power lighting products that carry rechargeable batteries, such as night lights, cool lights, cabinet lights, etc.
[0034] In an optional embodiment, the controlling of charging the rechargeable battery according to the first pulse signal includes:
[0035] determining a target resistance value corresponding to the rechargeable battery based on the first pulse signal;
[0036] determining a first current signal corresponding to the rechargeable battery based on the target resistance value;
[0037] The rechargeable battery is charged using the first current signal.
[0038] Optionally, the target resistance value is used to determine the first current signal corresponding to the rechargeable battery, that is, the charging current corresponding to the rechargeable battery is controlled by regulating the resistance corresponding to the rechargeable battery through the first pulse signal.
[0039] In an optional embodiment, the lamp includes: a resistance circuit corresponding to the rechargeable battery, the resistance circuit including a first resistance branch and a second resistance branch, the first resistance branch and the second resistance branch being connected in parallel, and determining the target resistance value corresponding to the rechargeable battery based on the first pulse signal includes:
[0040] determining a first resistance value corresponding to the first resistance branch based on the first pulse signal;
[0041] Obtaining a second resistance value corresponding to the second resistance branch;
[0042] The target resistance value is obtained based on the first resistance value and the second resistance value.
[0043] Optionally, the resistance circuit corresponding to the above-mentioned rechargeable battery is a variable resistance circuit. It includes a first resistance branch with a variable resistance value, and a second resistance branch with a fixed resistance value. The above-mentioned first resistance branch with a variable resistance value can be, but is not limited to, composed of a transistor and a variable resistor. The current conduction state of the transistor is controlled by a first pulse signal. The different duty cycles of the first pulse signal cause the current conduction state of the transistor to change, and the target resistance value corresponding to the resistance circuit changes accordingly, thereby realizing dynamic adjustment of the current signal of the rechargeable battery (i.e., the above-mentioned first current signal).
[0044] In an optional embodiment, the first resistance branch includes a first resistor and a transistor, and determining the first resistance value corresponding to the first resistance branch based on the first pulse signal includes:
[0045] determining a current conduction state of the transistor based on the first pulse signal;
[0046] The first resistance value is determined based on the current conduction state.
[0047] Optionally, the current conduction state of the transistor includes: a fully-on state, a fully-off state, and a partially-on state. The current conduction state of the transistor is determined by the duty cycle of the first pulse signal. When the duty cycle of the first pulse signal changes, the current conduction state of the transistor changes, and the first resistance value corresponding to the first resistance branch changes accordingly. Figure 2FIG. 1 shows a schematic diagram of a circuit structure of an optional cool lamp according to an embodiment of the present invention, as shown in FIG. Figure 2 As shown in FIG, a schematic diagram of a resistor circuit is shown, in which the first resistor branch is composed of a transistor Q4 and a first resistor R19.
[0048] Optionally, when the current display state of the lamp is off, the current conduction state of the above-mentioned transistor reaches a fully conductive state, and the parallel result of the above-mentioned first resistance value and the second resistance value is the above-mentioned target resistance value. At this time, the target resistance value reaches a minimum, the charging current corresponding to the rechargeable battery is the largest, the charging current is dynamically increased, and the charging efficiency is improved.
[0049] Optionally, when the current display state of the lamp is the lit state, and the light brightness corresponding to the lit state reaches maximum, the duty cycle of the first pulse signal reaches maximum. At this time, the current on-state of the transistor reaches a fully off state, the second resistance value is the target resistance value, the target resistance value reaches maximum, and the charging current corresponding to the rechargeable battery reaches minimum. In an optional embodiment, when the lamp includes multiple light source circuits, determining the first pulse signal corresponding to the lit state includes:
[0050] Obtaining second pulse signals corresponding to the plurality of light source circuits respectively, wherein the second pulse signals correspond to the lighting states of the plurality of light source circuits;
[0051] The second pulse signals corresponding to the plurality of light source circuits are processed to obtain the first pulse signal.
[0052] Optionally, when the lamp includes multiple light source circuits, the first pulse signal is obtained by performing logical processing on the second pulse signal. For example, the multiple second pulse signals are sent to a microcontroller circuit, which performs certain logical processing on the multiple second pulse signals to obtain the first pulse signal.
[0053] As an optional embodiment, Figure 2 and Figure 3 FIG. 1 is a schematic diagram of a circuit structure of an optional cool lamp according to an embodiment of the present invention. Figure 2 and Figure 3As shown, the cool lamp includes two light source circuits, and the circuit structure mainly includes: a rechargeable battery, a microcontroller, a first light source circuit, a first pulse circuit corresponding to the first light source circuit, a second light source circuit, a second pulse circuit corresponding to the second light source circuit, an external power supply circuit, a rechargeable battery, and a resistance circuit; wherein the above-mentioned resistance circuit includes a first resistance branch composed of a transistor Q4 and a first resistor R19 connected in series, and a second resistance branch composed of a second resistor R4, and the first resistance branch and the second resistance branch are connected in parallel; the above-mentioned resistance circuit, the above-mentioned first pulse circuit and the above-mentioned second pulse circuit are all connected to the above-mentioned microcontroller circuit through different interfaces, and the above-mentioned is also connected to the rechargeable battery, the above-mentioned first light source circuit is connected to the above-mentioned first pulse circuit, and the above-mentioned second light source circuit is connected to the above-mentioned second pulse circuit, and the above-mentioned external power supply circuit charges the lamp via the serial bus interface (Universal Serial Bus, USB) of the external adapter.
[0054] When the current display state of the lamp is the lighting state, and the lighting state corresponding to the lighting state is the light brightness, the first control signal emitted by button TP1 is used to control the first light source circuit to be turned on, corresponding to the first light brightness. At this time, the first pulse pin W-PWM corresponding to the first pulse circuit emits a high level, and the second pulse pin Y-PWM corresponding to the second pulse circuit emits a low level; the second control signal emitted by button TP2 is used to control the second light source circuit to be turned on, corresponding to the second light brightness, wherein the second light brightness is greater than the first light brightness. At this time, the first pulse pin W-PWM emits a low level, and the second pulse pin Y-PWM emits a high level; the third control signal emitted by button TP3 is used to control the first light source circuit and the second light source circuit to be turned on at the same time, corresponding to the third light brightness, that is, button TP3 corresponds to the maximum light brightness, and the first pulse pin W-PWM and the second pulse pin Y-PWM both emit high levels.
[0055] It should be noted that different light brightnesses correspond to different first pulse signals, i.e., different duty cycles of the first pulse signals are obtained. When the current display state of the lamp is the lit state, at least one of the two pins W-PWM or Y-PWM is at a high level, and at least one of the corresponding switches Q2 and Q3 is turned on. When both the W-PWM or Y-PWM pins are at a high level, that is, when both switches Q2 and Q3 are turned on, the microcontroller circuit (such as a single-chip microcomputer) determines through internal logic that the ISET pin does not output a signal, and the transistor Q4 does not turn on. At this time, the size of the charging current corresponding to the rechargeable battery is only determined by the second resistor R4, and a low current charging can be set.
[0056] When the current display state of the lamp is off, the above-mentioned rechargeable battery is charged, and the above-mentioned first pulse pin W-PWM and the above-mentioned second pulse pin Y-PWM must all output low levels. The micro-control circuit obtains the first pulse signal through internal logic judgment, so that the transistor Q4 is turned on. At this time, the size of the charging current corresponding to the rechargeable battery depends on the result of the second resistor R4 and the first resistor R19 being connected in parallel. That is, at this time, the charging current corresponding to the rechargeable battery dynamically reaches the maximum and the charging efficiency is the highest.
[0057] The embodiments of the present invention can at least achieve the following technical effects: (1) When the lamp is used while being charged, the charging current corresponding to the rechargeable battery is reduced, and the limited input power is mostly distributed to the light source circuit, with a small amount used for charging, which not only increases the output power but also extends the battery life; when charging is not in use, the system automatically determines internally to improve the charging efficiency, and when the limited input power is small, all of it is used for charging to meet the fast charging requirements.
[0058] It should be noted that for the aforementioned method embodiments, for simplicity of description, they are all expressed as a series of action combinations. However, those skilled in the art should be aware that the present invention is not limited by the order of the actions described, because according to the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in this specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0059] Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus the necessary general hardware platform, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for enabling a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods of various embodiments of the present invention.
[0060] This embodiment also provides a lamp charging device for implementing the above-mentioned embodiments and preferred embodiments. Details already described will not be repeated. As used below, the terms "module" and "device" may refer to a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation using hardware, or a combination of software and hardware, is also possible and contemplated.
[0061] According to an embodiment of the present invention, there is also provided an embodiment of a device for implementing the above-mentioned lamp charging method. Figure 4 FIG. 1 is a schematic structural diagram of a lamp charging device according to an embodiment of the present invention. Figure 4 As shown, the lamp charging device includes: an acquisition module 400, a judgment module 402, a determination module 404, and a control module 406, wherein:
[0062] The acquisition module 400 is used to acquire the current display status of the lamp;
[0063] The judgment module 402 is connected to the acquisition module 400 and is used to judge whether the current display state is the lit state;
[0064] The determination module 404 is connected to the judgment module 402 and is configured to determine a first pulse signal corresponding to the lighting state if the current display state is the lighting state, wherein the duty cycle of the first pulse signal is used to determine a charging current corresponding to the rechargeable battery in the lamp;
[0065] The control module 406 is connected to the determination module 404 and is configured to control the charging of the rechargeable battery according to the first pulse signal.
[0066] In an embodiment of the present invention, the acquisition module 400 is provided to acquire the current display state of the lamp; the judgment module 402 is provided to judge whether the current display state is the lighting state; the determination module 404 is provided to determine the first pulse signal corresponding to the lighting state if the current display state is the lighting state, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the lamp; the control module 406 is provided to control the charging of the rechargeable battery according to the first pulse signal, thereby achieving the purpose of obtaining the corresponding pulse signal according to the lighting state of the lamp and dynamically adjusting the charging current of the battery through the pulse signal, thereby realizing the technical effect of improving the charging efficiency of the lamp battery, reducing battery loss, and realizing flexible charging, thereby solving the technical problem of low charging flexibility and large battery loss caused by using a fixed current value to charge the battery in the lamp when the lamp is charged while in use in the prior art.
[0067] It should be noted that the above modules can be implemented by software or hardware. For example, for the latter, it can be implemented in the following ways: the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.
[0068] It should be noted that the acquisition module 400, judgment module 402, determination module 404, and control module 406 correspond to steps S102 to S108 in the embodiment. The examples and application scenarios implemented by these modules and the corresponding steps are the same, but are not limited to the contents disclosed in the above embodiment. It should be noted that the above modules, as part of the device, can be run on a computer terminal.
[0069] It should be noted that the optional or preferred implementation of this embodiment can be found in the relevant description in the embodiment, which will not be repeated here.
[0070] The above-mentioned lamp charging device may further include a processor and a memory. The above-mentioned acquisition module 400, judgment module 402, determination module 404, control module 406, etc. are all stored in the memory as program modules, and the processor executes the above-mentioned program modules stored in the memory to implement corresponding functions.
[0071] The processor includes a core, which retrieves corresponding program modules from memory. There can be one or more cores. Memory may include non-permanent memory in a computer-readable medium, random access memory (RAM), and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory includes at least one memory chip.
[0072] According to an embodiment of the present application, an embodiment of a non-volatile storage medium is further provided. Optionally, in this embodiment, the non-volatile storage medium includes a stored program, wherein when the program is executed, the device containing the non-volatile storage medium is controlled to execute any of the above-mentioned lamp charging methods.
[0073] Optionally, in this embodiment, the non-volatile storage medium may be located in any computer terminal in a computer terminal group in a computer network, or in any mobile terminal in a mobile terminal group, and the non-volatile storage medium includes a stored program.
[0074] Optionally, when the program is running, the device where the non-volatile storage medium is located is controlled to perform the following functions: obtain the current display status of the lamp; determine whether the above-mentioned current display status is the lighting state; if the above-mentioned current display state is the above-mentioned lighting state, determine the first pulse signal corresponding to the above-mentioned lighting state, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; and control the charging of the above-mentioned rechargeable battery according to the above-mentioned first pulse signal.
[0075] According to an embodiment of the present application, an embodiment of a processor is further provided. Optionally, in this embodiment, the processor is used to run a program, wherein when the program is run, any of the above-mentioned lamp charging methods is executed.
[0076] According to an embodiment of the present application, an embodiment of a computer program product is also provided. When executed on a data processing device, the computer program product is suitable for executing a program that initializes any one of the above-mentioned lamp charging method steps.
[0077] Optionally, the above-mentioned computer program product, when executed on a data processing device, is suitable for executing a program initialized with the following method steps: obtaining the current display state of the lamp; determining whether the above-mentioned current display state is the lighting state; if the above-mentioned current display state is the above-mentioned lighting state, determining the first pulse signal corresponding to the above-mentioned lighting state, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; and controlling the charging of the above-mentioned rechargeable battery according to the above-mentioned first pulse signal.
[0078] According to an embodiment of the present application, a lamp embodiment is further provided. Optionally, in this embodiment, the lamp is used to execute any one of the above lamp control methods.
[0079] like Figure 5 As shown, an embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a program stored in the memory and runnable on the processor. When the processor executes the program, the following steps are implemented: obtaining the current display state of the lamp; determining whether the above-mentioned current display state is the lighting state; if the above-mentioned current display state is the above-mentioned lighting state, determining a first pulse signal corresponding to the above-mentioned lighting state, wherein the duty cycle of the first pulse signal is used to determine the charging current corresponding to the rechargeable battery in the above-mentioned lamp; and controlling the charging of the above-mentioned rechargeable battery according to the above-mentioned first pulse signal.
[0080] The serial numbers of the above embodiments of the present invention are for description only and do not represent the advantages or disadvantages of the embodiments.
[0081] In the above embodiments of the present invention, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0082] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only exemplary. For example, the division of the above modules can be a logical function division. In actual implementation, there may be other division methods, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, modules or indirect coupling or communication connection of modules, which can be electrical or other forms.
[0083] The modules described above as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.
[0084] In addition, the functional modules in various embodiments of the present invention may be integrated into a single processing module, or each module may exist physically separately, or two or more modules may be integrated into a single module. The aforementioned integrated modules may be implemented in the form of hardware or software functional modules.
[0085] If the above-mentioned integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can be stored in a computer-readable non-volatile storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a non-volatile storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server or network device, etc.) to execute all or part of the steps of the various embodiments of the present invention. The aforementioned non-volatile storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk, and other media that can store program codes.
[0086] The above are only preferred embodiments of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A lamp charging method, characterized in that: include: Get the current display status of the lamp; Determine whether the current display state is a lit state; If the current display state is the lighting state, determining a first pulse signal corresponding to the lighting state, wherein the duty cycle of the first pulse signal is used to determine a charging current corresponding to the rechargeable battery in the lamp; Controlling charging of the rechargeable battery according to the first pulse signal; The controlling of charging the rechargeable battery according to the first pulse signal includes: determining a target resistance value corresponding to the rechargeable battery based on the first pulse signal; determining a first current signal corresponding to the rechargeable battery based on the target resistance value; and charging the rechargeable battery using the first current signal. The lamp includes a resistance circuit corresponding to the rechargeable battery, the resistance circuit includes a first resistance branch and a second resistance branch, the first resistance branch and the second resistance branch are connected in parallel, and determining the target resistance value corresponding to the rechargeable battery based on the first pulse signal includes: determining a first resistance value corresponding to the first resistance branch based on the first pulse signal; obtaining a second resistance value corresponding to the second resistance branch; and obtaining the target resistance value based on the first resistance value and the second resistance value; The method further includes: when the current display state is the off state, determining the target resistance value according to the parallel result of the first resistance value and the second resistance value, wherein the target resistance value reaches the minimum and the charging current corresponding to the rechargeable battery is the maximum.
2. The method according to claim 1, characterized in that The first resistance branch includes a first resistor and a transistor, and determining a first resistance value corresponding to the first resistance branch based on the first pulse signal includes: determining a current conduction state of the transistor based on the first pulse signal; The first resistance value is determined based on the current conductive state.
3. The method according to claim 1, characterized in that In a case where the lamp includes a plurality of light source circuits, determining the first pulse signal corresponding to the lighting state includes: Acquire second pulse signals respectively corresponding to the plurality of light source circuits, wherein the second pulse signals correspond to light states of the plurality of light source circuits; The second pulse signals corresponding to the plurality of light source circuits are processed to obtain the first pulse signal.
4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: If the current display state is the off state, a predetermined current signal is used to charge the rechargeable battery.
5. A lamp charging device, characterized in that: include: The acquisition module is used to obtain the current display status of the lamp; A judging module, configured to judge whether the current display state is a lit state; a determination module, configured to determine a first pulse signal corresponding to the lighting state if the current display state is the lighting state, wherein the duty cycle of the first pulse signal is used to determine a charging current corresponding to the rechargeable battery in the lamp; a control module, configured to control charging of the rechargeable battery according to the first pulse signal; The control module is further configured to determine a target resistance value corresponding to the rechargeable battery based on the first pulse signal; determine a first current signal corresponding to the rechargeable battery based on the target resistance value; and charge the rechargeable battery using the first current signal; The lamp in the device includes a resistance circuit corresponding to the rechargeable battery, the resistance circuit includes a first resistance branch and a second resistance branch, the first resistance branch and the second resistance branch are connected in parallel, and the control module is further configured to determine a first resistance value corresponding to the first resistance branch based on the first pulse signal; obtain a second resistance value corresponding to the second resistance branch; and obtain the target resistance value based on the first resistance value and the second resistance value; The device is further configured to determine the target resistance value based on a parallel connection result of the first resistance value and the second resistance value when the current display state is off, wherein the target resistance value reaches a minimum and the charging current corresponding to the rechargeable battery is maximum.
6. A non-volatile storage medium, characterized in that: The non-volatile storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor and executed by the lamp charging method according to any one of claims 1 to 4.
7. An electronic device, characterized in that: The device comprises one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the lamp charging method according to any one of claims 1 to 4.
8. A lamp, characterized in that: The lamp is used to execute the lamp charging method according to any one of claims 1 to 4.
Citation Information
Patent Citations
Lighting system
JP2007165016A