Dimming method, dimming device and computer storage medium

By using dimming equipment in smart lamps to communicate directly with the lighting equipment, and updating the dimming value according to the ambient brightness value and target brightness value, the problem of poor dimming effect and long time of smart lamps is solved, and fast and efficient Dimming effect and expanding application range.

CN115119365BActive Publication Date: 2025-01-07HANGZHOU TUYA INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210682151.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-02-08
Publication Date
2025-01-07
Estimated Expiration
2041-02-08

AI Technical Summary

Technical Problem

The dimming effect of smart lamps needs to be improved, and the dimming time in the prior art is long and the application range is limited.

Method used

Provide a dimming method. When the dimming device receives and saves the current environmental brightness value, judges the difference between the target brightness value, updates the dimming value according to the difference value, and directly uses the Zigbee protocol to perform direct connection with the lighting device. Communication, send dimming commands to realize dimming, and the dimming value is adjusted according to the difference after each dimming.

Benefits of technology

Shortens dimming time, improves dimming effect, and expands the application range, and can be suitable for any environment and lighting equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115119365B_ABST
    Figure CN115119365B_ABST
Patent Text Reader

Abstract

The present application discloses a dimming method, a dimming device and a computer storage medium, the dimming method comprising: upon receiving a trigger instruction, obtaining and saving the current ambient brightness value; judging whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range; if the judgment result is no, obtaining the saved dimming value and determining the dimming direction; sending a dimming instruction to the lighting device, the dimming instruction carrying the dimming direction and the dimming value; obtaining the current ambient brightness value after a preset time of sending the dimming instruction; calculating the brightness difference between the current ambient brightness value and the saved ambient brightness value, and updating the saved dimming value according to the brightness difference; updating the saved ambient brightness value with the current ambient brightness value; returning to execute the step of judging whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range. The dimming method provided by the present application can shorten the dimming time and improve the dimming effect.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of intelligent dimming technology, and in particular to a dimming method, a dimming device and a computer storage medium. Background Art

[0002] Lamps are the most common devices that provide lighting, and are also one of the important auxiliary tools that are essential in our normal life, study and work.

[0003] In the traditional field of lighting adjustment, local operations such as knobs and button lights are usually used to control the brightness and color of lights. However, with the popularization and development of smart terminals, smart lamps with automatic dimming have become an inevitable development trend.

[0004] The inventors of the present application have found in long-term research that the dimming effect of current smart lamps needs to be improved. Summary of the invention

[0005] The main technical problem solved by the present application is to provide a dimming method, a dimming device and a computer storage medium, which can shorten the dimming time and improve the dimming effect.

[0006] To solve the above technical problems, a technical solution adopted by the present application is: to provide a dimming method, the method comprising: when the dimming device receives a trigger instruction, obtaining and saving the current ambient brightness value; judging whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range; if the judgment result is no, obtaining the saved dimming value, and determining the dimming direction according to the current ambient brightness value and the target brightness value; sending a dimming instruction to the lighting device with a communication connection, the dimming instruction carrying the dimming direction and the dimming value; obtaining the current ambient brightness value after a preset time of sending the dimming instruction; calculating the brightness difference between the current ambient brightness value and the saved ambient brightness value, and updating the saved dimming value according to the brightness difference; updating the saved ambient brightness value with the current ambient brightness value; returning to execute the step of judging whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range; wherein, according to the brightness The step of updating the stored dimming value by the difference value comprises: if the absolute value of the brightness difference value is less than the first value, superimposing the stored dimming value with the first adjustment value, and updating the stored dimming value with the superimposed result; if the absolute value of the brightness difference value is not less than the first value but less than the second value, superimposing the stored dimming value with the second adjustment value, and updating the stored dimming value with the superimposed result, wherein the first value and the second value are both less than the adjustment step, and the first value is less than the second value, the first adjustment value is greater than the second adjustment value, and the first adjustment value and the second adjustment value are both greater than zero; if the absolute value of the brightness difference value is not less than the second value but less than or equal to the adjustment step, keeping the stored dimming value unchanged; if the absolute value of the brightness difference value is greater than the adjustment step, reducing the stored dimming value; wherein the adjustment step represents the expected change value of the ambient brightness each time the illumination device adjusts the brightness according to the dimming instruction.

