Lighting circuit and lighting device
By introducing a detection circuit and processor into the lighting circuit, the changes in the current values of the two light-emitting parts are automatically detected and synchronized, solving the problem of asynchronous dimming of the light-emitting parts, improving the lighting effect and user experience, and adapting to changes in the light-emitting parts or dimming circuit without the need for hardware or software adjustments.
Patent Information
- Application Number
- CN202110797375.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-14
- Publication Date
- 2024-11-22
- Estimated Expiration
- 2041-07-14
AI Technical Summary
In existing lighting circuits and devices, the response times of the two light-emitting parts are not synchronized during dimming, resulting in inconsistent visual effects. Furthermore, frequent adjustments to the circuit design or MCU program are required to adapt to changes in different combinations of light-emitting parts, increasing costs and inconvenience.
By introducing a detection circuit and processor into the lighting circuit, the difference between the starting moments of the current value changes of the two light-emitting parts is automatically detected and calculated. The processor is then used to adjust the dimming signal to synchronize the switching of the light-emitting parts, thereby achieving automatic compensation and avoiding the need for hardware or software readjustment.
It achieves synchronization of different light-emitting components during the dimming process, improving lighting effects and user experience. It can adapt to changes in light-emitting components or dimming circuits without hardware or software adjustments, enhancing the versatility and synchronization of lighting circuits.
Smart Images

