Disclosure of Invention
The invention mainly designs a timing remote control method based on time correction, which comprises the steps that after a timing key sets timing time, when other keys are pressed down, the timing time is calibrated by utilizing at least one time correction mode; and issuing the calibrated timing time to the master control equipment. According to the scheme, after the timing is set through the remote controller, other keys are pressed again, the remote controller can evaluate and calculate the timing time sent to the main control according to the current time again, and meanwhile, the remote controller automatically sends the timing time to the main control equipment again every fixed time interval, so that the timing time is corrected absolutely, and continuous accumulation of periodic timing time errors is avoided. Through the correction mode of at least one of the above, on the premise of not increasing the cost, the timing precision is effectively improved, the code sending times of the remote controller are reduced, and the power consumption is reduced.
In a first aspect, the present invention provides a timing remote control method based on time correction, which includes:
after the timing key sets the timing time, when other keys are pressed, the timing time is calibrated by using at least one time correction mode;
and issuing the calibrated timing time to the master control equipment.
As a further embodiment of the first aspect of the present invention, after the timing key sets a timing time, when the other key is pressed, calibrating the timing time by using at least one time correction method includes:
Recording the set timing time of the timing key as a first time, starting timing by taking the first time as a starting time point, taking the timing time length as a first time length, recording the pressed time of the other keys as a second time length, and subtracting the first time length from the second time length as a second time length;
Correcting the timing time according to a second duration;
correcting the timing time according to a first time length;
And doubly correcting the timing time according to the second time length and the first time length.
As a further embodiment of the first aspect of the present invention, the correcting the timing time according to the second duration includes:
correcting the timing time when the main control equipment is in a starting state;
and correcting the timing time when the main control equipment is in a shutdown state.
As a further embodiment of the first aspect of the present invention, correcting the timing time when the master control device is in the on state includes:
when the second duration is within a first preset range, the timing time is kept at the original timing time;
when the second duration is within a second preset range, the timing time is the original timing time minus a preset deviation value delta;
When the second duration is within a third preset range, the timing time is obtained by subtracting the preset deviation delta from the current timing time;
And when the round robin is performed, the timing time is gradually reduced until the timing time is within the last remaining time threshold of the timing startup, if the other keys are pressed, executing the timing startup instruction, and resetting the timing time.
As a further embodiment of the first aspect of the present invention, correcting the timing time when the master control apparatus is in the off state includes:
when the second duration is within a first preset range, the timing time is kept at the original timing time;
when the second duration is within a second preset range, the timing time is the original timing time minus the preset deviation delta;
When the second duration is within a third preset range, the timing time is obtained by subtracting the preset deviation delta from the current timing time;
When the round robin is performed, the timing time is gradually reduced until the timing time is within a last residual time threshold of the timing shutdown, if other keys except the on/off key are pressed, the relevant flag bit is cleared, and information is transmitted according to the set state;
And canceling the timing or setting the timing time by pressing the timing key again after the timing time is reduced to zero, wherein the current timing time is the timing time set last time.
As a further embodiment of the first aspect of the present invention, the timing key or the other key being pressed comprises:
The key is pressed and information is transmitted.
As a further embodiment of the first aspect of the present invention, the correcting the timing time according to the first time length includes:
when the first duration is n times of the preset deviation delta, the current timing time is the original timing time minus n times of the delta, namely the current timing time is S-n times of the delta, wherein n is the serial number of the n delta which starts to be timed after the timing duration exceeds the upper limit value of the first preset range, and S is the original timing time.
As a further embodiment of the first aspect of the present invention, doubly correcting the timing time according to the second time length and the first time length includes:
after the timing key sets the timing, the timing time is continuously and actively sent to the main control equipment by using the mode of correcting the timing time according to the second time length and taking the preset deviation value delta as a minimum time interval unit, and meanwhile, if the other keys are detected to be pressed, the timing time is determined by using the mode of correcting the timing time according to the first time length.
In another aspect of the present invention, a timing remote control with time correction is provided, which includes one or more processors and a non-transitory computer readable storage medium storing program instructions, which when executed by the one or more processors, are configured to implement the method of any one of the above.
In yet another aspect, the present invention provides a non-transitory computer-readable storage medium having stored thereon program instructions that, when executed by one or more processors, are configured to implement the method of any of the above embodiments.
In still another aspect, the present invention provides an air conditioning system based on a time correction timing remote control method, which includes an air conditioner and a remote controller as described in the foregoing embodiments.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The terminology used in the embodiments of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in this application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise, the "plurality" generally includes at least two, but does not exclude the case of at least one.
It should be understood that the term "and/or" as used herein is merely an association relationship describing the associated object, and means that there may be three relationships, e.g., a and/or B, and that there may be three cases where a exists alone, while a and B exist together, and B exists alone. In addition, the character "/" herein generally indicates that the front and rear associated objects are an "or" relationship.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a product or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such product or system. Without further limitation, an element defined by the phrase "comprising one of the elements" does not exclude the presence of additional identical elements in a commodity or system comprising the element.
Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings. In the drawings, detailed descriptions of related known functions or configurations are omitted so as not to unnecessarily obscure the technical gist of the present invention. In addition, throughout the description, the same reference numerals denote the same circuits, modules or units, and repetitive descriptions of the same circuits, modules or units are omitted for brevity.
Furthermore, it should be understood that one or more of the following methods or aspects thereof may be performed by at least one control system, control unit, or controller. The terms "control unit", "controller", "control module" or "main control module" may refer to hardware devices including a memory and a processor, and the term "air conditioner" may refer to devices similar to refrigeration devices. The memory or computer-readable storage medium is configured to store program instructions, and the processor is specifically configured to execute the program instructions to perform one or more processes that will be described further below. Moreover, it should be appreciated that the following methods may be performed by including a processor in combination with one or more other components, as will be appreciated by those of ordinary skill in the art.
In order to further illustrate the technical solution of the present invention, the following specific embodiments are provided with reference to fig. 1 and 2.
Example 1
The embodiment of the invention provides a timing remote control method based on time correction, as shown in fig. 1, the timing remote control method based on time correction in the embodiment of the invention at least comprises the following steps S1 and S2.
S1, after the timing key sets the timing time, when other keys are pressed, the timing time is calibrated by at least one time correction mode.
S2, the calibrated timing time is issued to the master control equipment.
Wherein:
s1, after the timing key sets the timing time, when other keys are pressed, the timing time is calibrated by at least one time correction mode.
As shown in fig. 2, assuming that the timing key sets the timing time to be S hours to T1, the time when the other key is pressed to T2, the timing is started with T1 as the start time point, the time length from the time of T1 is denoted by Y, and if the current time is any time Tn after the start of the timing at the time of T1, the time length of the first time y=tn-T1, the time length at the time of T2 is denoted by X with the time of T1 as the time start point, that is, x=t2-T1. The units of X and Y are minutes. And X, Y two different timing durations are utilized to respectively correspond to the two different time correction modes S11 and S12, and meanwhile, the time correction mode based on the double correction timing time of the X duration and the Y duration is also included. Since the preset deviation value delta is used for the decreasing offset of the timing time, the accuracy of the time correction can be characterized, it is preferable that delta is the timing accuracy. Preferably, delta=0.5 hours.
S11, correcting the timing time according to the second duration X.
S12, correcting the timing time according to the first time length Y.
S13, double correcting the timing time according to the second time length X and the first time length Y.
Wherein:
S11, correcting the timing time according to the second duration X.
When correcting the timing time by using the second duration X, two different time correction strategies can be classified as follows S111 and S112 according to the on-off state of the master device.
S111, correcting timing time when the main control equipment is in a starting state. If the second duration X is within the first preset range, preferably the first preset range is 0 to 15 minutes, the timing time is maintained for the initially set timing time S hours.
If the second duration X is within the second preset range, preferably the second preset range is 15 minutes, 1 second to 45 minutes, then the current timing time is updated to S-delta.
If the second duration X is within the third preset range, preferably, the third preset range is 45 minutes, 1 second to 60 minutes, then the current timing time is the last updated timing time minus the preset deviation delta, i.e. the current timing time is S-2X delta.
And (3) performing round robin timing until the last 15 minutes of the timing startup, if other keys except the timing key are pressed, executing the timing startup instruction, and resetting the current timing time.
S112, correcting the timing time when the main control equipment is in the shutdown state.
If the second duration X is within the first preset range, preferably the first preset range is 0 to 15 minutes, the timing time remains the original timing time, i.e., the timing time S originally set.
If the second duration X is within the second preset range, preferably the second preset range is 15 minutes, 1 second to 45 minutes, then the current timing time is updated to S-delta.
If the second duration X is within the third preset range, preferably, the third preset range is 45 minutes, 1 second to 75 minutes, then the current timing time is the last updated timing time minus delta, i.e., the current timing time is S-2X delta.
When the round-robin is performed, the current timing time may be represented as S-n times delta, where n is the number of n times delta that starts to count after the time length exceeds the upper limit value of the first preset range. Can be expressed as n= (X-R1 top)// (delta 60) +1, where// is the rounding down operation in the computer, R1 top is the upper value of the first preset range, and the dimension is minutes. The timing time is gradually reduced until the timing time is within the last remaining time threshold of the timing shutdown, preferably, the last remaining time threshold is 15 minutes, if other keys except the on/off key are pressed, the relevant flag bit is cleared, and information is transmitted according to the set state. After the timing time is cancelled or the time is decremented to zero, the timing is set again, and the time value is the last set timing time value, not the decremented timing time value.
S12, correcting the timing time according to the first time length Y.
The timing correction method of S11 is used to calibrate the timing, and although the accuracy of the timing is improved to some extent, there is a problem in that if the estimation is always biased in one direction, the timing estimated last is far from the timing setting time.
For example, when the main control device is an air conditioner, the cycle timing is set, the air conditioner is started at eight points in the morning every day, if the timing of the first air conditioner is started 15 minutes earlier, the subsequent time of the first air conditioner is taken as a time reference every day, the deviation is continuously accumulated for 15 minutes, and the deviation is 120 minutes for 8 days. This results in the air conditioner being turned on 2 hours in advance, i.e. 6 a.m. on day 9, which results far from the user's will, and in order to solve this problem, a second absolute time correction is required according to the first duration Y.
After the timing key sets the timing time, the first time length Y starts to be increased, when Y is equal to n times of a preset deviation delta of 60 minutes, Y is cleared, then Y is continuously accumulated, and in the process of accumulating to clear, the timing time S is updated to be S-delta, namely the current timing time is the original timing time minus n times delta, wherein n is a natural number, and the original timing time is the timing time set by the timing key. And then issuing the master control device. That is, after the timing is set, the timing time is automatically sent back to the main control equipment after the delta is exceeded, so that the timing time is absolutely corrected, and the continuous accumulation of periodic timing time errors is avoided.
Because the remote control is simpler than the main control equipment in terms of the executed logic functions, the interrupt and other calls are less, the overall timing time is more accurate, the remote control timing precision is delta, the timing time calculation can be carried out in the remote control after the remote control is used for setting the timing, and the remote control automatically sends the residual timing time to the main control equipment for absolute correction every interval delta, so that even if the previous timing has deviation, the deviation cannot be accumulated after the absolute correction of the delta, and the accuracy of the final timing can be ensured.
S13, double correcting the timing time according to the second time length X and the first time length Y.
After the remote controller is set to time, the timing time is corrected according to the first time length Y as described in S12, the timing time is continuously and actively sent to the master control device with the remote control timing precision as the minimum time interval unit, and meanwhile, if other keys except the timing key are pressed, the timing time is determined by correcting the timing time according to the second time length X as described in S11.
By combining the two correction modes of S11, S12 and S13, the timing precision is effectively improved, the code sending times of a remote controller are reduced, and the power consumption is reduced on the premise of not increasing the cost.
S2, the calibrated timing time is issued to the master control equipment.
Through the calibration of S1 to the timing time, the accuracy of the timing time is improved, and after the main control equipment is operated by the remote control key, a corresponding control instruction and the calibrated timing time are sent to the main control equipment, so that the accuracy of timing is ensured, and the normal operation of the functions of the main control equipment is ensured.
In this embodiment, the evaluation of the timing time is formulated according to the timing accuracy delta of the remote control, and if the timing accuracy delta is changed, the evaluation and calculation modes are adjusted accordingly.
The key in this embodiment is pressed with the transmitted information.
Example two
The embodiment of the invention provides an air conditioning system based on a time correction timing remote control method, which comprises an air conditioner and a remote controller as shown in fig. 3.
The remote controller is in wireless connection with the air conditioner, the remote controller sends a control instruction to the air conditioner through a key, and the air conditioner immediately executes after receiving the control instruction.
The remote controller can set the timing on or off of the air conditioner through the timing key, records the set timing moment of the remote controller as T1, presses the other keys of the remote controller again as T2, starts timing after the set timing moment T1, records the timing duration of the T2 as a second duration, and indicates X minutes, namely X=T2-T1. Recording the timing duration from the moment T1 as a first duration, representing the first duration as Y minutes, if the timing duration is any moment Tn after the moment T1 begins to be timed, the first duration Y=Tn-T1, and calibrating the timing time of the remote controller is finished through time correction based on the X duration and the Y duration respectively, or can be finished through double correction of the timing time based on the X duration and the Y duration at the same time, wherein the three modes are represented as S1, S2 and S3.
S1, correcting timing time based on the X duration.
S2, correcting the timing time based on the Y duration.
S3, correcting the timing time based on the X duration and the Y duration.
Wherein,
S1, correcting timing time based on the X duration.
When other keys of the remote controller except the timing key are operated again, judging the X, specifically, the following two timing correction modes under the state of the air conditioner are adopted:
s11, when the air conditioner is in a starting state, the timing time correcting mode is as follows:
if X is within the first preset range, preferably, the first preset range is 0to 15 minutes, and the timing time is kept for the original timing time;
If X is within the second preset range, preferably, the second preset range is 15 minutes, 1 second to 45 minutes, and the timing time is the original timing time minus 0.5 hour;
If X is within the third preset range, preferably, the third preset range is 45 minutes, 1 second to 60 minutes, and the current timing time is obtained by subtracting 0.5 hour from the last step of timing time;
And (3) after the round robin is performed until the X is within the last remaining time threshold value of the air conditioner when the air conditioner is started at regular time, preferably, the last remaining time threshold value is 15 minutes, if the remote controller presses other keys except the timing key and has transmitting information, the air conditioner immediately responds to the command of the remote controller, and the air conditioner is started according to the time determined by the timing time, namely, the air conditioner is started within 15 minutes at the latest.
S12, when the air conditioner is in a shutdown state, correcting the timing time as follows:
if X is within the first preset range, preferably, the first preset range is 0to 15 minutes, and the timing time is kept for the original timing time;
If X is within the second preset range, preferably, the second preset range is 15 minutes, 1 second to 45 minutes, and the timing time is the original timing time minus 0.5 hour;
if X is within the third preset range, preferably, the third preset range is 45 minutes, 1 second to 75 minutes, and the current timing time is obtained by subtracting 0.5 hour from the last step of timing time;
And (3) after the round robin is performed until the timing time is within the last remaining time threshold of the air conditioner for timing shutdown, preferably, the last remaining time threshold is 15 minutes, if other keys except the on/off key are pressed, the relevant flag bit is cleared, and the information is transmitted according to the state set by the currently pressed key. If the timing is canceled or the timing time is decremented to zero, the timing is again set, and the timing time value at this time is the last set timing time value, instead of the decremented timing time value.
The air conditioner corrects the timing time by correcting the time using the timing time X as described above, but there is a problem in that if the estimated value is always biased in one direction, the timing time estimated last is far from the timing set time. For example, if the cycle timing is set and the air conditioner is started at eight times a day in the morning, if the first air conditioner timing is started 15 minutes earlier, the following day will take the first timing as the time reference, the deviation will continue to accumulate for 15 minutes, and the deviation will be 120 minutes for 8 days. This results in the air conditioner being turned on 2 hours in advance, i.e. 6 a.m. on day 9, which is far from the user's wish, and in order to solve this problem, a correction of the second absolute time according to the time duration Y is required.
S2, correcting the timing time based on the Y duration.
Because the remote controller is simpler for the logical function of air conditioner, interrupt etc. is called comparatively less, and whole timing time is more accurate, and the remote controller timing accuracy is 0.5 hour, uses the remote controller to set for the back, can carry out timing time calculation in the remote controller, every interval 0.5 hour, then the remote controller is automatic to send remaining timing time to master control equipment, carries out absolute correction, even have the deviation in the timing before like this, through 0.5 hour's absolute correction, the deviation just can not accumulate, alright guarantee the accuracy of final timing to can guarantee that the timing time that the remote controller sent to the air conditioner is accurate.
S3, correcting the timing time based on the X duration and the Y duration.
And (2) after the timing is set by the remote controller, the remote controller continuously and actively transmits the remaining timing time to the air conditioner by taking the timing precision as a minimum time interval unit, and meanwhile, if other keys except the timing key are pressed, the remaining timing time transmitted to the air conditioner at the moment can be determined by the mode based on the X-time correction timing time in the step (S1).
In summary, it is readily understood by those skilled in the art that the above-described advantageous ways can be freely combined and superimposed without conflict. The above description is only an example of the present invention and is not intended to limit the present invention, but various modifications and variations can be made to the present invention by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.