[0007] To solve the above technical problems, another technical solution adopted in the present application is: to provide a dimming device, the dimming device includes a processor, a memory and a communication circuit, the processor is coupled to the memory and the communication circuit respectively, the memory stores program data, and the processor implements the steps in the above method by executing the program data in the memory.

[0008] In order to solve the above technical problem, another technical solution adopted by the present application is: providing a computer storage medium, wherein the computer storage medium stores a computer program, and the computer program can be executed by a processor to implement the steps in the above method.

[0009] The beneficial effect of the present application is that after dimming the lighting device, the dimming method in the present application will update the dimming value according to the dimming result, so that there is no requirement for the relative position between the sensor for collecting ambient brightness values ​​and the lighting device, and the environment in which they are located. That is, the dimming method in the present application can not only shorten the dimming time and improve the dimming effect, but also expand the scope of application. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. Among them:

[0011] Figure 1 It is a flow chart of an implementation method of the dimming method of the present application;

[0012] Figure 2 It is a link diagram of the interaction between the dimming device and the lighting device in the prior art;

[0013] Figure 3 It is a link diagram of the interaction between the dimming device and the lighting device in this application;

[0014] Figure 4 It is a structural schematic diagram of an implementation method of a dimming device of the present application;

[0015] Figure 5 It is a structural schematic diagram of an implementation method of a computer storage medium of the present application. DETAILED DESCRIPTION

[0016] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0017] See also Figure 1 , Figure 1 1 is a flow chart of an embodiment of a dimming method of the present application, the dimming method comprising:

[0018] S110: When receiving the trigger instruction, the dimming device obtains and saves the current ambient brightness value.

[0019] Specifically, the dimming device may have the function of collecting ambient brightness values, for example, the dimming device is integrated with a sensor for collecting ambient brightness values, or it may not have the function of collecting ambient brightness values, but establishes a communication connection with the sensor for collecting ambient brightness values ​​to obtain the current ambient brightness value. When the dimming device has the function of collecting ambient brightness values, the dimming device and the lighting device are installed in the same space; when the dimming device does not have the function of collecting ambient brightness values, the sensor for establishing a communication connection with the dimming device and the lighting device are installed in the same space. For the sake of convenience, the following description assumes that the dimming device has the function of collecting ambient brightness values.

[0020] A trigger instruction may be an instruction sent by a user. For example, when a user wants to adjust the brightness value of a lighting device, the user sends a dimming instruction to the dimming device. The dimming instruction is the trigger instruction. Alternatively, the trigger instruction is automatically generated by the dimming device according to a preset rule. For example, if the user sets dimming every half an hour, the dimming device generates a trigger instruction every half an hour.

[0021] S120: Determine whether the brightness difference between the current environment brightness value and the target brightness value is within a preset range.

[0022] If the judgment result is yes, the process ends, that is, entering step S180; if the judgment result is no, entering step S130.

[0023] Specifically, the target brightness value may be carried in the trigger instruction, or may be pre-set and stored in the dimming device, which is not limited here.

[0024] At the same time, if the brightness difference between the current ambient brightness value and the target brightness value is within the preset range, it means that the current ambient brightness value meets the requirements. Near the target brightness value, there is no need to dim the lighting device, and the process ends directly.

[0025] S130: Obtain the saved dimming value, and determine the dimming direction according to the current ambient brightness value and the target brightness value.

[0026] Specifically, the dimming value is a magnitude value of the brightness increase or decrease of the lighting device.

[0027] At the same time, if the current ambient brightness value is greater than the target brightness value, the dimming direction is downward, that is, the brightness of the lighting device needs to be reduced. If the current ambient brightness value is less than the target brightness value, the dimming direction is upward, that is, the brightness of the lighting device needs to be increased.

[0028] S140: Send a dimming instruction to the lighting device with which the communication connection is established, where the dimming instruction carries a dimming direction and a dimming value.

[0029] Specifically, after receiving the dimming instruction, the lighting device performs dimming according to the dimming instruction.

[0030] The units of the ambient brightness value and the target brightness value are lux, the brightness value of the lighting device is the level value, and the level value range is 0-255, representing 0-100% brightness. That is, the unit of the ambient brightness value is different from the unit of the lighting device brightness value. It is understandable that the unit of the dimming value is the same as the unit of the lighting device brightness value, but different from the unit of the ambient brightness value.