Figure CN115623631B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of lighting, and in particular to a lighting circuit and a lighting device. Background Art
[0002] Nowadays, lighting devices are becoming more and more diversified. Multiple light-emitting parts are arranged in lighting devices and lighting circuits, so that more types of lighting schemes or modes can be matched to meet the personalized needs of users, and therefore they are increasingly widely used. When the light source is composed of two light-emitting parts, the two light-emitting parts are dimmed by a dimming circuit. In the process of switching or state switching of the lighting device, different light-emitting parts will act successively, resulting in a difference in response time, which causes the two light-emitting parts to emit light asynchronously, making the human eye feel uncomfortable when watching.
[0003] In order to solve the problem of asynchronous dimming of the two light-emitting parts, in the prior art, the difference between the response time of the switch / state switching action of the two light-emitting parts can be compensated by adjusting the circuit design (for example, adjusting the relevant capacitors) or re-burning the program in the MCU, so that the switch / state switching action of the two light-emitting parts is synchronized. In addition, due to the adjustment of chip models and even chip manufacturers, the combination of light-emitting parts of lighting devices produced in different periods changes, and the difference in the action of the two light-emitting parts also changes accordingly, which requires repeated adjustment of circuit design or MCU program. Summary of the invention
[0004] Technical problem to be solved by the invention
[0005] In order to compensate for the difference between different light-emitting parts, the lighting circuits and lighting devices of the prior art need to adjust the circuit design (for example, adjust the relevant capacitors). When the light-emitting part or the dimming circuit changes, the circuit needs to be redesigned to compensate for the difference. In order to solve the problem of different dimming asynchronism caused by different light-emitting part combinations, the prior art needs to repeatedly adjust the circuit design or MCU program by confirming the differences in different switch / state switching, which increases the cost and is inconvenient. Therefore, how to use a single lighting circuit to conveniently deal with the synchronization of different light-emitting parts when the light-emitting part changes becomes a problem that needs to be solved.
[0006] Solutions for solving the above technical problems
[0007] In order to solve the above problems, the present invention provides a lighting circuit, which includes a light source, a processor, a memory, a detection circuit and a dimming circuit. The light source includes a first light-emitting portion and a second light-emitting portion. The dimming circuit is electrically connected to the first light-emitting portion via a first circuit, and the dimming circuit is electrically connected to the second light-emitting portion via a second circuit. The detection circuit is electrically connected to both the first circuit and the second circuit. The processor is electrically connected to the memory, the dimming circuit and the detection circuit. The processor sends a dimming signal to the dimming circuit to control the light-emitting state of the light source. The memory stores processor-readable instructions. The processor controls the lighting circuit to perform the following steps by executing the processor-readable instructions:
[0008] A detection step, in response to a state switching instruction from a user, the detection circuit detects current values in the first circuit and the second circuit;
[0009] a difference determination step, calculating the difference Δt between the start time t1 of the first current value change of the first circuit and the start time t2 of the second current value change of the second circuit according to the detection result of the detection circuit, and storing the difference Δt in a memory;
[0010] The switching step reads the difference Δt from the memory in response to a state switching instruction from the user, and the processor sets the dimming signal based on the difference Δt in a manner of delaying the start time t1 of the first current value change or advancing the start time t2 of the second current value change.
[0011] According to the above technical solution, the first light emitting unit and the second light emitting unit are components in the lighting circuit for emitting light, and the first light emitting unit and the second light emitting unit constitute a light source. The dimming circuit can adjust the light emitting state of the first light emitting unit and the second light emitting unit, thereby adjusting the light emitting combination state of the light source.
[0012] The detection circuit detects the current values in the first circuit and the second circuit. When the current value changes, the detection circuit can detect the starting time of the current value change, including the starting time t1 of the first current value change of the first circuit and the starting time t2 of the second current value change of the second circuit. The result detected by the detection circuit is transmitted to the processor, and the processor further calculates the difference Δt. After calculating the difference Δt, the processor saves the result in the memory. The difference Δt stored in the memory can be called and read by the processor. When the lighting circuit performs the same or similar switch or state switching process, the processor reads the difference Δt.
[0013] Because there is a difference Δt between the start time t1 of the first current value change of the first circuit and the start time t2 of the second current value change of the second circuit, the first light-emitting unit and the second light-emitting unit cannot keep synchronization when switching the light-emitting state, which affects the lighting effect of the light source. In order to improve the lighting effect, it is necessary to reduce or even eliminate the difference Δt so that the first light-emitting unit and the second light-emitting unit switch synchronously. If the user initializes the lighting circuit or issues an instruction to control the circuit to enter a specific detection mode, the detection circuit is used to know that the start time t1 of the first current value change is earlier than the start time t2 of the second current value change, that is, when not adjusted, the switching action of the first light-emitting unit will be earlier than the switching action of the second light-emitting unit. In the normal use mode, the difference Δt can be eliminated by delaying the start time t1 of the first current value change or advancing the start time t2 of the second current value change.
[0014] Therefore, in the technical solution of the present invention, by adding a detection circuit and a control method that cooperates with the detection circuit, the lighting circuit itself can feedback and adjust the switching action response speed of different light-emitting parts according to the switching action response result of the light-emitting part when the user initializes the lighting circuit or issues a command to control the circuit to enter a specific detection mode. When replacing the dimming circuit or light-emitting part in the lighting circuit, for example, when changing the model or manufacturer of the dimming chip or the model or manufacturer of the light-emitting part, there is no need to make hardware adjustments to the lighting circuit itself or re-burn the software program. In the above manner, a single lighting circuit can be used to conveniently handle the synchronization of different light-emitting parts when the light-emitting part or dimming circuit is changed, taking into account the versatility of the lighting circuit and the synchronization of different light-emitting parts when switching / status.
[0015] Preferably, in the switching step, the processor sets the dimming signal in a manner of delaying the start time t1 of the first current value change by Δt.
[0016] According to the above technical solution, after the user issues a switching instruction, the processor receives the instruction and changes the start time t1 of the first current value change. By delaying the start time t1 of the first current value change by Δt, the time difference between the start time t1 of the first current value change and the start time t2 of the second current value change is 0, thereby achieving synchronous dimming of the light source. The method of delaying the action response to the earlier one is easier to achieve by setting the dimming signal, ensuring that the synchronization task is easier to achieve, and is suitable for synchronization tasks in various usage scenarios such as turning on / off / mode switching.
[0017] Preferably, the detection circuit includes a first detection circuit and a second detection circuit, the first detection circuit is electrically connected to the first circuit, and the second detection circuit is electrically connected to the second circuit. In the detection step, the first detection circuit and the second detection circuit periodically detect the current values in the first circuit and the second circuit at a specified time interval.
[0018] According to the above technical solution, the detection circuit responds to the user's state switching instruction, wherein the first detection circuit detects the current value in the first circuit, and the second detection circuit detects the current value in the second circuit. The first detection circuit and the second detection circuit periodically detect the current value at a specified time interval to achieve automatic detection of the first circuit and the second circuit respectively, so that the user does not need to actively detect the current value in the circuit, and the periodically collected data is easier to analyze the change trend of the current and easier to determine the time starting point of the current change.
[0019] Preferably, the first light-emitting portion and the second light-emitting portion are light-emitting portions with different color temperatures, brightness or colors in a single lighting device.
[0020] According to the above technical solution, since the color temperature, brightness and color of the first light-emitting portion and the second light-emitting portion in a single lighting device are different, different modes can be formed by matching the color temperature, brightness and color.
[0021] Preferably, the dimming circuit is a PWM dimming chip.
[0022] Preferably, the state switching instruction is an on / off instruction or a mode switching instruction.
[0023] According to the above technical solution, the user can issue a state switching instruction through a remote control or other means. When the state switching instruction is an on / off instruction, the first light-emitting unit and the second light-emitting unit can be turned on or off synchronously; when the state switching instruction is a mode switching instruction, the first light-emitting unit and the second light-emitting unit change synchronously, and the time t1 is the same as the time t2, realizing the synchronous mode switching, which is beneficial to improving the visual effect of the lighting device and optimizing the user experience.
[0024] Preferably, the light source is an LED light source.
[0025] Preferably, the present invention provides a lighting device having the above lighting circuit.
[0026] According to the above technical solution, the lighting device can automatically detect and automatically compensate for the difference Δt between the starting moment t1 of the first current value change and the starting moment t2 of the second current value change, so that the first light-emitting part and the second light-emitting part in the lighting device can achieve synchronous dimming, thereby improving the lighting effect of the lighting device and optimizing the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 It is a module diagram of a lighting circuit according to an embodiment of the present invention.
[0028] Figure 2 It is a control flow chart of the lighting circuit according to the embodiment of the present invention.
[0029] Figure 3 3 is a comparison diagram of the first circuit and the second circuit according to the embodiment of the present invention in which the difference Δt is not eliminated.
[0030] Figure 4 FIG. 4 is a comparison diagram of the first circuit and the second circuit according to the embodiment of the present invention after the difference Δt is eliminated.
[0031] Description of Reference Numerals
[0032] 1 light source; 11 first light emitting unit; 12 second light emitting unit; 2 processor; 3 memory; 4 detection circuit; 41 first detection circuit; 42 second detection circuit; 5 dimming circuit; 6 first circuit; 7 second circuit; I1 first circuit current value; I2 second circuit current value. DETAILED DESCRIPTION
[0033] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments 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 creative work are within the scope of protection of the present invention.
[0034] The present invention provides a lighting circuit. Figure 1 is a module diagram of a lighting circuit according to an embodiment of the present invention, such as Figure 1 As shown, the lighting circuit includes a light source 1, a processor 2, a memory 3, a detection circuit 4 and a dimming circuit 5. The light source 1 includes a first light-emitting unit 11 and a second light-emitting unit 12. The dimming circuit 5 is electrically connected to the first light-emitting unit 11 via a first circuit 6. The dimming circuit 5 is electrically connected to the second light-emitting unit 12 via a second circuit 7. The detection circuit 4 is electrically connected to both the first circuit 6 and the second circuit 7. The processor 2 is electrically connected to the memory 3, the dimming circuit 5 and the detection circuit 4.
[0035] In this embodiment, the first light-emitting unit 11 and the second light-emitting unit 12 are components used to emit light in the lighting circuit. The first light-emitting unit 11 and the second light-emitting unit 12 constitute the light source 1. The first light-emitting unit 11 and the second light-emitting unit 12 are set with different brightness, color temperature, color, breathing frequency (regular changes in brightness and / or color temperature over time) or any other suitable light-emitting parameters, so that more types of lighting schemes or modes can be modulated through matching and combination, so that the lighting circuit can be applied to more usage scenarios to meet the user's usage needs. The dimming circuit 5 can adjust the light-emitting state of the first light-emitting unit 11 and the second light-emitting unit 12, thereby adjusting the light-emitting state of the light source 1.
[0036] The processor 2 sends a dimming signal to the dimming circuit 5, and the dimming circuit 5 controls the light-emitting state of the light source 1 according to the dimming signal. The memory 3 stores instructions readable by the processor 2. The processor 2 controls the lighting circuit to perform the following steps by executing the instructions readable by the processor 2: Figure 2 is a control flow chart of a lighting circuit according to an embodiment of the present invention, such as Figure 2 As shown:
[0037] In the detection step S1, in response to the user's state switching instruction, the processor 2 turns on the detection circuit 4 to detect the current values in the first circuit 6 and the second circuit 7. Specifically, in response to the user's state switching instruction, for example, when the user initializes the lighting circuit or issues an instruction to control the circuit to enter a specific detection mode, the detection circuit 4 is started. After the detection step S1 starts, the detection circuit 4 detects the current values in the first circuit 6 and the second circuit 7 every 10μs-5ms, for example, 200μs, and generates the following according to the periodically detected current values: Figure 3 The current changes with time as shown. Usually, when the lighting circuit receives the state switching instruction, when the difference Δt between the first light-emitting unit 11 and the second light-emitting unit 12 is less than 5ms, it can be ignored by the human eye, so at least the difference Δt greater than 5ms needs to be adjusted. In the time period of the difference Δt, there must be at least 3 detections, and the detection cycle is usually 10μs-5ms. For example, when the difference Δt is detected to be 20ms, the detection cycle should be adjusted to no more than 6.6ms, such as 200μs. When the lighting circuit is initialized or enters a specific detection mode, when the current value changes, the detection circuit 4 sends the relevant detection results to the processor 2, and the processor 2 can analyze the starting time of the current value change according to the detection results or the generated curve graph, for example, the starting time of the current value change can be determined according to the comparison between the slope of the curve and the threshold or any other suitable calculation method. The analyzed starting time includes the first current value change starting time t1 of the first circuit 6 and the second current value change starting time t2 of the second circuit 7, and then enters the difference determination step S2.
[0038] In the difference determination step S2, after receiving the data from the detection circuit 4, the processor 2 further calculates the difference Δt between the first current value change start time t1 of the first circuit 6 and the second current value change start time t2 of the second circuit 7 according to the detection result of the detection circuit 4. After calculating the difference Δt, the processor 2 sends the difference Δt to the memory 3 and stores it in the memory 3, then exits the initialization process of the lighting circuit, or exits the detection mode, and responsively enters the switching step S3 when re-executing the same or similar switch / mode switching process.
[0039] In the switching step S3, the difference Δt stored in the memory 3 can be called and read by the processor 2. When the lighting circuit needs to dim the light source 1, in response to the user's state switching instruction, the processor 2 reads the difference Δt from the memory 3, and the processor 2 sets the dimming signal based on the difference Δt in a manner of postponing the start time t1 of the first current value change or advancing the start time t2 of the second current value change. When the lighting circuit performs the same or similar switch or state switching process, the processor 2 also reads the difference Δt and sets the dimming signal in a manner of postponing the start time t1 of the first current value change or advancing the start time t2 of the second current value change. For example, if in the detection mode, it is detected that the lighting circuit will generate an action response delay between the first light-emitting unit 11 and the second light-emitting unit 12 when the lighting device is turned off, then the corresponding difference Δt1 is recorded for the turning-off action, and the difference Δt1 is read and loaded each time the lighting device is turned off after exiting the detection mode, so as to maintain the synchronization between the first light-emitting unit 11 and the second light-emitting unit 12. For another example, if in the detection mode, it is detected that the lighting circuit will generate an action response delay between the first light-emitting unit 11 and the second light-emitting unit 12 during the color temperature mode switching process, the corresponding Δt2 is recorded for the color temperature mode switching process, and the difference Δt2 is read and loaded during each color temperature mode switching action after exiting the detection mode to maintain the synchronization between the first light-emitting unit 11 and the second light-emitting unit 12 under the color temperature mode switching action.
[0040] Figure 3 : is a comparison diagram of the first circuit 6 and the second circuit 7 in the embodiment of the present invention where the difference Δt is not eliminated (in the figure, I represents current, t represents time, I1 represents the current value of the first circuit 6, and I2 represents the current value of the second circuit 7). Figure 3 As shown, because there is a difference Δt between the first current value change start time t1 of the first circuit 6 and the second current value change start time t2 of the second circuit 7, the light-emitting state switching of the first light-emitting unit 11 and the second light-emitting unit 12 cannot be synchronized, which affects the lighting effect of the light source 1. In order to improve the lighting effect, it is necessary to reduce or even eliminate the difference Δt so that the first light-emitting unit 11 and the second light-emitting unit 12 can switch synchronously.
[0041] If the user initializes the lighting circuit or issues an instruction to control the circuit to enter a specific detection mode, the detection circuit 4 is used to detect that the starting time t1 of the first current value change is earlier than the starting time t2 of the second current value change, that is, when no adjustment is made, the switching action of the first light-emitting unit 11 will be earlier than the switching action of the second light-emitting unit 12. Figure 4 is a comparison diagram of the first circuit 6 and the second circuit 7 in the embodiment of the present invention after the difference Δt has been eliminated. Figure 4As shown, in the normal use mode, the difference Δt can be eliminated by delaying the first current value change start time t1 or advancing the second current value change start time t2. After the difference Δt is eliminated, the processor 2 controls the detection circuit 4 to stop detecting the current value.
[0042] Therefore, in the technical solution of the present invention, by adding a detection circuit 4 and a control method coordinated with the detection circuit 4, the lighting circuit itself can feedback and adjust the switching action response speed of different light-emitting parts according to the switching action response result of the light-emitting part when the user initializes the lighting circuit or issues a command to control the circuit to enter a specific detection mode. When replacing the dimming circuit 5 or the light-emitting part in the lighting circuit, for example, when changing the model or manufacturer of the dimming chip or the model or manufacturer of the light-emitting part, there is no need to make hardware adjustments to the lighting circuit itself or re-burn the software program. In the above manner, a single lighting circuit can be used to conveniently handle the synchronization of different light-emitting parts when the light-emitting part or the dimming circuit 5 is changed, taking into account the versatility of the lighting circuit and the synchronization of different light-emitting parts when switching / status.
[0043] In this embodiment, the processor 2 and the memory 3 can be separately set. In other embodiments of the present invention, other settings are also possible, which are not specifically limited here. For example, the memory 3 can be integrated on the processor 2 to form an independent MCU chip, which can reduce the space occupied by the lighting circuit and is conducive to the integration and miniaturization of the lighting circuit.
[0044] Preferably, in the switching step S3 , the processor 2 sets the dimming signal in a manner of delaying the start time t1 of the first current value change by Δt.
[0045] In this embodiment, after the user issues a switching instruction, the processor 2 receives the instruction and changes the first current value change start time t1. By delaying the first current value change start time t1 by Δt, the difference Δt between the first current value change start time t1 and the second current value change start time t2 is eliminated, thereby achieving synchronous dimming of the light source 1. The method of delaying the action response to the earlier one is easier to achieve by setting the dimming signal, ensuring that the synchronization task is easier to achieve, and is suitable for synchronization tasks in various usage scenarios such as opening / closing / mode switching.
[0046] Preferably, the detection circuit 4 includes a first detection circuit 41 and a second detection circuit 42, the first detection circuit 41 is electrically connected to the first circuit 6, and the second detection circuit 42 is electrically connected to the second circuit 7. In the detection step S1, the first detection circuit 41 and the second detection circuit 42 periodically detect the current values in the first circuit 6 and the second circuit 7 at a prescribed time interval.
[0047] In this embodiment, in response to the user's state switching instruction, the first detection circuit 41 detects the current value in the first circuit 6, and the second detection circuit 42 detects the current value in the second circuit 7. The user's state switching instruction can be issued in the form of a remote control, or in the form of voice or mobile phone operation, or in other forms, which are not specifically limited here. The first detection circuit 41 and the second detection circuit 42 periodically detect the current value at a prescribed time interval to achieve automatic detection of the first circuit 6 and the second circuit 7, so that the user does not need to actively operate the current value in the detection circuit 4. When the prescribed time interval is small enough, as long as the current value of the first circuit 6 and the second circuit 7 changes, the detection circuit 4 can quickly detect and transmit the data to the processor 2. The periodically collected data makes it easier to analyze the trend of current changes and to determine the starting point of the current change.
[0048] Preferably, the first light-emitting portion 11 and the second light-emitting portion 12 are light-emitting portions with different color temperatures, brightness or colors in a single lighting device.
[0049] In this embodiment, the first light-emitting unit 11 can emit electric spherical light (for example, light with a color temperature of 2000-3000K), and the second light-emitting unit 12 can emit white light (for example, light with a color temperature of 5000-6000K). The light emitted by the first light-emitting unit 11 and the second light-emitting unit 12 can be combined into multiple modes to suit different usage scenarios. The different modes include a light-off mode, a full-brightness mode, a warm white mode, and a daylight mode. When the first light-emitting part 11 and the second light-emitting part 12 are both turned off, the first light-emitting part 11 and the second light-emitting part 12 form a light-off mode, which is suitable for scenarios where the user needs to take a rest; when the first light-emitting part 11 and the second light-emitting part 12 are both turned on, the first light-emitting part 11 and the second light-emitting part 12 form a full-brightness mode, which is suitable for daily life scenes; when the first light-emitting part 11 is turned on and the second light-emitting part 12 is turned off, the first light-emitting part 11 and the second light-emitting part 12 form a warm white mode, which is suitable for night scenes; when the first light-emitting part 11 is turned off and the second light-emitting part 12 is turned on, the first light-emitting part 11 and the second light-emitting part 12 form a daylight color mode, which is suitable for daytime scenes.
[0050] In some other embodiments of the present invention, the first light-emitting portion 11 and the second light-emitting portion 12 are not limited to electric color or white. The first light-emitting portion 11 and the second light-emitting portion 12 may also be light-emitting portions of other color temperatures, brightness or colors.
[0051] Preferably, the dimming circuit 5 is a PWM dimming chip.
[0052] Because the lighting circuit can automatically detect and calculate the difference Δt between the starting time t1 of the first current value change and the starting time t2 of the second current value change, and eliminate the difference Δt during dimming, even if a different type of dimming circuit 5 is replaced, the lighting circuit can automatically adjust to adapt to the new dimming circuit 5 without re-setting, and can still maintain the original synchronous dimming function.
[0053] Preferably, the state switching instruction is an on / off instruction or a mode switching instruction.
[0054] In this embodiment, the user can issue a state switching instruction through a remote control or other means. When the state switching instruction is an on / off instruction, the first light-emitting unit 11 and the second light-emitting unit 12 can be turned on or off synchronously; when the state switching instruction is a mode switching instruction, the first light-emitting unit 11 and the second light-emitting unit 12 change synchronously, and the starting time t1 of the first current value change is the same as the starting time t2 of the second current value change, thereby realizing synchronous mode switching, which is beneficial to improving the visual effect of the lighting device and optimizing the user experience.
[0055] Preferably, the light source 1 is an LED light source 1 .
[0056] In some other embodiments of the present invention, the light source 1 of the lighting circuit is not limited to the LED light source 1, but can also be other types of light sources 1, which are not specifically limited here, such as EL elements such as organic EL (full name Electroluminescence) or inorganic EL.
[0057] The present invention also provides a lighting device having the lighting circuit.
[0058] In this embodiment, the lighting device has a lampshade and a lamp holder, the lamp holder is used to be fixedly connected to the installation position of the lighting device, and the lampshade protects the light source 1 and serves as a decoration. The lighting device can automatically detect and automatically compensate for the difference Δt between the start time t1 of the first current value change and the start time t2 of the second current value change, so that the first light-emitting part 11 and the second light-emitting part 12 in the lighting device can achieve synchronous dimming, improve the lighting effect of the lighting device and optimize the user experience.
[0059] So far, the technical solutions of the present invention have been described in conjunction with the multiple embodiments shown in the accompanying drawings. However, it is easy for those skilled in the art to understand that the protection scope of the present invention is obviously not limited to these specific embodiments. Without departing from the principle of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will fall within the protection scope of the present invention.
Claims
1. A lighting circuit, characterized in that: The lighting circuit includes a light source, a processor, a memory, a detection circuit and a dimming circuit. The light source includes a first light-emitting unit and a second light-emitting unit. The dimming circuit is electrically connected to the first light-emitting unit via a first circuit, and the dimming circuit is electrically connected to the second light-emitting unit via a second circuit. The detection circuit is electrically connected to both the first circuit and the second circuit. The processor is electrically connected to the memory, the dimming circuit and the detection circuit. The processor sends a dimming signal to the dimming circuit to control the light-emitting state of the light source. The memory stores processor-readable instructions. The processor controls the lighting circuit to perform the following steps by executing the processor-readable instructions: A detection step, in response to a state switching instruction from a user, the detection circuit detecting current values in the first circuit and the second circuit; a difference determination step, calculating the difference Δt between the start time t1 of the first current value change of the first circuit and the start time t2 of the second current value change of the second circuit according to the detection result of the detection circuit, and storing the difference Δt in the memory; The switching step reads the difference Δt from the memory in response to the state switching instruction of the user, and the processor sets the dimming signal based on the difference Δt in a manner of delaying the starting time t1 of the first current value change or advancing the starting time t2 of the second current value change.
2. The lighting circuit according to claim 1, characterized in that: In the switching step, the processor sets the dimming signal in a manner of delaying a start time t1 of the first current value change by Δt.
3. The lighting circuit according to claim 1 or 2, characterized in that: The detection circuit includes a first detection circuit and a second detection circuit, the first detection circuit is electrically connected to the first circuit, and the second detection circuit is electrically connected to the second circuit. In the detection step, the first detection circuit and the second detection circuit both periodically detect the current values in the first circuit and the second circuit at specified time intervals.
4. The lighting circuit according to claim 1 or 2, characterized in that: The first light-emitting portion and the second light-emitting portion are light-emitting portions with different color temperatures, brightness or colors in a single lighting device.
5. The lighting circuit according to claim 1, characterized in that: The dimming circuit is a PWM dimming chip.
6. The lighting circuit according to claim 1, characterized in that: The state switching instruction is an on / off instruction or a mode switching instruction.
7. The lighting circuit according to claim 1, characterized in that: The light source is an LED light source.
8. A lighting device, characterized in that: A lighting circuit as claimed in any one of claims 1 to 7.