[0031] In one application scenario, in order to reduce the entire dimming time, the dimming instruction sent by the dimming device to the lighting device carries a communication identifier that can be recognized by the lighting device.

[0032] Specifically, combined Figure 2 and Figure 3 In the conventional dimming method of the prior art, the lighting device reports the current ambient brightness value to the gateway, and then the gateway reports it to the cloud. The cloud then compares the value set by the user (i.e., the target brightness value). If the absolute value of the difference between the two exceeds the preset value, a dimming instruction is sent to the gateway, and the gateway forwards it to the lighting device. The process has a long link, which is not conducive to reducing the dimming time.

[0033] In this embodiment, the dimming device and the lighting device communicate with each other using Zigbee (Zigbee protocol, which allows devices to exchange data in a group manner) group communication. The dimming device and the lighting device pre-establish a group, that is, the dimming device and the lighting device share a communication identifier. Then, during the dimming process, the dimming device sends a dimming instruction to the lighting device by multicast, that is, the dimming instruction sent by the dimming device carries the shared communication identifier. After receiving the dimming instruction, the lighting device performs authentication, and after successful authentication, adjusts the brightness according to the dimming instruction. Figure 2 and Figure 3 It can be seen that in this embodiment, there is no need for a gateway to relay and forward data, and its communication link can be shortened compared to the communication link in the prior art, thereby avoiding dimming delays caused by too long a data link and further improving dimming efficiency.

[0034] S150: After a preset time of sending the dimming instruction, the current environment brightness value is obtained.

[0035] Specifically, after a preset time when the dimming device sends the dimming instruction, it is determined that the lighting device has adjusted the brightness according to the dimming instruction. The current ambient brightness value obtained at this time is the brightness value of the current environment after the lighting device adjusts the brightness.

[0036] S160: Calculate the brightness difference between the current ambient brightness value and the saved ambient brightness value, and update the saved dimming value according to the brightness difference.

[0037] Specifically, the saved ambient brightness value is the ambient brightness value before dimming. Therefore, it can be understood that the brightness difference between the current ambient brightness value and the saved ambient brightness value represents the change in ambient brightness after the lighting device adjusts the brightness according to the dimming instruction, that is, the brightness difference is feedback on the dimming value carried by the dimming instruction, reflecting the dimming effect, and then the saved dimming value is updated according to the brightness difference, so that the dimming value carried by the dimming instruction sent next time is the updated dimming value, that is, the next dimming effect is adjusted, thereby shortening the dimming time and improving the dimming effect.

[0038] It should be noted that after the dimming device receives the trigger instruction, the dimming value carried in the dimming instruction sent to the lighting device for the first time is preset and stored in the dimming device.

[0039] Specifically, the relationship between the brightness difference between the current ambient brightness value and the saved ambient brightness value and the dimming value is affected by factors such as the relative position between the sensor (used to collect the ambient brightness value) and the lighting device and the ambient light. That is, as the relative position between the sensor and the lighting device and the surrounding environment change, the relationship between the brightness difference between the current ambient brightness value and the saved ambient brightness value (the result of the change in the ambient brightness value) and the dimming value is not fixed. Therefore, the dimming value carried by the dimming instruction sent to the lighting device for the first time is set in advance.

[0040] In one application scenario, the step of updating the saved dimming value according to the brightness difference includes: if the absolute value of the brightness difference is less than the adjustment step, increasing the saved dimming value; if the absolute value of the brightness difference is equal to the adjustment step, keeping the saved dimming value unchanged; if the absolute value of the brightness difference is greater than the adjustment step, reducing the saved dimming value.

[0041] Specifically, the adjustment step represents the expected change in ambient brightness each time the lighting device adjusts the brightness according to the dimming instruction. When increasing or decreasing the dimming value, a fixed value may be increased or decreased.

[0042] When a trigger instruction is received, the absolute value of the brightness difference between the current environment brightness value and the target brightness value is calculated; and the adjustment step is determined according to the absolute value of the brightness difference.

[0043] The step of determining the adjustment step according to the absolute value of the brightness difference includes: calculating the product of the absolute value of the brightness difference and the inverse of the acquired dimming time; and using the product as the adjustment step.

[0044] Specifically, the dimming time is input by the user, and the adjustment step Det=|(T_V-S_V)| / T, wherein T_V represents the current ambient brightness value obtained when the trigger instruction is received, S_V represents the target brightness value, and T represents the dimming time.

[0045] In other application scenarios, the calculation formula for the adjustment step can also be: Det = |(T_V-S_V)| / N, where T_V represents the current ambient brightness value obtained when the trigger command is received, S_V represents the target brightness value, and N represents the number of dimming times. Similarly, the number of dimming times N can also be input by the user.

[0046] In another application scenario, the step of updating the saved dimming value according to the brightness difference includes: if the absolute value of the brightness difference is less than the first value, superimposing the saved dimming value with the first adjustment value, and updating the saved dimming value with the superimposed result; if the absolute value of the brightness difference is not less than the first value but less than the second value, superimposing the saved dimming value with the second adjustment value, and updating the saved dimming value with the superimposed result, wherein the first value and the second value are both less than the adjustment step, and the first value is less than the second value, the first adjustment value is greater than the second adjustment value, and the first adjustment value and the second adjustment value are both greater than zero; if the absolute value of the brightness difference is not less than the second value but less than or equal to the adjustment step, keeping the saved dimming value unchanged; if the absolute value of the brightness difference is greater than the adjustment step, reducing the saved dimming value.

[0047] The first value is one third of the adjustment step, and the second value is two thirds of the adjustment step, or the first value is one fourth of the adjustment step, and the second value is three fourths of the adjustment step, as long as the first value and the second value are both smaller than the adjustment step, and the first value is smaller than the second value, no specific limitation is made here. For the sake of convenience, the following description assumes that the first value is one third of the adjustment step, and the second value is two thirds of the adjustment step.

[0048] Specifically, when the absolute value of the brightness difference is less than one-third of Det, it means that the intensity of the dimming value is not enough, and the dimming value A1=A1+B1 is set (A1 is the dimming value, B1 is the first adjustment value, that is, the saved dimming value is superimposed on the first adjustment value, and the dimming value is updated with the superimposed result); when the absolute value of the brightness difference is greater than or equal to one-third of Det but less than two-thirds of Det, it means that although the dimming is effective, it fails to achieve the expected effect, and the dimming value A1=A1+B2 is set (B2 is the second adjustment value, that is, the saved dimming value is superimposed on the second adjustment value, and the dimming value is updated with the superimposed result); when the absolute value of the brightness difference is greater than or equal to two-thirds of Det but less than or equal to Det, it means that the dimming effect is good, and A1=A1 is set (that is, the dimming value is kept unchanged); when the absolute value of the brightness difference is greater than the adjustment step, it means that the dimming effect is too strong, and A1=A1-B3 is set (B3 is the third adjustment value, the third adjustment value is greater than zero, that is, the saved dimming value is reduced).

[0049] In one application scenario, after superimposing the saved dimming value with the first adjustment value and updating the saved dimming value with the superimposed result, it also includes: judging whether the result of superimposing the saved dimming value with the first adjustment value is less than the dimming threshold; if the judgment result is yes, updating the saved dimming value with the superimposed result; if the judgment result is no, issuing a prompt message.

[0050] Specifically, if the result of superimposing the saved dimming value and the first adjustment value is greater than or equal to the dimming threshold, it means that the superimposed result has reached the dimming upper limit. At this time, the lighting device or sensor may be installed incorrectly, or there may be abnormal light source interference, etc., and the user is reminded.

[0051] The above describes in detail how to update the saved dimming value. Figure 1 , the steps after step S160 are described in detail.

[0052] S170: Update the saved ambient brightness value with the current ambient brightness value.

[0053] Specifically, the current environment brightness value is saved so as to update the dimming value next time.

[0054] Then after executing step S170, return to execute step S120.

[0055] S180: End the process.

[0056] From the above content, it can be seen that after dimming the lighting device, the dimming method in this embodiment will update the dimming value according to the dimming result, that is, update the dimming value according to the feedback result. The dimming value is not fixed, and the dimming value does not need to be set according to the change result of the ambient brightness value. Therefore, there are no requirements for the relative position between the sensor for collecting the ambient brightness value and the lighting device, and the environment in which it is located. That is, the dimming method in this application can not only shorten the dimming time and improve the dimming effect, but also be suitable for any application scenario.

[0057] At the same time, the lighting device in this embodiment can also communicate with remote terminals such as mobile phones and computers, and users can control the on and off, brightness, color temperature, etc. of the lighting device through the remote terminal.

[0058] See also Figure 4 , Figure 4 1 is a schematic diagram of the structure of an embodiment of a dimming device of the present application. The dimming device 200 includes a processor 210, a memory 220, and a communication circuit 230. The processor 210 is coupled to the memory 220 and the communication circuit 230 respectively. The memory 220 stores program data. The processor 210 implements the steps of the dimming method in any of the above embodiments by executing the program data in the memory 220. The detailed steps can be found in the above embodiments and will not be repeated here.

[0059] See also Figure 5 , Figure 5 The computer storage medium 300 stores a computer program 310, which can be executed by a processor to implement the steps in any of the above methods.

[0060] Among them, the computer storage medium 300 can specifically be a device that can store the computer program 310, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, or it can also be a server that stores the computer program 310. The server can send the stored computer program 310 to other devices for execution, or it can also run the stored computer program 310 by itself.

[0061] The above description is only an implementation method of the present application, and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly used in other related technical fields, are also included in the patent protection scope of the present application.

Claims

1. A dimming method, characterized in that: The method comprises: When receiving the trigger command, the dimming device obtains and saves the current ambient brightness value; Determine whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range; If the judgment result is no, obtaining the saved dimming value, and determining the dimming direction according to the current ambient brightness value and the target brightness value; Sending a dimming instruction to the lighting device with which the communication connection is established, wherein the dimming instruction carries the dimming direction and the dimming value; After a preset time of sending the dimming instruction, obtaining the current ambient brightness value; Calculating a brightness difference between the current ambient brightness value and the stored ambient brightness value, and updating the stored dimming value according to the brightness difference; Updating the stored ambient brightness value with the current ambient brightness value; Return to the step of determining whether the brightness difference between the current ambient brightness value and the target brightness value is within a preset range; Wherein, the step of updating the stored dimming value according to the brightness difference value comprises: if the absolute value of the brightness difference value is less than the first value, superimposing the stored dimming value with the first adjustment value, and updating the stored dimming value with the superimposed result; if the absolute value of the brightness difference value is not less than the first value but less than the second value, superimposing the stored dimming value with the second adjustment value, and updating the stored dimming value with the superimposed result, wherein the first value and the second value are both less than the adjustment step, and the first value is less than the second value, the first adjustment value is greater than the second adjustment value, and the first adjustment value and the second adjustment value are both greater than zero; if the absolute value of the brightness difference value is not less than the second value but less than or equal to the adjustment step, keeping the stored dimming value unchanged; if the absolute value of the brightness difference value is greater than the adjustment step, reducing the stored dimming value; The adjustment step represents the expected change in ambient brightness each time the lighting device adjusts the brightness according to the dimming instruction.

2. The method according to claim 1, characterized in that The step of sending a dimming instruction to the lighting device that has established a communication connection includes: The dimming instruction carrying the communication identifier recognizable by the lighting device is sent to the lighting device that has established a communication connection.

3. The method according to claim 1, characterized in that The step of superimposing the stored dimming value with the first adjustment value and updating the stored dimming value with the superimposed result further comprises: Determine whether a result of superimposing the stored dimming value and the first adjustment value is less than a dimming threshold; If the judgment result is yes, the stored dimming value is updated with the superimposed result; If the judgment result is no, a prompt message is issued.

4. The method according to claim 1, characterized in that: The first value is one third of the adjustment step, and the second value is two thirds of the adjustment step.

5. The method according to claim 1, characterized in that The method further comprises: When receiving the trigger instruction, calculating the absolute value of the brightness difference between the current ambient brightness value and the target brightness value; The adjustment step is determined according to the absolute value of the brightness difference.

6. The method according to claim 5, characterized in that The step of determining the adjustment step according to the absolute value of the brightness difference comprises: Calculating the product of the absolute value of the brightness difference and the obtained reciprocal of the dimming time; The product is taken as the adjustment step.

7. A dimming device, characterized in that: The dimming device includes a processor, a memory and a communication circuit, the processor is coupled to the memory and the communication circuit respectively, the memory stores program data, and the processor implements the steps in the method as described in any one of claims 1-6 by executing the program data in the memory.

8. A computer storage medium, characterized in that The computer storage medium stores a computer program, and the computer program can be executed by a processor to implement the steps in the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Light-adjusting scale adjusting apparatus and light adjusting method for driving luminous unit

    CN102548113A

  • Information processing method and electronic equipment

    CN104915166A