WO2022121409A1 - 空调通信的控制方法、装置、通信系统和可读存储介质 - Google Patents

空调通信的控制方法、装置、通信系统和可读存储介质 Download PDF

Info

Publication number
WO2022121409A1
WO2022121409A1 PCT/CN2021/117574 CN2021117574W WO2022121409A1 WO 2022121409 A1 WO2022121409 A1 WO 2022121409A1 CN 2021117574 W CN2021117574 W CN 2021117574W WO 2022121409 A1 WO2022121409 A1 WO 2022121409A1
Authority
WO
WIPO (PCT)
Prior art keywords
voltage
bus
slope
duration
time
Prior art date
Application number
PCT/CN2021/117574
Other languages
English (en)
French (fr)
Inventor
孙良伟
梅利军
吴田
彭梦强
Original Assignee
广东美的暖通设备有限公司
美的集团股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 广东美的暖通设备有限公司, 美的集团股份有限公司 filed Critical 广东美的暖通设备有限公司
Priority to EP21902117.7A priority Critical patent/EP4134831A4/en
Priority to US17/922,971 priority patent/US20230160600A1/en
Publication of WO2022121409A1 publication Critical patent/WO2022121409A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling
    • G06F13/4068Electrical coupling
    • G06F13/4072Drivers or receivers
    • FMECHANICAL ENGINEERING; LIGHTING; HEATING; WEAPONS; BLASTING
    • F24HEATING; RANGES; VENTILATING
    • F24FAIR-CONDITIONING; AIR-HUMIDIFICATION; VENTILATION; USE OF AIR CURRENTS FOR SCREENING
    • F24F11/00Control or safety arrangements
    • F24F11/88Electrical aspects, e.g. circuits
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling
    • G06F13/4068Electrical coupling
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03KPULSE TECHNIQUE
    • H03K5/00Manipulating of pulses not covered by one of the other main groups of this subclass
    • H03K5/153Arrangements in which a pulse is delivered at the instant when a predetermined characteristic of an input signal is present or at a fixed time interval after this instant
    • H03K5/1534Transition or edge detectors
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/10Current supply arrangements
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02BCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO BUILDINGS, e.g. HOUSING, HOUSE APPLIANCES OR RELATED END-USER APPLICATIONS
    • Y02B30/00Energy efficient heating, ventilation or air conditioning [HVAC]
    • Y02B30/70Efficient control or regulation technologies, e.g. for control of refrigerant flow, motor or heating

Definitions

  • the present application relates to the technical field of communication control, and in particular, to a control method, device, communication system and readable storage medium for air conditioning communication.
  • the sampling method of the MCU in the air conditioner and other communication systems is generally to multiply the frequency of the crystal oscillator, and after sampling a certain number of times, read the sampled data, such as identifying the high and low levels of the communication signal, and the MCU in the air conditioner and other communication systems.
  • a detection threshold will be set, and when the above distortion occurs, the data read by the MCU will be wrong.
  • the detection threshold is -200mV to 200mV.
  • the voltage value on the bus is greater than 200mV, it is considered that "1” is recognized from the bus.
  • the voltage value on the bus is less than -200mV, it is considered to be recognized from the bus.
  • "0" when the above distortion occurs, as shown in Figure 10, under normal circumstances, the voltage value of the bus differential signal is 0V, and the output signal of the communication interface chip is "1". When the bus signal is disturbed and fluctuates, the communication interface The chip will output the wrong signal "0".
  • the present application aims to solve at least one of the technical problems existing in the prior art or related technologies.
  • a first aspect of the present application is to provide a control method for air-conditioning communication.
  • a second aspect of the present application is to provide a control device for air-conditioning communication.
  • a third aspect of the present application is to provide a communication system.
  • a fourth aspect of the present application is to provide a readable storage medium.
  • the present application provides a control method for air conditioner communication, wherein the air conditioner is connected to a bus, and the control method for air conditioner communication includes: acquiring a voltage signal of the bus; The comparison condition of the power supply voltage and the reference voltage on the bus is to determine the voltage rising edge slope and the voltage falling edge slope in the voltage signal; By comparison, the processed voltage signal is obtained; the target data model in the data model library that is consistent with the processed voltage signal is determined; and the data information corresponding to the target data model is output.
  • the voltage rising edge slope and the voltage falling edge slope are compared to realize the screening of the voltage data, and the collected data is realized by time comparison.
  • Data signal restoration In this process, the voltage signal on the bus is identified by model comparison, which reduces the detection caused by the interference of inductance, capacitance, resistance and signal reflection in air conditioners and other communication systems. The obtained signal data is abnormal.
  • control method for air-conditioning communication in the above-mentioned technical solutions provided by the present application may also have the following additional technical features:
  • any sampled voltage value in the voltage signal is less than or equal to the power supply voltage of the air conditioner, and the difference from the reference voltage is greater than a preset threshold, it is determined that the voltage signal satisfies the power supply voltage of the air conditioner and the reference on the bus Voltage comparison conditions.
  • the air conditioner is connected to the bus through a communication chip to obtain the signal on the bus, and when the chip is in use, the voltage signal collected by the chip is located in the interval that is smaller than its power supply voltage.
  • the voltage value corresponding to the voltage signal on the device is too high, such as exceeding its power supply voltage, so that the air conditioner cannot collect and restore it. supply voltage, so that the voltage signal on the bus can be corrected accurately, reducing the probability of outputting wrong signals.
  • the technical solution of the present application specifically limits the difference between any sampling voltage value and the reference voltage to be large enough, such as greater than a preset threshold, to ensure that the sampling voltage value is large enough, thereby ensuring that the restored precision.
  • the preset threshold value can be set according to actual needs. For example, when the power supply voltage of the communication chip is 3.3V, the value of the preset threshold value can be 0.5V. At this time, the reference voltage cannot be more than 2.5 volts.
  • the determination process of whether the voltage rising edge slope and the voltage falling edge slope satisfy the slope comparison condition is specifically defined, and specifically, the first amplitude corresponding to the voltage rising edge slope and the voltage falling edge slope are determined.
  • the corresponding second amplitude based on the ratio between the first amplitude and the second amplitude being greater than 0.5 and less than 2, it is determined that the voltage rising edge slope and the voltage falling edge slope satisfy the slope comparison condition.
  • the technical solution of the present application determines whether there is a large difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage by comparing the magnitude relationship between the amplitudes of the slopes , specifically, when the difference between the first amplitude value and the second amplitude value is not more than half, it is considered that the difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage is small, that is, the slope comparison condition is satisfied, Considering that the first amplitude value may be larger than the second amplitude value, or may be smaller than the second amplitude value, if the comparison cases are divided separately, more data needs to be processed.
  • the technical solution of the present application quantifies the judgment that the difference between the first amplitude value and the second amplitude value is not more than half by determining the fluctuation range of the ratio between the first amplitude value and the second amplitude value Condition, specifically, the ratio needs to be greater than 0.5 and less than 2.
  • the ratio needs to be greater than 0.5 and less than 2.
  • the step of determining the voltage rising edge slope and the voltage falling edge slope in the voltage signal specifically includes: based on the sampling voltage value of the bus being greater than the reference voltage, recording the sampling voltage value as the first voltage value; The duration of the sampled voltage value greater than the reference voltage is greater than or equal to the first preset duration, and the recorded sampled voltage value is the second voltage value; the ratio of the second voltage value to the first voltage value is used as the voltage rising edge slope; The sampled voltage value is the maximum voltage value as the start time, and the sampled voltage value recorded after the first preset duration is the third voltage value; the ratio of the maximum voltage value to the third voltage value is used as the voltage falling edge slope.
  • the air conditioner collects data on the bus periodically. If the voltage value is collected and the voltage difference value is determined, the ratio of the time corresponding to the voltage difference value and the voltage difference value will be calculated to obtain the corresponding slope. , considering that the technical solution of the present application is to determine whether the slope comparison condition is satisfied by comparing the ratio between the first amplitude value and the second amplitude value, in the case where the time corresponding to the voltage difference is the same, the The ratio of the second voltage value to the first voltage value is regarded as the slope of the rising edge of the voltage. Similarly, the ratio of the maximum voltage value to the third voltage value is regarded as the slope of the falling edge of the voltage, so as to reduce the amount of data that the air conditioner needs to process. .
  • the step of comparing the voltage signals with time to obtain the processed voltage signals specifically includes: determining the start time when the sampling voltage value of the bus is greater than the reference voltage as the start time, and the second preset time length Determine the first time after the bus sampling voltage value is the time corresponding to the maximum voltage value as the second time after the second preset time at the start time; Determine the first time according to the first time and the second time; According to the first time
  • the duration corresponding to the first number in the binary data determines the number of the first numbers represented by the first duration; it is determined that the time corresponding to the sampling voltage value of the bus is greater than the reference voltage as the starting time, and the second preset
  • the third moment after the duration; the second duration is determined according to the third moment and the second moment; the number of the second numbers represented by the second duration is determined according to the duration corresponding to the second duration and the second number in the binary data;
  • the processed voltage signal is determined according to the number of the first number, the number of the second number, the first number and the second number.
  • the way to determine the voltage signal on the bus is to determine the number of the first number and the second number in the binary data according to the duration of the high level or the duration of the low level on the bus.
  • the voltage collected by the air conditioner fluctuates greatly, and the accuracy is low.
  • the technical solution of the present application adopts the method of time comparison to determine the number of the first number and the second number in the binary data, and according to the number of the first number and the number of the second number Data restoration is performed on the voltage signal by digital pair. In this process, the influence of the above situation on the read signal is reduced, and the reliability of the signal is ensured.
  • the first duration corresponds to M consecutive first numbers
  • the second duration corresponds to N consecutive second numbers, where M and N are natural numbers.
  • the first The fluctuation interval between the duration and the duration corresponding to the M first numbers specifically, by calculating the difference between the first duration and the duration corresponding to the M first numbers, and comparing the difference with the set value , in order to judge whether the fluctuation range exceeds the set value. If it does not exceed the set value, it is determined that the first duration corresponds to M consecutive first numbers, wherein it can be understood that the voltage signal between the first moment and the second moment corresponds to M consecutive first numbers. Digital, in the same way, the voltage signal between the second time and the third time corresponds to N consecutive second digital numbers. In the above process, the restoration of the collected voltage signal is realized, so as to obtain the processed voltage signal. .
  • control method for air-conditioning communication further comprises: acquiring the baud rate of the air-conditioning and the actual communication time on the bus; determining the duration corresponding to the first number and the second Digital corresponding duration.
  • the duration corresponding to the first number and the duration corresponding to the second number will also be different.
  • the duration corresponding to the number and the duration corresponding to the second number are calibrated, and the duration corresponding to the first number and the duration corresponding to the second number are determined according to the baud rate of the air conditioner and the actual communication time on the bus.
  • the actual communication time is the difference between the theoretical communication time on the bus and the first waiting time and the second waiting time, wherein the theoretical communication time can be understood as the voltage value on the bus is greater than or equal to the reference
  • the duration of the voltage is the time when the voltage value on the bus is greater than the reference voltage, and the sampling voltage value on the bus is obtained after the first waiting time.
  • the second waiting time is the time when no sampling is performed. , which corresponds to the tail of the theoretical communication time.
  • the first waiting time and the second waiting time belong to the time during which the voltage signal on the bus is not sampled, and the specific values thereof can be preset.
  • a control device for air conditioner communication wherein the air conditioner is connected to a bus, and the control device for air conditioner communication includes: an acquisition unit for acquiring a voltage signal of the bus; a determination unit for using Determine the voltage rising edge slope and the voltage falling edge slope in the voltage signal based on the comparison condition of the supply voltage of the air conditioner and the reference voltage on the bus based on the voltage signal; satisfy the slope comparison condition based on the voltage rising edge slope and the voltage falling edge slope , perform time comparison on the voltage signal to obtain the processed voltage signal; determine the target data model in the data model library that is consistent with the processed voltage signal; the output unit is used to output the data information corresponding to the target data model.
  • the technical solution of the present application provides a control device for air-conditioning communication, which specifically includes an acquisition unit, a determination unit, and an output unit.
  • the data model corresponding to the voltage signal in the bus is obtained by detecting the voltage signal in the bus, and the data model is compared with the model in the stored data model library, and if the comparison is consistent , and output the data information in the consistent data model (that is, the data information in the target data model in this application).
  • the voltage rising edge slope and the voltage falling edge slope are compared to realize the screening of the voltage data, and the collected data is realized by time comparison.
  • Data signal restoration In this process, the voltage signal on the bus is identified by model comparison, which reduces the detection caused by the interference of inductance, capacitance, resistance and signal reflection in air conditioners and other communication systems. The obtained signal data is abnormal.
  • control device for air-conditioning communication in the above-mentioned technical solutions provided by the present application may also have the following additional technical features:
  • the determining unit is specifically configured to: determine that the voltage signal satisfies the power supply of the air conditioner based on any sampled voltage value in the voltage signal that is less than or equal to the power supply voltage of the air conditioner, and the difference from the reference voltage is greater than a preset threshold The comparison condition of the voltage and the reference voltage on the bus.
  • the air conditioner is connected to the bus through a communication chip to obtain the signal on the bus, and when the chip is in use, the voltage signal collected by the chip is located in the interval that is smaller than its power supply voltage.
  • the voltage value corresponding to the voltage signal on the device is too high, such as exceeding its power supply voltage, so that the air-conditioning communication cannot collect and restore it. It is equal to the power supply voltage, so that the voltage signal on the bus can be corrected accurately and the probability of outputting the wrong signal can be reduced.
  • the technical solution of the present application specifically limits the difference between any sampling voltage value and the reference voltage to be large enough, such as greater than a preset threshold, to ensure that the sampling voltage value is large enough, thereby ensuring that the restored precision.
  • the preset threshold value can be set according to actual needs. For example, when the power supply voltage of the communication chip is 3.3V, the value of the preset threshold value can be 0.5V. At this time, the reference voltage cannot be more than 2.5 volts.
  • the determining unit is specifically configured to: determine the first amplitude value corresponding to the voltage rising edge slope and the second amplitude value corresponding to the voltage falling edge slope; based on the difference between the first amplitude value and the second amplitude value If the ratio is greater than 0.5 and less than 2, it is determined that the slope of the rising edge of the voltage and the slope of the falling edge of the voltage satisfy the slope comparison condition.
  • the technical solution of the present application determines whether there is a large difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage by comparing the magnitude relationship between the amplitudes of the slopes , specifically, when the difference between the first amplitude value and the second amplitude value is not more than half, it is considered that the difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage is small, that is, the slope comparison condition is satisfied, Considering that the first amplitude value may be larger than the second amplitude value, or may be smaller than the second amplitude value, if the comparison cases are divided separately, more data needs to be processed.
  • the technical solution of the present application quantifies the judgment that the difference between the first amplitude value and the second amplitude value is not more than half by determining the fluctuation range of the ratio between the first amplitude value and the second amplitude value Condition, specifically, the ratio needs to be greater than 0.5 and less than 2.
  • the ratio needs to be greater than 0.5 and less than 2.
  • the determining unit is specifically configured to: the sampling voltage value based on the bus is greater than the reference voltage, and the recorded sampling voltage value is the first voltage value; the duration for which the sampling voltage value based on the bus is greater than the reference voltage is greater than or equal to the first voltage value
  • the determining unit is specifically configured to: the sampling voltage value based on the bus is greater than the reference voltage, and the recorded sampling voltage value is the first voltage value; the duration for which the sampling voltage value based on the bus is greater than the reference voltage is greater than or equal to the first voltage value
  • For a preset duration record the sampling voltage value as the second voltage value; use the ratio of the second voltage value to the first voltage value as the slope of the rising edge of the voltage; find the sampling voltage value of the bus as the maximum voltage value as the starting time, the first
  • the sampled voltage value recorded after the preset time period is the third voltage value; the ratio of the maximum voltage value to the third voltage value is used as the voltage falling edge slope.
  • the air conditioner collects data on the bus periodically. If the voltage value is collected and the voltage difference value is determined, the ratio of the time corresponding to the voltage difference value and the voltage difference value will be calculated to obtain the corresponding slope. , considering that the technical solution of the present application is to determine whether the slope comparison condition is satisfied by comparing the ratio between the first amplitude value and the second amplitude value, in the case where the time corresponding to the voltage difference is the same, the The ratio of the second voltage value to the first voltage value is regarded as the slope of the rising edge of the voltage. Similarly, the ratio of the maximum voltage value to the third voltage value is regarded as the slope of the falling edge of the voltage, so as to reduce the amount of data that the air conditioner needs to process. .
  • the determining unit is specifically configured to: determine the time when the sampled voltage value of the bus is greater than the reference voltage as the start time, the first time after the second preset duration; determine the sampled voltage value of the bus as the start time The time corresponding to the maximum voltage value is taken as the second time after the second preset time length at the start time; the first time length is determined according to the first time and the second time; according to the time length corresponding to the first time length and the first number in the binary data Determine the number of the first numbers represented by the first duration; determine the start moment when the sampling voltage value of the bus is greater than the reference voltage again, and the third moment after the second preset duration; The second time length is determined at the second time; the number of the second digits represented by the second time length is determined according to the time length corresponding to the second time length and the second number in the binary data; according to the number of the first number, the second number The number of , the first number and the second number determine the processed voltage signal.
  • the way to determine the voltage signal on the bus is to determine the number of the first number and the second number in the binary data according to the duration of the high level or the duration of the low level on the bus.
  • the voltage collected by the air conditioner fluctuates greatly, and the accuracy is low.
  • the technical solution of the present application adopts the method of time comparison to determine the number of the first number and the second number in the binary data, and according to the number of the first number and the number of the second number Data restoration is performed on the voltage signal by digital pair. In this process, the influence of the above situation on the read signal is reduced, and the reliability of the signal is ensured.
  • the determining unit is specifically configured to: based on the difference between the first duration and the durations corresponding to the M first numbers being less than or equal to the set value, determine that the first duration corresponds to M consecutive first numbers Numbers; based on the difference between the second duration and the durations corresponding to the N second numbers being less than or equal to the set value, determine that the second duration corresponds to N consecutive second numbers, where M, N are natural numbers.
  • the first The fluctuation interval between the duration and the duration corresponding to the M first numbers specifically, by calculating the difference between the first duration and the duration corresponding to the M first numbers, and comparing the difference with the set value , in order to judge whether the fluctuation range exceeds the set value. If it does not exceed the set value, it is determined that the first duration corresponds to M consecutive first numbers, wherein it can be understood that the voltage signal between the first moment and the second moment corresponds to M consecutive first numbers. Digital, in the same way, the voltage signal between the second time and the third time corresponds to N consecutive second digital numbers. In the above process, the restoration of the collected voltage signal is realized, so as to obtain the processed voltage signal. .
  • the determining unit is also used to: obtain the baud rate of the air conditioner and the actual communication time on the bus; determine the duration corresponding to the first number and the corresponding time of the second number according to the baud rate and the actual communication time length of time.
  • the duration corresponding to the first number and the duration corresponding to the second number will also be different.
  • the duration corresponding to the number and the duration corresponding to the second number are calibrated, and the duration corresponding to the first number and the duration corresponding to the second number are determined according to the baud rate of the air conditioner and the actual communication time on the bus.
  • the actual communication time is the difference between the theoretical communication time on the bus and the first waiting time and the second waiting time, wherein the theoretical communication time can be understood as the voltage value on the bus is greater than or equal to the reference
  • the duration of the voltage is the time when the voltage value on the bus is greater than the reference voltage, and the sampling voltage value on the bus is obtained after the first waiting time.
  • the second waiting time is the time when no sampling is performed. , which corresponds to the tail of the theoretical communication time.
  • the first waiting time and the second waiting time belong to the time during which the voltage signal on the bus is not sampled, and the specific values thereof can be preset.
  • a communication system which includes a processor, a memory, and a program or instruction stored in the memory and executable on the processor.
  • the program or instruction is executed by the processor, the The steps of the control method for air conditioning communication according to any one of the aspects.
  • the technical solution of the present application provides a communication system, wherein the communication system includes a memory and a processor, wherein the processor executes a program or an instruction stored in the memory to implement the control method for air-conditioning communication according to any one of the first aspect Therefore, the communication system has all the beneficial technical effects of any one of the above-mentioned control methods for air-conditioning communication.
  • a readable storage medium wherein a program or an instruction is stored on the readable storage medium, and when the program or instruction is executed by a processor, the communication of the air conditioner according to any one of the first aspect is realized. The steps of the control method.
  • the technical solution of the present application provides a readable storage medium, wherein, when the program or instruction stored on the readable storage medium is executed, the steps of the control method for air-conditioning communication in any one of the first aspect are implemented, so it is readable and readable.
  • the storage medium has all the beneficial technical effects of any one of the above-mentioned control methods for air-conditioning communication.
  • FIG. 1 shows a schematic flowchart of a control method for air-conditioning communication in an embodiment of the present application
  • FIG. 2 shows a schematic flowchart of judging whether the voltage rising edge slope and the voltage falling edge slope meet the slope comparison condition in an embodiment of the present application
  • FIG. 3 shows a schematic flowchart of determining a voltage rising edge slope and a voltage falling edge slope in an embodiment of the present application
  • FIG. 4 shows a schematic flowchart of performing time comparison on voltage signals and obtaining processed voltage signals in an embodiment of the present application
  • FIG. 5 shows a schematic block diagram of a control device for air-conditioning communication in an embodiment of the present application
  • FIG. 6 shows a schematic block diagram of a communication system in an embodiment of the present application
  • FIG. 7 shows a schematic diagram of a voltage signal in an embodiment of the present application.
  • FIG. 8 shows a schematic diagram of a voltage signal in an embodiment of the present application.
  • FIG. 9 shows a schematic diagram of a voltage signal in an embodiment of the present application.
  • Fig. 10 shows the waveform diagram of the distortion of the signal collected by the air conditioner in the related technical solution
  • FIG. 11 shows a waveform diagram of the distortion of the signal collected by the air conditioner in the related art solution.
  • the present application provides a control method for air conditioner communication, wherein the air conditioner is connected to a bus, and the control method for air conditioner communication includes:
  • Step 102 obtaining the voltage signal on the bus
  • Step 104 in the case that the voltage signal meets the comparison condition between the power supply voltage of the air conditioner and the reference voltage on the bus, determine the voltage rising edge slope and the voltage falling edge slope in the voltage signal;
  • Step 106 when the voltage rising edge slope and the voltage falling edge slope meet the slope comparison conditions, compare the voltage signals with time, and obtain the processed voltage signals;
  • Step 108 determining a target data model in the data model library that is consistent with the processed voltage signal
  • Step 110 Output data information corresponding to the target data model.
  • the voltage signal on the bus may be a plurality of discrete samples that are consecutive in time.
  • the data model corresponding to the voltage signal in the bus is obtained by detecting the voltage signal in the bus, and the data model is compared with the model in the stored data model library. If the comparison is consistent, the data information in the data model that is consistent with the comparison (that is, the data information in the target data model in this application) is output.
  • the voltage rising edge slope and the voltage falling edge slope are compared to realize the screening of the voltage data, and the collected data is realized by time comparison.
  • Data signal restoration In this process, the voltage signal on the bus is identified by model comparison, which reduces the detection caused by the interference of inductance, capacitance, resistance and signal reflection in air conditioners and other communication systems. The obtained signal data is abnormal.
  • the data model repository stores data models.
  • a frame of data in a communication protocol includes dozens to dozens of bytes, of which each byte has 10 bits of data.
  • a byte includes a start bit “0" and a stop bit “1” and the 8-bit data between the start bit “0” and the stop bit “1”, and these 8-bit data are used to transmit data.
  • the data model in the data model library is based on 10-bit data.
  • each bit of data can be "1" or "0"
  • 2 8 256 data models need to be constructed and saved, for example, "1111111100” is a communication
  • the data model is represented as a byte “FE” in hexadecimal, where the first "0" is the start bit, and the last "1" is the termination bit.
  • "1101010100" in hexadecimal is represented as a Byte "aa”.
  • the 8-bit data can be divided into 4+4 parts, that is, the first 4 bits of data are saved as a model.
  • the last 4 bits of data are stored as one data.
  • the last 4 bits also need 16 models to represent.
  • the content of judging whether the voltage signal satisfies the comparison condition between the power supply voltage of the air conditioner and the reference voltage on the bus is specifically limited.
  • the air conditioner is connected to the bus through a communication chip to obtain the signal on the bus.
  • the sampling voltage value collected by the chip will be less than its power supply voltage.
  • the voltage value corresponding to the signal is too high, such as exceeding its power supply voltage, so that the air conditioner cannot collect and restore it.
  • Exceed the supply voltage so that the voltage signal on the bus can be accurately corrected, reducing the probability of outputting an erroneous signal.
  • the embodiment of the present application needs to further determine whether the slope of the rising edge of the voltage and the slope of the falling edge of the voltage satisfy the slope comparison condition, if the voltage value corresponding to the collected voltage signal is too low, it will have an impact on the accuracy of restoration , and even worse, rendering the signal uncorrectable.
  • the embodiments of the present application specifically limit the difference between any sampled voltage value and the reference voltage to be large enough, such as greater than a preset threshold, to ensure that the sampled voltage value is large enough, thereby ensuring that the restored precision.
  • the preset threshold can be set according to actual needs. For example, as shown in FIG. 7 , when the power supply voltage of the communication chip is 3.3 volts, the sampling voltage values U2 and U3 cannot exceed 3.3 volts , the preset threshold value may be 0.5 volts, and the reference voltage U0 cannot exceed 2.5 volts at this time.
  • an error data model is output to remind the user to handle it.
  • the content of determining whether the slope of the rising edge of the voltage and the slope of the falling edge of the voltage satisfy the slope comparison condition is specifically limited.
  • the content of judging whether the voltage rising edge slope and the voltage falling edge slope satisfy the slope comparison condition includes:
  • Step 202 take the amplitude value of the slope of the rising edge of the voltage, and record it as the first amplitude value;
  • Step 204 taking the amplitude of the slope of the voltage falling edge, and denoting it as the second amplitude
  • Step 206 calculating the ratio of the first amplitude value to the second amplitude value
  • Step 208 if the ratio is between 0.5 and 2, it is considered that the voltage rising edge slope and the voltage falling edge slope meet the slope comparison condition.
  • the embodiment of the present application determines whether there is a large difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage by comparing the magnitude relationship between the amplitudes of the slopes.
  • the difference between the first amplitude value and the second amplitude value is not more than half, it is considered that the difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage is small, that is, the slope comparison condition is satisfied, Considering that the first amplitude value may be larger than the second amplitude value, or may be smaller than the second amplitude value, if the comparison cases are divided separately, more data needs to be processed.
  • the embodiment of the present application quantifies the judgment that the difference between the first amplitude value and the second amplitude value is not more than half by determining the fluctuation range of the ratio between the first amplitude value and the second amplitude value Condition, specifically, the ratio needs to be greater than 0.5 and less than 2.
  • the ratio needs to be greater than 0.5 and less than 2.
  • a process for determining the voltage rising edge slope and the voltage falling edge slope is proposed. Specifically, as shown in FIG. 3 , it includes:
  • Step 302 when the sampling voltage value of the bus is greater than the reference voltage, record the first voltage value
  • Step 304 when the sampling voltage value of the bus is greater than the reference voltage and the duration is greater than or equal to the first preset duration, record the second voltage value;
  • Step 306 Calculate the ratio of the second voltage value to the first voltage value, and use the ratio as the slope of the rising edge of the voltage.
  • the air conditioner periodically collects data on the bus. If the voltage value is collected and the voltage difference value is determined, the ratio of the time corresponding to the voltage difference value to the voltage difference value will be calculated to The corresponding slope is obtained, considering that the embodiment of the present application determines whether the slope comparison condition is satisfied by comparing the ratio between the first amplitude value and the second amplitude value, and the time corresponding to the voltage difference is the same.
  • the ratio of the second voltage value and the first voltage value can be regarded as the slope of the rising edge of the voltage.
  • the ratio of the maximum voltage value and the third voltage value can be regarded as the slope of the falling edge of the voltage, so as to reduce the need for air conditioning.
  • the amount of data processed is processed.
  • the reference voltage is U0
  • the first voltage value U1 is recorded
  • the second voltage value U2 is recorded
  • the sampled voltage value is is the maximum voltage value U3
  • the third voltage value U4 calculates the ratio of U2 to U1, denoted as ⁇ 1
  • the reference voltage is U0
  • the first voltage value U1 is recorded, and after t/2, that is, the first preset duration t
  • the sampling voltage value is the maximum voltage value U3, at the maximum voltage
  • the third voltage Value U3 calculates the ratio of U1-2 to U1, denoted as ⁇ 1
  • the binary data is the machine language that the machine can recognize, that is, the data "1" and the data "0".
  • the first number in the binary data may be the data "1" and the data "0" in the Any one of the corresponding binary data
  • the second number is another number except the first number, such as in one case, when the first number is the data "1”, the second number is the data "0", in another case, when the first digital number is data "0", the second digital number is data "1”, in the embodiment of the present application, the selected first digital number is data "0” , the second digit is the data "1".
  • the air conditioner is connected to the bus, and data transmission is carried out by means of current transmission. For example, if other communication devices on the bus want to send data 0, they will pull a constant current M from the bus, and when data 1 is sent, they will pull a constant current N to the bus. , N can be 0, only need to connect a sampling resistor on the power supply, the current drawn by other communication devices on the bus will pass through this sampling resistor, and form a voltage on the sampling resistor, by collecting the signal of the voltage on this resistor to get other Data transmitted by communication equipment.
  • the voltage signal is compared with time to determine the number of "1" or "0" contained in the voltage signal, such as a single “1” and two “1”s.
  • FIG. 4 shows the content that specifically defines how to perform time comparison on the voltage signals and obtain the processed voltage signals. As shown in Figure 4:
  • Step 402 taking the time corresponding to the sampled voltage value greater than the reference voltage as the timing start time, and recording the first time after the second preset duration;
  • Step 404 taking the sampling voltage value of the bus as the time corresponding to the maximum voltage value as the start timing time, and recording the second time after the second preset duration;
  • Step 406 determining the first duration between the first moment and the second moment
  • Step 408 determine the number of the first number according to the duration corresponding to the first duration and the first number
  • Step 410 taking the time when the sampled voltage value of the bus is greater than the reference voltage again as the start timing time, and recording the third time after the second preset duration;
  • Step 412 determining the second duration between the third moment and the second moment
  • Step 414 determine the number of the second number according to the time length corresponding to the second duration and the second number
  • Step 416 Determine the processed voltage signal according to the number of the first number, the number of the second number, the first number and the second number.
  • the way to determine the voltage signal on the bus is to determine the number of the first number and the second number in the binary data according to the duration of the high level or the duration of the low level on the bus.
  • the voltage collected by the air conditioner fluctuates greatly, and the accuracy is low.
  • the embodiments of the present application use a time comparison method to determine the number of the first number and the second number in the binary data, and determine the number of the first number and the second number according to the number of the first number and the number of the second number.
  • Data restoration is performed on the voltage signal by digital pair. In this process, the influence of the above situation on the read signal is reduced, and the reliability of the signal is ensured.
  • the first The fluctuation interval between the duration and the duration corresponding to the M first numbers specifically, by calculating the difference between the first duration and the duration corresponding to the M first numbers, and comparing the difference with the set value , in order to judge whether the fluctuation range exceeds the set value. If it does not exceed the set value, it is determined that the first duration corresponds to M consecutive first numbers, wherein it can be understood that the voltage signal between the first moment and the second moment corresponds to M consecutive first numbers. Digital, in the same way, the voltage signal between the second time and the third time corresponds to N consecutive second digital numbers. In the above process, the restoration of the collected voltage signal is realized, so as to obtain the processed voltage signal. .
  • control method for air-conditioning communication further comprises: acquiring the baud rate of the air-conditioning and the actual communication time on the bus; and determining the duration corresponding to the first number and the second number according to the baud rate and the actual communication time The duration corresponding to each number.
  • the duration corresponding to the first number and the duration corresponding to the second number are also different.
  • the duration corresponding to the number and the duration corresponding to the second number are calibrated, and the duration corresponding to the first number and the duration corresponding to the second number are determined according to the baud rate of the air conditioner and the actual communication time on the bus.
  • the actual communication time is the difference between the theoretical communication time on the bus and the first waiting time and the second waiting time, wherein the theoretical communication time can be understood as the voltage value on the bus is greater than or equal to the reference
  • the duration of the voltage is the time when the voltage value on the bus is greater than the reference voltage, and the sampling voltage value on the bus is obtained after the first waiting time.
  • the second waiting time is the time when no sampling is performed. , which corresponds to the tail of the theoretical communication time.
  • the first waiting time and the second waiting time belong to the time during which the voltage signal on the bus is not sampled, and the specific values thereof can be preset.
  • the duration of the first digital and the second digital is determined, that is, the time of a single bit is also fixed.
  • the difference between the first duration T1 and the fixed time T is calculated, and the difference is compared with the set value, where the set value can be 0.5, such as the first duration T1 and If the difference between the fixed time T is less than 0.5, it is considered that the fixed time T is equal to the first time T1, and the air conditioner receives a "0". Similarly, the difference between the second time T2 and the fixed time T is less than 0.5, and it is considered that the fixed time T is equal to the second duration T2, and it is considered that the air conditioner receives a "1".
  • the third duration T3 wherein, the difference between the third duration T3 and the two fixed durations T is less than 0.5, and it is considered that the air conditioner has received two "0", and so on, determine the Nth duration Tn and n.
  • the difference between the fixed time T is less than 0.5, and it is considered that the air conditioner receives a "0".
  • a control device 500 for air-conditioning communication includes: an acquisition unit 502, a determination unit 504, and an output unit 506, wherein, The air conditioner is connected to the bus and conducts data communication through the bus.
  • the acquiring unit 502 is used to acquire the voltage signal on the bus;
  • the determining unit 504 is used to determine the voltage rise in the voltage signal when the voltage signal conforms to the comparison condition between the power supply voltage of the air conditioner and the reference voltage on the bus Edge slope and voltage falling edge slope; when the voltage rising edge slope and voltage falling edge slope meet the slope comparison conditions, compare the voltage signal time to obtain the processed voltage signal; and determine the data model library and the processed voltage signal.
  • the target data model is consistent with the voltage signal of the target data model; the output unit 506 is used for outputting data information corresponding to the target data model.
  • the embodiment of the present application proposes a control device 500 for air-conditioning communication, which specifically includes an acquisition unit 502 , a determination unit 504 and an output unit 506 .
  • the data model corresponding to the voltage signal in the bus is obtained by detecting the voltage signal in the bus, and the data model is compared with the model in the stored data model library, and if the comparison is consistent , and output the data information in the consistent data model (that is, the data information in the target data model in this application).
  • the voltage rising edge slope and the voltage falling edge slope are compared to realize the screening of the voltage data, and the collected data is realized by time comparison.
  • Data signal restoration In this process, the voltage signal on the bus is identified by model comparison, which reduces the detection caused by the interference of inductance, capacitance, resistance and signal reflection in air conditioners and other communication systems. The obtained signal data is abnormal.
  • the data model repository stores data models.
  • a frame of data in a communication protocol includes dozens to dozens of bytes, of which each byte has 10 bits of data.
  • a byte includes a start bit “0" and a stop bit “ 1” and the 8-bit data between the start bit “0” and the stop bit “1”, and these 8-bit data are used to transmit data.
  • the data model in the data model library is based on 10-bit data.
  • the 8-bit data can be divided into 4+4 parts, that is, the first 4 bits of data are saved as a model.
  • the last 4 bits of data are saved as one data.
  • the last 4 bits also need 16 models to represent.
  • the content of judging whether the voltage signal satisfies the comparison condition between the power supply voltage of the air conditioner and the reference voltage on the bus is specifically limited.
  • the air conditioner will be connected to the bus through a communication chip to achieve the acquisition of signals on the bus.
  • the sampling voltage value collected by the chip will be less than its power supply voltage.
  • the determining unit 504 is specifically used to limit Any sampled voltage value does not exceed the supply voltage, so that the voltage signal on the bus can be corrected accurately and the probability of outputting an incorrect signal is reduced.
  • the embodiment of the present application needs to further judge whether the slope of the rising edge of the voltage and the slope of the falling edge of the voltage meet the slope comparison condition, if the voltage value corresponding to the collected voltage signal is too low, it will have an impact on the accuracy of restoration , and even worse, rendering the signal uncorrectable.
  • the determining unit 504 is specifically configured to define that the difference between any sampled voltage value and the reference voltage should be large enough, such as greater than a preset threshold, to ensure that the sampled voltage value is large enough, thereby ensuring that the restored precision.
  • the preset threshold can be set according to actual needs. For example, when the power supply voltage of the communication chip is 3.3 volts, the value of the preset threshold can be 0.5 volts. At this time, the reference voltage cannot be more than 2.5 volts.
  • an error data model is output to remind the user to handle it.
  • the content of judging whether the slope of the rising edge of the voltage and the slope of the falling edge of the voltage satisfy the slope comparison condition is specifically limited.
  • the determining unit 504 is configured to: take the amplitude of the slope of the rising edge of the voltage, denoted as the first amplitude; take the amplitude of the slope of the falling edge of the voltage, denoted as the second amplitude; calculate the first amplitude and the second amplitude The ratio of the values; if the ratio is between 0.5 and 2, it is considered that the voltage rising edge slope and the voltage falling edge slope meet the slope comparison conditions.
  • the embodiment of the present application determines whether there is a large difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage by comparing the magnitude relationship between the amplitudes of the slopes.
  • the difference between the first amplitude value and the second amplitude value is not more than half, it is considered that the difference between the waveform of the rising edge of the voltage and the waveform of the falling edge of the voltage is small, that is, the slope comparison condition is satisfied, Considering that the first amplitude value may be larger than the second amplitude value, or may be smaller than the second amplitude value, if the comparison cases are divided separately, more data needs to be processed.
  • the embodiment of the present application quantifies the judgment that the difference between the first amplitude value and the second amplitude value is not more than half by determining the fluctuation range of the ratio between the first amplitude value and the second amplitude value Condition, specifically, the ratio needs to be greater than 0.5 and less than 2.
  • the ratio needs to be greater than 0.5 and less than 2.
  • the determining unit 504 is specifically configured to determine the voltage rising edge slope and the voltage falling edge slope, specifically, in the case that the sampled voltage value of the bus is greater than the reference voltage, record the first voltage value; If the value is greater than the reference voltage and the duration is greater than or equal to the first preset duration, record the second voltage value; and calculate the ratio of the second voltage value to the first voltage value, and use the ratio as the voltage rising edge slope.
  • the air conditioner periodically collects data on the bus. If the voltage value is collected and the voltage difference value is determined, the ratio of the time corresponding to the voltage difference value to the voltage difference value will be calculated to The corresponding slope is obtained, considering that the embodiment of the present application determines whether the slope comparison condition is satisfied by comparing the ratio between the first amplitude value and the second amplitude value, and the time corresponding to the voltage difference is the same.
  • the ratio of the second voltage value and the first voltage value can be regarded as the slope of the rising edge of the voltage.
  • the ratio of the maximum voltage value and the third voltage value can be regarded as the slope of the falling edge of the voltage, so as to reduce the need for air conditioning.
  • the amount of data processed is processed.
  • the reference voltage is U0
  • the first voltage value U1 is recorded
  • the second voltage value U2 is recorded
  • the sampled voltage value is is the maximum voltage value U3
  • the third voltage value U4 calculates the ratio of U2 to U1, denoted as ⁇ 1
  • the reference voltage is U0
  • the first voltage value U1 is recorded, and after t/2, that is, the first preset duration t
  • the sampling voltage value is the maximum voltage value U3, at the maximum voltage
  • the third voltage Value U3 calculates the ratio of U1-2 to U1, denoted as ⁇ 1
  • the determining unit 504 is specifically configured to define how to perform time comparison on the voltage signals and obtain the content of the processed voltage signals.
  • the binary data is the machine language that the machine can recognize, that is, the data "1" and the data "0".
  • the first number in the binary data may be the data "1" and the data "0" in the Any one of the corresponding binary data
  • the second number is another number except the first number, such as in one case, when the first number is the data "1”, the second number is the data "0", in another case, when the first digital number is data "0", the second digital number is data "1”, in the embodiment of the present application, the selected first digital number is data "0” , the second digit is the data "1".
  • the determining unit 504 is configured to: take the time when the sampled voltage value is greater than the reference voltage as the timing start time, and record the first time after the second preset duration; take the sampled voltage value of the bus as the time corresponding to the maximum voltage value The time is taken as the start timing, and the second time after the second preset time is recorded; the first time between the first time and the second time is determined; the first digital is determined according to the time corresponding to the first time and the first digital Take the time when the sampling voltage value of the bus is greater than the reference voltage again as the start timing time, record the third time after the second preset time length; Determine the second time length between the third time and the second time; Determine the number of the second number according to the duration corresponding to the second number and the second number; determine the number of the second number according to the number of the first number, the number of the second number, the first number and the second number voltage signal.
  • the way to determine the voltage signal on the bus is to determine the number of the first number and the second number in the binary data according to the duration of the high level or the duration of the low level on the bus.
  • the voltage collected by the air conditioner fluctuates greatly, and the accuracy is low.
  • the embodiments of the present application use a time comparison method to determine the number of the first number and the second number in the binary data, and determine the number of the first number and the second number according to the number of the first number and the number of the second number.
  • Data restoration is performed on the voltage signal by digital pair. In this process, the influence of the above situation on the read signal is reduced, and the reliability of the signal is ensured.
  • the first The fluctuation interval between the duration and the duration corresponding to the M first numbers specifically, by calculating the difference between the first duration and the duration corresponding to the M first numbers, and comparing the difference with the set value , in order to judge whether the fluctuation range exceeds the set value. If it does not exceed the set value, it is determined that the first duration corresponds to M consecutive first numbers, wherein it can be understood that the voltage signal between the first moment and the second moment corresponds to M consecutive first numbers. Digital, in the same way, the voltage signal between the second time and the third time corresponds to N consecutive second digital numbers. In the above process, the restoration of the collected voltage signal is realized, so as to obtain the processed voltage signal. .
  • control method for air-conditioning communication further comprises: acquiring the baud rate of the air-conditioning and the actual communication time on the bus; and determining the duration corresponding to the first number and the second number according to the baud rate and the actual communication time The duration corresponding to each number.
  • the duration corresponding to the first number and the duration corresponding to the second number are also different.
  • the duration corresponding to the number and the duration corresponding to the second number are calibrated, and the duration corresponding to the first number and the duration corresponding to the second number are determined according to the baud rate of the air conditioner and the actual communication time on the bus.
  • the actual communication time is the difference between the theoretical communication time on the bus and the first waiting time and the second waiting time, wherein the theoretical communication time can be understood as the voltage value on the bus is greater than or equal to the reference
  • the duration of the voltage is the time when the voltage value on the bus is greater than the reference voltage, and the sampling voltage value on the bus is obtained after the first waiting time.
  • the second waiting time is the time when no sampling is performed. , which corresponds to the tail of the theoretical communication time.
  • the first waiting time and the second waiting time belong to the time during which the voltage signal on the bus is not sampled, and the specific values thereof can be preset.
  • the duration of the first digital and the second digital is determined, that is, the time of a single bit is also fixed.
  • the difference between the first duration T1 and the fixed time T is calculated, and the difference is compared with the set value, where the set value can be 0.5, such as the first duration T1 and If the difference between the fixed time T is less than 0.5, it is considered that the fixed time T is equal to the first time T1, and the air conditioner receives a "0". Similarly, the difference between the second time T2 and the fixed time T is less than 0.5, and it is considered that the fixed time T is equal to the second duration T2, and it is considered that the air conditioner receives a "1".
  • the third duration T3 wherein, the difference between the third duration T3 and the two fixed durations T is less than 0.5, and it is considered that the air conditioner has received two "0", and so on, determine the Nth duration Tn and n.
  • the difference between the fixed time T is less than 0.5, and it is considered that the air conditioner receives a "0".
  • a communication system 600 which includes a processor 604, a memory 602, and programs or instructions stored in the memory 602 and executable on the processor 604, The programs or instructions, when executed by the processor 604, implement the steps of the air-conditioning communication control method according to any one of the first aspects.
  • An embodiment of the present application provides a communication system 600, wherein the communication system 600 includes a memory 602 and a processor 604, wherein the processor 604 executes a program or instruction stored in the memory 602 to implement any one of the first aspect Since the steps of the control method for air-conditioning communication are not included, the communication system 600 has all the beneficial technical effects of any one of the above-mentioned control methods for air-conditioning communication.
  • the communication system 600 executes the above method of the present application through the set communication chip, and specifically, establishes a communication data model, compares the three dimensions of slope, voltage, and time, and outputs the data model after the comparison is successful. Correct communication data, solve the communication signal error caused by external factors such as interference and cables, and improve the stability of communication.
  • a readable storage medium wherein a program or an instruction is stored on the readable storage medium, and when the program or instruction is executed by a processor, the air conditioner communication according to any one of the first aspect is implemented steps of the control method.
  • the embodiment of the present application proposes a readable storage medium, wherein, when the program or instruction stored on the readable storage medium is executed, the steps of the control method for air conditioner communication in any one of the first aspect are implemented, so the readable storage medium is readable.
  • the storage medium has all the beneficial technical effects of any one of the above-mentioned control methods for air-conditioning communication.
  • the term “plurality” refers to two or more than two, unless otherwise expressly defined, the orientation or positional relationship indicated by the terms “upper”, “lower” etc. is based on what is shown in the accompanying drawings The orientation or positional relationship is only for the convenience of describing the application and simplifying the description, rather than indicating or implying that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be construed as a limitation on the application;
  • the terms “connected”, “installed”, “fixed”, etc. should be understood in a broad sense.
  • connection can be a fixed connection, a detachable connection, or an integral connection; it can be directly connected, or through the middle media are indirectly connected.
  • connection can be a fixed connection, a detachable connection, or an integral connection; it can be directly connected, or through the middle media are indirectly connected.
  • description of the terms “one embodiment,” “some embodiments,” “a specific embodiment,” etc. means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in this application at least one embodiment or example of .
  • schematic representations of the above terms do not necessarily refer to the same embodiment or instance.
  • the particular features, structures, materials or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Chemical & Material Sciences (AREA)
  • Combustion & Propulsion (AREA)
  • Mechanical Engineering (AREA)
  • Nonlinear Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Selective Calling Equipment (AREA)
  • Air Conditioning Control Device (AREA)

Abstract

本申请提供了一种空调通信的控制方法、装置、通信系统和可读存储介质,空调通信的控制方法包括:获取总线的电压信号;基于电压信号满足通信设备的供电电压和总线上的基准电压的比对条件,确定电压信号中的电压上升沿斜率以及电压下降沿斜率;基于电压上升沿斜率和电压下降沿斜率满足斜率比对条件,对电压信号进行时间对比,得到处理后的电压信号;确定数据模型库中与处理后的电压信号一致的目标数据模型;输出目标数据模型对应的数据信息。采用模型对比的方式对总线上的电压信号进行识别,减少了因空调以及其他通信系统中的电感、电容、电阻以及信号反射等受到干扰时,导致的检测得到的信号数据异常。

Description

空调通信的控制方法、装置、通信系统和可读存储介质
本申请要求于2020年12月09日提交中国专利局、申请号为“202011433039.4”、申请名称为“空调通信的控制方法、装置、通信系统和可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信控制技术领域,具体而言,涉及一种空调通信的控制方法、装置、通信系统和可读存储介质。
背景技术
相关技术方案中,空调以及其他通信系统中的电感、电容、电阻以及信号反射等受到干扰时,会导致检测得到的信号发生畸变。
具体地,空调以及其他通信系统中MCU的采样方式一般是将晶振的频率倍频处理,采样一定次数之后,读取采样的数据,如识别通信信号的高低电平,空调以及其他通信系统中MCU会设置一个检测阈值,在出现如上文中的畸变时,会使得MCU读取得到的数据出现错误。
以485通信为例,检测阈值为-200mV~200mV,在总线上的电压值大于200mV时,认为从总线上识别到“1”,当总线上的电压值小于-200mV,认为从总线上识别到“0”,在出现如上文中的畸变时,如图10所示,正常情况下总线差分信号的电压值为0V,通信接口芯片输出信号为“1”,当总线信号受到干扰发生波动,通信接口芯片就会输出错误的信号“0”。
如图11所示,对于通信线过长或电阻、电容影响,在通信速率较快时,总线上的信号传输变化缓慢,根据通信接口芯片的检测阈值,如485通信的-200mV~200mV,通信接口芯片输出“1”的时间会变短,最终造成通信的质量下降。
申请内容
本申请旨在至少解决现有技术或相关技术中存在的技术问题之一。
为此,本申请的第一个方面在于,提供了一种空调通信的控制方法。
本申请的第二个方面在于,提供了一种空调通信的控制装置。
本申请的第三个方面在于,提供了一种通信系统。
本申请的第四个方面在于,提供了一种可读存储介质。
有鉴于此,根据本申请的第一个方面,本申请提供了一种空调通信的控制方法,其中,空调与总线连接,空调通信的控制方法包括:获取总线的电压信号;基于电压信号满足空调的供电电压和总线上的基准电压的比对条件,确定电压信号中的电压上升沿斜率以及电压下降沿斜率;基于电压上升沿斜率和电压下降沿斜率满足斜率比对条件,对电压信号进行时间对比,得到处理后的电压信号;确定数据模型库中与处理后的电压信号一致的目标数据模型;输出目标数据模型对应的数据信息。
在本申请的技术方案中,通过对总线中的电压信号进行检测,以得到总线中的电压信号所对应的数据模型,并将该数据模型与存储的数据模型库中的模型进行比对,在比对一致的情况下,输出比对一致的数据模型中的数据信息(即本申请中的目标数据模型中的数据信息)。
具体地,通过对获取总线上采集的电压信息进行电压比对,电压上升沿斜率、电压下降沿斜率的斜率比对实现了对电压数据的筛选,并通过时间对比的方式实现了对采集得到的数据的信号还原,在此过程中,采用模型对比的方式对总线上的电压信号进行识别,减少了因空调以及其他通信系统中的电感、电容、电阻以及信号反射等受到干扰时,导致的检测得到的信号数据异常。
另外,本申请提供的上述技术方案中的空调通信的控制方法还可以具有如下附加技术特征:
在上述任一技术方案中,基于电压信号中任一采样电压值小于或等于空调的供电电压,且与基准电压的差值大于预设阈值,确定电压信号满足空调的供电电压、总线上的基准电压的比对条件。
在该技术方案中,具体限定了电压信号是否满足空调的供电电压、总线上的基准电压的比对条件的判断过程。
通常情况下,空调会通过一个通信芯片与总线连接,以实现总线上的 信号的获取,而该芯片在使用时,芯片所采集的电压信号所在的区间会小于其供电电压,故为了减少因总线上的电压信号对应的电压值过高,如超过其供电电压,致使空调无法对其进行采集以及还原,本申请的技术方案中,在进行电压比对时,限定任一采样电压值小于或等于供电电压,以便可以准确地对总线上的电压信号进行矫正,降低输出错误信号的几率。
此外,由于本申请的技术方案需要对电压上升沿斜率和电压下降沿斜率满足斜率比对条件进行比对,若采集得到的电压信号所对应的电压值过低,则会对还原的精度产生影响,更有甚者,致使信号无法矫正。
为了解决上述问题,本申请的技术方案具体限定了任一采样电压值与基准电压之间的差值要足够大,如大于预设阈值,以确保才采样电压值足够大,进而确保了还原的精度。
在上述任一技术方案中,预设阈值可以根据实际需要进行设定,举例来说,在通信芯片的供电电压为3.3伏特时,预设阈值的取值可以是0.5伏特,此时基准电压不能超过2.5伏特。
在上述任一技术方案中,若电压信号不满足空调的供电电压、总线上的基准电压的比对条件时,输出错误数据模型,以提醒用户进行处理。
在上述任一技术方案中,具体限定了电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件的判定过程,具体地,确定电压上升沿斜率所对应的第一幅值和电压下降沿斜率对应的第二幅值;基于第一幅值与第二幅值之间的比值大于0.5、且小于2,确定电压上升沿斜率和电压下降沿斜率满足斜率比对条件。
在该技术方案中,通过将确定的第一幅值和第二幅值进行比较,以便确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,对于差异较大的情况,认为电压信号不满足斜率比对条件,此时,输出错误数据模型,以提醒用户进行处理。
具体地,为了便于对电压信号是否满足斜率比对条件进行量化处理,本申请的技术方案通过比较斜率的幅值的大小关系来确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,具体地,在第一幅值和第二幅值之间相差不超过一半的情况下,认为电压上升沿的波形和电压下降沿的 波形之间的差异较小,即满足斜率比对条件,考虑到第一幅值可以大于第二幅值,也可以小于第二幅值,若单独划分比较情况,则需要处理的数据较多。
为了减少数据处理的量,本申请的技术方案通过确定第一幅值与第二幅值之间的比值的波动范围来量化第一幅值和第二幅值之间相差不超过一半这一判断条件,具体地,该比值需要大于0.5、且小于2,在此过程中,在对电压上升沿的波形和电压下降沿的波形之间的差异的过程中,仅需判断该比值是否大于0.5且小于2即可实现该差异的判定,降低了比对难度。
在上述任一技术方案中,确定电压信号中的电压上升沿斜率以及电压下降沿斜率的步骤,具体包括:基于总线的采样电压值大于基准电压,记录采样电压值为第一电压值;基于总线的采样电压值大于基准电压的持续时长大于或等于第一预设时长,记录采样电压值为第二电压值;将第二电压值与第一电压值的比值作为电压上升沿斜率;查找以总线的采样电压值为最大电压值作为开始时刻,第一预设时长后记录的采样电压值为第三电压值;将最大电压值与第三电压值的比值作为电压下降沿斜率。
在该技术方案中,空调是周期性在总线上采集数据,若在采集得到的电压值并确定的电压差值之后,将计算其与电压差值所对应的时间的比值,以得到对应的斜率,考虑到本申请的技术方案是通过比较第一幅值与第二幅值之间的比值大小来确定是否满足斜率比对条件,在电压差值所对应的时间是相同的情况下,可以将第二电压值和第一电压值的比值看作电压上升沿斜率,同理,将最大电压值和第三电压值的比值看作电压下降沿斜率,以此来降低空调所需要处理的数据量。
在上述任一技术方案中,对电压信号进行时间对比,得到处理后的电压信号的步骤,具体包括:确定以总线的采样电压值大于基准电压所对应的时刻作为开始时刻,第二预设时长后的第一时刻;确定以总线的采样电压值为最大电压值对应的时刻作为开始时刻第二预设时长后的第二时刻;根据第一时刻和第二时刻确定第一时长;根据第一时长与二进制数据中的第一个数码对应的时长确定第一时长代表的第一个数码的个数;确定以总线的采样电压值再次大于基准电压所对应的时刻作为开始时刻,第二预设 时长后的第三时刻;根据第三时刻和第二时刻确定第二时长;根据第二时长与二进制数据中的第二个数码对应的时长确定第二时长代表的第二个数码的个数;根据第一个数码的个数、第二个数码的个数、第一个数码和第二个数码确定处理后的电压信号。
通常情况下,确定总线上电压信号的方式是根据总线上高电平的持续时间或低电平的持续时间来确定二进制数据中的第一个数码和第二个数码的个数,由于总线上存在信号干扰,空调采集得到的电压波动较大,精度较低。
为了解决上述问题,本申请的技术方案采用时间对比的方式来确定二进制数据中的第一个数码和第二个数码的个数,并根据第一个数码的个数和第二个数码的个数对电压信号进行数据还原,在此过程中,减少了上述情况对读取信号的影响,确保了信号的可信度。
在上述任一技术方案中,基于第一时长与M个第一个数码对应的时长的差值小于或等于设定值,确定第一时长对应M个连续的第一个数码;基于第二时长与N个第二个数码对应的时长的差值小于或等于设定值,确定第二时长对应N个连续的第二个数码,其中,M,N为自然数。
在该技术方案中,考虑到由于总线过长、或与总线连接的电容或者如与总线连接的采样电阻的影响,总线上的电压信号的长度会发生变化,为了消除该影响,给出第一时长与M个第一个数码对应的时长之间的波动区间,具体地,通过计算第一时长与M个第一个数码对应的时长的差值,并将该差值与设定值进行比较,以便判断该波动区间是否超出设定值。若不超过设定值时,认定第一时长对应M个连续的第一个数码,其中,可以理解的是,即第一时刻至第二时刻之间的电压信号对应M个连续的第一个数码,同理,第二时刻至第三时刻之间的电压信号对应N个连续的第二个数码,在上述过程中,实现了对采集得到的电压信号的还原,以便得到处理后的电压信号。
在上述任一技术方案中,空调通信的控制方法还包括:获取空调的波特率以及总线上的实际通信时间;根据波特率和实际通信时间确定第一个数码对应的时长以及第二个数码对应的时长。
在该技术方案中,考虑到空调进行通信的波特率不同,第一个数码对应的时长以及第二个数码对应的时长也会不同,为了确保目标数据模型的准确性,需要对第一个数码对应的时长以及第二个数码对应的时长进行标定,根据空调的波特率以及总线上的实际通信时间来确定第一个数码对应的时长以及第二个数码对应的时长。
在上述任一技术方案中,实际通信时间即总线上的理论通信时间与第一等待时间、第二等待时间的差值,其中,理论通信时间可以理解为在总线上的电压值大于或等于基准电压的时长,第一等待时长为总线上的电压值大于基准电压的时长为第一等待时间之后,才开始进行获取总线上的采样电压值,同理,第二等待时间为不进行采样的时间,其对应理论通信时间的尾部。
在其中一个实施例中,第一等待时间、第二等待时间属于不对总线上的电压信号进行采样的时间,其具体数值可以预先进行设定。
在本申请第二方面的实施例中,提出了一种空调通信的控制装置,其中,空调与总线连接,空调通信的控制装置包括:获取单元,用于获取总线的电压信号;确定单元,用于基于电压信号满足空调的供电电压和总线上的基准电压的比对条件,确定电压信号中的电压上升沿斜率以及电压下降沿斜率;基于电压上升沿斜率和电压下降沿斜率满足斜率比对条件,对电压信号进行时间比对,得到处理后的电压信号;确定数据模型库中与处理后的电压信号一致的目标数据模型;输出单元,用于输出目标数据模型对应的数据信息。
本申请的技术方案提出了一种空调通信的控制装置,其具体包括获取单元、确定单元以及输出单元。其中,通过对总线中的电压信号进行检测,以得到总线中的电压信号所对应的数据模型,并将该数据模型与存储的数据模型库中的模型进行比对,在比对一致的情况下,输出比对一致的数据模型中的数据信息(即本申请中的目标数据模型中的数据信息)。
具体地,通过对获取总线上采集的电压信息进行电压比对,电压上升沿斜率、电压下降沿斜率的斜率比对实现了对电压数据的筛选,并通过时间对比的方式实现了对采集得到的数据的信号还原,在此过程中,采用模 型对比的方式对总线上的电压信号进行识别,减少了因空调以及其他通信系统中的电感、电容、电阻以及信号反射等受到干扰时,导致的检测得到的信号数据异常。
另外,本申请提供的上述技术方案中的空调通信的控制装置还可以具有如下附加技术特征:
在上述任一技术方案中,确定单元具体用于:基于电压信号中任一采样电压值小于或等于空调的供电电压,且与基准电压的差值大于预设阈值,确定电压信号满足空调的供电电压、总线上的基准电压的比对条件。
在该技术方案中,具体限定了电压信号是否满足空调的供电电压、总线上的基准电压的比对条件的判断过程。
通常情况下,空调会通过一个通信芯片与总线连接,以实现总线上的信号的获取,而该芯片在使用时,芯片所采集的电压信号所在的区间会小于其供电电压,故为了减少因总线上的电压信号对应的电压值过高,如超过其供电电压,致使空调通信无法对其进行采集以及还原,本申请的技术方案中,在进行电压比对时,限定任一采样电压值小于或等于供电电压,以便可以准确地对总线上的电压信号进行矫正,降低输出错误信号的几率。
此外,由于本申请的技术方案需要对电压上升沿斜率和电压下降沿斜率满足斜率比对条件进行比对,若采集得到的电压信号所对应的电压值过低,则会对还原的精度产生影响,更有甚者,致使信号无法矫正。
为了解决上述问题,本申请的技术方案具体限定了任一采样电压值与基准电压之间的差值要足够大,如大于预设阈值,以确保才采样电压值足够大,进而确保了还原的精度。
在上述任一技术方案中,预设阈值可以根据实际需要进行设定,举例来说,在通信芯片的供电电压为3.3伏特时,预设阈值的取值可以是0.5伏特,此时基准电压不能超过2.5伏特。
在上述任一技术方案中,若电压信号不满足空调的供电电压、总线上的基准电压的比对条件时,输出错误数据模型,以提醒用户进行处理。
在上述任一技术方案中,确定单元具体用于:确定电压上升沿斜率所对应的第一幅值和电压下降沿斜率对应的第二幅值;基于第一幅值与第二 幅值之间的比值大于0.5、且小于2,确定电压上升沿斜率和电压下降沿斜率满足斜率比对条件。
在该技术方案中,通过将确定的第一幅值和第二幅值进行比较,以便确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,对于差异较大的情况,认为电压信号不满足斜率比对条件,此时,输出错误数据模型,以提醒用户进行处理。
具体地,为了便于对电压信号是否满足斜率比对条件进行量化处理,本申请的技术方案通过比较斜率的幅值的大小关系来确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,具体地,在第一幅值和第二幅值之间相差不超过一半的情况下,认为电压上升沿的波形和电压下降沿的波形之间的差异较小,即满足斜率比对条件,考虑到第一幅值可以大于第二幅值,也可以小于第二幅值,若单独划分比较情况,则需要处理的数据较多。
为了减少数据处理的量,本申请的技术方案通过确定第一幅值与第二幅值之间的比值的波动范围来量化第一幅值和第二幅值之间相差不超过一半这一判断条件,具体地,该比值需要大于0.5、且小于2,在此过程中,在对电压上升沿的波形和电压下降沿的波形之间的差异的过程中,仅需判断该比值是否大于0.5且小于2即可实现该差异的判定,降低了比对难度。
在上述任一技术方案中,确定单元具体用于:基于总线的采样电压值大于基准电压,记录采样电压值为第一电压值;基于总线的采样电压值大于基准电压的持续时长大于或等于第一预设时长,记录采样电压值为第二电压值;将第二电压值与第一电压值的比值作为电压上升沿斜率;查找以总线的采样电压值为最大电压值作为开始时刻,第一预设时长后记录的采样电压值为第三电压值;将最大电压值与第三电压值的比值作为电压下降沿斜率。
在该技术方案中,空调是周期性在总线上采集数据,若在采集得到的电压值并确定的电压差值之后,将计算其与电压差值所对应的时间的比值,以得到对应的斜率,考虑到本申请的技术方案是通过比较第一幅值与第二幅值之间的比值大小来确定是否满足斜率比对条件,在电压差值所对应的 时间是相同的情况下,可以将第二电压值和第一电压值的比值看作电压上升沿斜率,同理,将最大电压值和第三电压值的比值看作电压下降沿斜率,以此来降低空调所需要处理的数据量。
在上述任一技术方案中,确定单元具体用于:确定以总线的采样电压值大于基准电压所对应的时刻作为开始时刻,第二预设时长后的第一时刻;确定以总线的采样电压值为最大电压值对应的时刻作为开始时刻第二预设时长后的第二时刻;根据第一时刻和第二时刻确定第一时长;根据第一时长与二进制数据中的第一个数码对应的时长确定第一时长代表的第一个数码的个数;确定以总线的采样电压值再次大于基准电压所对应的时刻作为开始时刻,第二预设时长后的第三时刻;根据第三时刻和第二时刻确定第二时长;根据第二时长与二进制数据中的第二个数码对应的时长确定第二时长代表的第二个数码的个数;根据第一个数码的个数、第二个数码的个数、第一个数码和第二个数码确定处理后的电压信号。
通常情况下,确定总线上电压信号的方式是根据总线上高电平的持续时间或低电平的持续时间来确定二进制数据中的第一个数码和第二个数码的个数,由于总线上存在信号干扰,空调采集得到的电压波动较大,精度较低。
为了解决上述问题,本申请的技术方案采用时间对比的方式来确定二进制数据中的第一个数码和第二个数码的个数,并根据第一个数码的个数和第二个数码的个数对电压信号进行数据还原,在此过程中,减少了上述情况对读取信号的影响,确保了信号的可信度。
在上述任一技术方案中,确定单元具体用于:基于第一时长与M个第一个数码对应的时长的差值小于或等于设定值,确定第一时长对应M个连续的第一个数码;基于第二时长与N个第二个数码对应的时长的差值小于或等于设定值,确定第二时长对应N个连续的第二个数码,其中,M,N为自然数。
在该技术方案中,考虑到由于总线过长、或与总线连接的电容或者如与总线连接的采样电阻的影响,总线上的电压信号的长度会发生变化,为了消除该影响,给出第一时长与M个第一个数码对应的时长之间的波动区 间,具体地,通过计算第一时长与M个第一个数码对应的时长的差值,并将该差值与设定值进行比较,以便判断该波动区间是否超出设定值。若不超过设定值时,认定第一时长对应M个连续的第一个数码,其中,可以理解的是,即第一时刻至第二时刻之间的电压信号对应M个连续的第一个数码,同理,第二时刻至第三时刻之间的电压信号对应N个连续的第二个数码,在上述过程中,实现了对采集得到的电压信号的还原,以便得到处理后的电压信号。
在上述任一技术方案中,确定单元还用于:获取空调的波特率以及总线上的实际通信时间;根据波特率和实际通信时间确定第一个数码对应的时长以及第二个数码对应的时长。
在该技术方案中,考虑到空调进行通信的波特率不同,第一个数码对应的时长以及第二个数码对应的时长也会不同,为了确保目标数据模型的准确性,需要对第一个数码对应的时长以及第二个数码对应的时长进行标定,根据空调的波特率以及总线上的实际通信时间来确定第一个数码对应的时长以及第二个数码对应的时长。
在上述任一技术方案中,实际通信时间即总线上的理论通信时间与第一等待时间、第二等待时间的差值,其中,理论通信时间可以理解为在总线上的电压值大于或等于基准电压的时长,第一等待时长为总线上的电压值大于基准电压的时长为第一等待时间之后,才开始进行获取总线上的采样电压值,同理,第二等待时间为不进行采样的时间,其对应理论通信时间的尾部。
在其中一个实施例中,第一等待时间、第二等待时间属于不对总线上的电压信号进行采样的时间,其具体数值可以预先进行设定。
在本申请的第三个方面,提出了一种通信系统,其包括处理器,存储器及存储在存储器上并可在处理器上运行的程序或指令,程序或指令被处理器执行时实现如第一方面中任一项的空调通信的控制方法的步骤。
本申请的技术方案提出了一种通信系统,其中,该通信系统包括存储器以及处理器,其中,处理器执行存储在存储器上的程序或指令实现如第一方面中任一项空调通信的控制方法的步骤,故通信系统具有上述任一项 的空调通信的控制方法的全部有益技术效果。
在本申请的第四方面,提出了一种可读存储介质,其中,可读存储介质上存储程序或指令,程序或指令被处理器执行时实现如第一方面中任一项的空调通信的控制方法的步骤。
本申请的技术方案提出了一种可读存储介质,其中,该可读存储介质上存储的程序或指令被执行时实现如第一方面中任一项空调通信的控制方法的步骤,故可读存储介质具有上述任一项的空调通信的控制方法的全部有益技术效果。
本申请的附加方面和优点将在下面的描述中部分给出,部分将从下面的描述中变得明显,或通过本申请的实践了解到。
附图说明
本申请的上述和/或附加的方面和优点从结合下面附图对实施例的描述中将变得明显和容易理解,其中:
图1示出了本申请一个实施例中的空调通信的控制方法的流程示意图;
图2示出了本申请一个实施例中的判断电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件的流程示意图;
图3示出了本申请一个实施例中的确定电压上升沿斜率以及电压下降沿斜率的流程示意图;
图4示出了本申请一个实施例中的对电压信号进行时间对比,并得到处理后的电压信号的流程示意图;
图5示出了本申请一个实施例中的空调通信的控制装置的示意框图;
图6示出了本申请一个实施例中的通信系统的示意框图;
图7示出了本申请一个实施例中的电压信号的示意图;
图8示出了本申请一个实施例中的电压信号的示意图;
图9示出了本申请一个实施例中的电压信号的示意图;
图10示出了相关技术方案中空调采集到的信号出现畸变的波形图;
图11示出了相关技术方案中空调采集到的信号出现畸变的波形图。
具体实施方式
为了能够更清楚地理解本申请的上述方面、特征和优点,下面结合附图和具体实施方式对本申请进行进一步的详细描述。需要说明的是,在不冲突的情况下,本申请的实施例及实施例中的特征可以相互组合。
在下面的描述中阐述了很多具体细节以便于充分理解本申请,但是,本申请还可以采用其他不同于在此描述的其他方式来实施,因此,本申请的保护范围并不受下面公开的具体实施例的限制。
实施例一
如图1所示,根据本申请的第一个方面,本申请提供了一种空调通信的控制方法,其中,空调与总线连接,空调通信的控制方法包括:
步骤102,获取总线上的电压信号;
步骤104,在电压信号符合空调的供电电压以总线上的基准电压的比对条件的情况下,确定电压信号中的电压上升沿斜率以及电压下降沿斜率;
步骤106,在电压上升沿斜率和电压下降沿斜率符合斜率比对条件的情况下,对电压信号进行时间对比,得到处理后的电压信号;
步骤108,确定数据模型库中与处理后的电压信号一致的目标数据模型;
步骤110,输出目标数据模型对应的数据信息。
在该实施例中,总线上的电压信号可以是在时间上连续的多个离散采样值。
在本申请的实施例中,通过对总线中的电压信号进行检测,以得到总线中的电压信号所对应的数据模型,并将该数据模型与存储的数据模型库中的模型进行比对,在比对一致的情况下,输出比对一致的数据模型中的数据信息(即本申请中的目标数据模型中的数据信息)。
具体地,通过对获取总线上采集的电压信息进行电压比对,电压上升沿斜率、电压下降沿斜率的斜率比对实现了对电压数据的筛选,并通过时间对比的方式实现了对采集得到的数据的信号还原,在此过程中,采用模型对比的方式对总线上的电压信号进行识别,减少了因空调以及其他通信系统中的电感、电容、电阻以及信号反射等受到干扰时,导致的检测得到 的信号数据异常。
在其中一个实施例中,数据模型库存储有数据模型。
通常情况下,通信协议中的一帧数据包括十几到几十个字节,其中,每个字节有10位数据,一般来说,一个字节包括起始位“0”和终止位“1”以及位于起始位“0”和终止位“1”之间的8位数据,而这8位数据是用于传输数据,基于此,数据模型库中的数据模型是根据10位数据建立的数据模型,在每位数据可以是“1”,也可以是“0”的情况下,需要构建2 8=256个数据模型,并将其进行保存,举例来说,“1111111100”为一个通信数据模型,用十六进制表示为一个字节“FE”,其中第一个“0”为起始位,最后一个“1”为终止位,再比如“1101010100”十六进制表示为一个字节“aa”。通过构建上述数据模型,以便在得到处理后的电压信号时,可以将其与数据模型库中的数据模型进行比对,进而得到如“FE”或“aa”的数据信息。
考虑到数据模型需要占据较大的存储空间,同时,模型对比也需要较大的数据处理量,可以将8为数据划分成4+4两个部分,即前4位数据作为一个模型进行保存,后4位数据作为一个数据进行保存,此时,前4位数据仅需要2 4=16个模型就可以完全表示,同理,后4位也需要16个模型来进行表示,在这种情况下,数据模型库中的模型仅需32个。在这种方案中,可以有效降低了模型的存储空间以及需要模型比对的数据量。
实施例二
在该实施例中,具体限定了判断电压信号是否满足空调的供电电压以及总线上的基准电压的比对条件的内容。
通常情况下,空调会通过一个通信芯片与总线连接,以实现总线上的信号的获取,而该芯片在使用时,芯片所采集的采样电压值会小于其供电电压,为了减少因总线上的电压信号对应的电压值过高,如超过其供电电压,致使空调无法对其进行采集以及还原这种情况的出现,本申请的实施例中,在进行电压比对时,限定任一采样电压值不超过供电电压,以便可以准确地对总线上的电压信号进行矫正,降低输出错误信号的几率。
此外,由于本申请的实施例需要进一步判断对电压上升沿斜率和电压 下降沿斜率是否满足斜率比对条件,若采集得到的电压信号所对应的电压值过低,则会对还原的精度产生影响,更有甚者,致使信号无法矫正。
为了解决上述问题,本申请的实施例具体限定了任一采样电压值与基准电压之间的差值要足够大,如大于预设阈值,以确保才采样电压值足够大,进而确保了还原的精度。
在上述任一实施例中,预设阈值可以根据实际需要进行设定,举例来说,如图7所示,在通信芯片的供电电压为3.3伏特时,采样电压值U2和U3不能超过3.3伏特,预设阈值的取值可以是0.5伏特,此时基准电压U0不能超过2.5伏特。
在上述任一实施例中,若电压信号不满足空调的供电电压、总线上的基准电压的比对条件时,输出错误数据模型,以提醒用户进行处理。
实施例三
在本申请的一个实施例中,具体限定了判断电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件的内容。
具体地,如图2所示,判断电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件的内容包括:
步骤202,取电压上升沿斜率的幅值,记作第一幅值;
步骤204,取电压下降沿斜率的幅值,记作第二幅值;
步骤206,计算第一幅值和第二幅值的比值;
步骤208,若该比值处于0.5至2之间,认为电压上升沿斜率和电压下降沿斜率符合斜率比对条件。
通过将确定的第一幅值和第二幅值进行比较,以便确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,对于差异较大的情况,认为电压信号不满足斜率比对条件,此时,输出错误数据模型,以提醒用户进行处理。
具体地,为了便于对电压信号是否满足斜率比对条件进行量化处理,本申请的实施例通过比较斜率的幅值的大小关系来确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,具体地,在第一幅值和第二幅值之间相差不超过一半的情况下,认为电压上升沿的波形和电压下降沿的波 形之间的差异较小,即满足斜率比对条件,考虑到第一幅值可以大于第二幅值,也可以小于第二幅值,若单独划分比较情况,则需要处理的数据较多。
为了减少数据处理的量,本申请的实施例通过确定第一幅值与第二幅值之间的比值的波动范围来量化第一幅值和第二幅值之间相差不超过一半这一判断条件,具体地,该比值需要大于0.5、且小于2,在此过程中,在对电压上升沿的波形和电压下降沿的波形之间的差异的过程中,仅需判断该比值是否大于0.5且小于2即可实现该差异的判定,降低了比对难度。
实施例四
在本申请的一个实施例中,提出了一种电压上升沿斜率以及电压下降沿斜率的确定过程,具体地,如图3所示,包括:
步骤302,在总线的采样电压值大于基准电压的情况下,记录第一电压值;
步骤304,在总线的采样电压值大于基准电压、且持续时长大于或等于第一预设时长,记录第二电压值;
步骤306,计算第二电压值与第一电压值的比值,并将该比值作为电压上升沿斜率。
对于电压下升沿斜率,查找以总线的采样电压值为最大电压值所对应的时刻作为开始时刻,第一预设时长后记录的采样电压值为第三电压值;计算最大电压值与第三电压值的比值,并将该比值作为电压下降沿斜率。
在该实施例中,通常情况下,空调是周期性在总线上采集数据,若在采集得到的电压值并确定的电压差值之后,将计算其与电压差值所对应的时间的比值,以得到对应的斜率,考虑到本申请的实施例是通过比较第一幅值与第二幅值之间的比值大小来确定是否满足斜率比对条件,在电压差值所对应的时间是相同的情况下,可以将第二电压值和第一电压值的比值看作电压上升沿斜率,同理,将最大电压值和第三电压值的比值看作电压下降沿斜率,以此来降低空调所需要处理的数据量。
具体地,如图7所示,基准电压为U0,在采样电压值大于基准电压U0时,记录第一电压值U1,在第一预设时长t后,记录第二电压值U2, 采样电压值为最大电压值U3,在最大电压值U3的第一预设时长t后,记录第三电压值U4,计算U2与U1的比值,记作λ1,计算U3与U4的比值,记作λ2,基于λ1与λ2相差不超过一半,认为符合斜率比对条件。
在其中一个实例中,如图8所示,具体地,基准电压为U0,在采样电压值大于基准电压U0时,记录第一电压值U1,在t/2后,即第一预设时长t的一半后,记录第四电压值U1-2,再经过t/2后,即第一预设时长t的一半后,记录第二电压值U2,采样电压值为最大电压值U3,在最大电压值U3后t/2时,即第一预设时长t的一半后,记录第五电压值U3-2,再经过t/2后,即第一预设时长t的一半后,记录第三电压值U3,计算U1-2与U1的比值,记作μ1,计算U2与U1-2的比值,记作μ3,计算U3与U3-2的比值,记作μ3,计算U3-2与U4的比值,记作μ4,若μ1与μ4相差不超过一半,且μ2与μ3相差不超过一半认为符合斜率比对条件。
实施例五
在该实施例中,具体限定了如何对电压信号进行时间对比,并得到处理后的电压信号的内容。
二进制数据是机器能够识别到的机器语言,即数据“1”和数据“0”,在本申请的实施例中,二进制数据中的第一个数码可以是数据“1”和数据“0”中的任意一个,对应的二进制数据中的第二个数码是除第一个数码的另一个数码,如在一种情况下,在第一个数码是数据“1”时,第二个数码是数据“0”,在另一种情况下在第一个数码是数据“0”时,第二个数码是数据“1”,在本申请的实施例中,选取第一个数码是数据“0”时,第二个数码是数据“1”。
空调与总线连接,通过电流传输的方式进行数据传输,比如总线上的其它通信设备要发送数据0,就从总线上拉一个恒定的电流M,发送数据1就往总线上拉一个恒定的电流N,N可以为0,只需要在电源上串一个采样电阻,总线上的其它通信设备拉的电流就会通过这个采样电阻,并在采样电阻上形成电压,通过采集这个电阻上电压的信号得到其它通信设备所传输的数据。
在该方案中,通过对电压信号进行时间对比,以便确定电压信号中包 含“1”或“0”的个数,如单独一个“1”,两个“1”。
图4示出了具体限定了如何对电压信号进行时间对比,并得到处理后的电压信号的内容。如图4所示:
步骤402,以采样电压值大于基准电压所对应的时刻作为计时开始时刻,记录第二预设时长后的第一时刻;
步骤404,以总线的采样电压值为最大电压值所对应的时刻作为开始计时时刻,记录第二预设时长后的第二时刻;
步骤406,确定第一时刻和第二时刻之间的第一时长;
步骤408,根据第一时长与第一个数码对应的时长确定第一个数码的个数;
步骤410,以总线的采样电压值再次大于基准电压所对应的时刻作为开始计时时刻,记录第二预设时长后的第三时刻;
步骤412,确定第三时刻和第二时刻之间的第二时长;
步骤414,根据第二时长与第二个数码对应的时长确定第二个数码的个数;
步骤416,根据第一个数码的个数、第二个数码的个数、第一个数码和第二个数码确定处理后的电压信号。
通常情况下,确定总线上电压信号的方式是根据总线上高电平的持续时间或低电平的持续时间来确定二进制数据中的第一个数码和第二个数码的个数,由于总线上存在信号干扰,空调采集得到的电压波动较大,精度较低。
为了解决上述问题,本申请的实施例采用时间对比的方式来确定二进制数据中的第一个数码和第二个数码的个数,并根据第一个数码的个数和第二个数码的个数对电压信号进行数据还原,在此过程中,减少了上述情况对读取信号的影响,确保了信号的可信度。
在上述任一实施例中,在第一时长与M个第一个数码对应的时长的差值小于或等于设定值,确定第一时长对应M个连续的第一个数码;在第二时长与N个第二个数码对应的时长的差值小于或等于设定值,确定第二时长对应N个连续的第二个数码,其中,M,N为自然数。
在该实施例中,考虑到由于总线过长、或与总线连接的电容或者如与总线连接的采样电阻的影响,总线上的电压信号的长度会发生变化,为了消除该影响,给出第一时长与M个第一个数码对应的时长之间的波动区间,具体地,通过计算第一时长与M个第一个数码对应的时长的差值,并将该差值与设定值进行比较,以便判断该波动区间是否超出设定值。若不超过设定值时,认定第一时长对应M个连续的第一个数码,其中,可以理解的是,即第一时刻至第二时刻之间的电压信号对应M个连续的第一个数码,同理,第二时刻至第三时刻之间的电压信号对应N个连续的第二个数码,在上述过程中,实现了对采集得到的电压信号的还原,以便得到处理后的电压信号。
在上述任一实施例中,空调通信的控制方法还包括:获取空调的波特率和总线上的实际通信时间;以及根据波特率和实际通信时间确定第一个数码对应的时长以及第二个数码对应的时长。
在该实施例中,考虑到空调进行通信的波特率不同,第一个数码对应的时长以及第二个数码对应的时长也会不同,为了确保目标数据模型的准确性,需要对第一个数码对应的时长以及第二个数码对应的时长进行标定,根据空调的波特率以及总线上的实际通信时间来确定第一个数码对应的时长以及第二个数码对应的时长。
在上述任一实施例中,实际通信时间即总线上的理论通信时间与第一等待时间、第二等待时间的差值,其中,理论通信时间可以理解为在总线上的电压值大于或等于基准电压的时长,第一等待时长为总线上的电压值大于基准电压的时长为第一等待时间之后,才开始进行获取总线上的采样电压值,同理,第二等待时间为不进行采样的时间,其对应理论通信时间的尾部。
在其中一个实施例中,第一等待时间、第二等待时间属于不对总线上的电压信号进行采样的时间,其具体数值可以预先进行设定。
举例来说,如图9所示,在波特率以及实际通信时间确定下来的情况下,第一个数码以及第二个数码的时长也确定下来了,即单个bit的时间也固定下来了。
在第一时长T1确定下来之后,计算第一时长T1与固定时间T的差值,并将该差值与设定值进行比较,其中,设定值可以取值0.5,如第一时长T1与固定时间T的差值小于0.5,认为固定时间T与第一时长T1相等,认为空调接收到一个“0”,同理,第二时长T2与固定时间T的差值,小于0.5,认为固定时间T与第二时长T2相等,认为空调接收到一个“1”。
以同样的方式,确定第三时长T3,其中,第三时长T3与2个固定时间T的差值小于0.5,认为空调接收到两个“0”,依次类推,确定第N个时长Tn与n个固定时间T的差值小于0.5,认为空调接收到一个“0”。
实施例六
在本申请的一个实施例中,如图5所示,提出了一种空调通信的控制装置500,其中,空调通信的控制装置500包括:获取单元502、确定单元504以及输出单元506,其中,空调与总线连接,并通过总线进行数据通信。其中,获取单元502,用于获取总线上的电压信号;确定单元504,用于在电压信号符合空调的供电电压以总线上的基准电压的比对条件的情况下,确定电压信号中的电压上升沿斜率以及电压下降沿斜率;在电压上升沿斜率和电压下降沿斜率符合斜率比对条件的情况下,对电压信号进行时间对比,得到处理后的电压信号;以及确定数据模型库中与处理后的电压信号一致的目标数据模型;输出单元506,用于输出目标数据模型对应的数据信息。
本申请的实施例提出了一种空调通信的控制装置500,其具体包括获取单元502、确定单元504以及输出单元506。其中,通过对总线中的电压信号进行检测,以得到总线中的电压信号所对应的数据模型,并将该数据模型与存储的数据模型库中的模型进行比对,在比对一致的情况下,输出比对一致的数据模型中的数据信息(即本申请中的目标数据模型中的数据信息)。
具体地,通过对获取总线上采集的电压信息进行电压比对,电压上升沿斜率、电压下降沿斜率的斜率比对实现了对电压数据的筛选,并通过时间对比的方式实现了对采集得到的数据的信号还原,在此过程中,采用模型对比的方式对总线上的电压信号进行识别,减少了因空调以及其他通信 系统中的电感、电容、电阻以及信号反射等受到干扰时,导致的检测得到的信号数据异常。
在其中一个实施例中,数据模型库存储有数据模型。
通常情况下,通信协议中的一帧数据包括十几到几十个字节,其中,每个字节有10位数据,一般来说,一个字节包括起始位“0”和终止位“1”以及位于起始位“0”和终止位“1”之间的8位数据,而这8位数据是用于传输数据,基于此,数据模型库中的数据模型是根据10位数据建立的数据模型,在每位数据可以是“1”,也可以是“0”的情况下,需要构建28=256个数据模型,并将其进行保存,举例来说,“1111111100”为一个通信数据模型,用十六进制表示为一个字节“FE”,其中第一个“0”为起始位,最后一个“1”为终止位,再比如“1101010100”十六进制表示为一个字节“aa”。通过构建上述数据模型,以便在得到处理后的电压信号时,可以将其与数据模型库中的数据模型进行比对,进而得到如“FE”或“aa”的数据信息。
考虑到数据模型需要占据较大的存储空间,同时,模型对比也需要较大的数据处理量,可以将8为数据划分成4+4两个部分,即前4位数据作为一个模型进行保存,后4位数据作为一个数据进行保存,此时,前4位数据仅需要24=16个模型就可以完全表示,同理,后4位也需要16个模型来进行表示,在这种情况下,数据模型库中的模型仅需32个。在这种方案中,可以有效降低了模型的存储空间以及需要模型比对的数据量。
实施例七
在该实施例中,具体限定了判断电压信号是否满足空调的供电电压以及总线上的基准电压的比对条件的内容。
通常情况下,空调会通过一个通信芯片与总线连接,以实现总线上的信号的获取,而该芯片在使用时,芯片所采集的采样电压值会小于其供电电压,为了减少因总线上的电压信号对应的电压值过高,如超过其供电电压,致使空调无法对其进行采集以及还原这种情况的出现,本申请的实施例中,在进行电压比对时,确定单元504具体用于限定任一采样电压值不超过供电电压,以便可以准确地对总线上的电压信号进行矫正,降低输出 错误信号的几率。
此外,由于本申请的实施例需要进一步判断对电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件,若采集得到的电压信号所对应的电压值过低,则会对还原的精度产生影响,更有甚者,致使信号无法矫正。
为了解决上述问题,确定单元504具体用于限定了任一采样电压值与基准电压之间的差值要足够大,如大于预设阈值,以确保才采样电压值足够大,进而确保了还原的精度。
在上述任一实施例中,预设阈值可以根据实际需要进行设定,举例来说,在通信芯片的供电电压为3.3伏特时,预设阈值的取值可以是0.5伏特,此时基准电压不能超过2.5伏特。
在上述任一实施例中,若电压信号不满足空调的供电电压、总线上的基准电压的比对条件时,输出错误数据模型,以提醒用户进行处理。
实施例八
在该实施例中,具体限定了判断电压上升沿斜率和电压下降沿斜率是否满足斜率比对条件的内容。
具体地,确定单元504用于:取电压上升沿斜率的幅值,记作第一幅值;取电压下降沿斜率的幅值,记作第二幅值;计算第一幅值和第二幅值的比值;若该比值处于0.5至2之间,认为电压上升沿斜率和电压下降沿斜率符合斜率比对条件。
通过将确定的第一幅值和第二幅值进行比较,以便确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,对于差异较大的情况,认为电压信号不满足斜率比对条件,此时,输出错误数据模型,以提醒用户进行处理。
具体地,为了便于对电压信号是否满足斜率比对条件进行量化处理,本申请的实施例通过比较斜率的幅值的大小关系来确定电压上升沿的波形和电压下降沿的波形是否存在较大差异,具体地,在第一幅值和第二幅值之间相差不超过一半的情况下,认为电压上升沿的波形和电压下降沿的波形之间的差异较小,即满足斜率比对条件,考虑到第一幅值可以大于第二幅值,也可以小于第二幅值,若单独划分比较情况,则需要处理的数据较 多。
为了减少数据处理的量,本申请的实施例通过确定第一幅值与第二幅值之间的比值的波动范围来量化第一幅值和第二幅值之间相差不超过一半这一判断条件,具体地,该比值需要大于0.5、且小于2,在此过程中,在对电压上升沿的波形和电压下降沿的波形之间的差异的过程中,仅需判断该比值是否大于0.5且小于2即可实现该差异的判定,降低了比对难度。
实施例九
在该实施例中,确定单元504具体用于确定电压上升沿斜率以及电压下降沿斜率,具体地,在总线的采样电压值大于基准电压的情况下,记录第一电压值;在总线的采样电压值大于基准电压、且持续时长大于或等于第一预设时长,记录第二电压值;以及计算第二电压值与第一电压值的比值,并将该比值作为电压上升沿斜率。
对于电压下升沿斜率,查找以总线的采样电压值为最大电压值所对应的时刻作为开始时刻,第一预设时长后记录的采样电压值为第三电压值;计算最大电压值与第三电压值的比值,并将该比值作为电压下降沿斜率。
在该实施例中,通常情况下,空调是周期性在总线上采集数据,若在采集得到的电压值并确定的电压差值之后,将计算其与电压差值所对应的时间的比值,以得到对应的斜率,考虑到本申请的实施例是通过比较第一幅值与第二幅值之间的比值大小来确定是否满足斜率比对条件,在电压差值所对应的时间是相同的情况下,可以将第二电压值和第一电压值的比值看作电压上升沿斜率,同理,将最大电压值和第三电压值的比值看作电压下降沿斜率,以此来降低空调所需要处理的数据量。
具体地,如图7所示,基准电压为U0,在采样电压值大于基准电压U0时,记录第一电压值U1,在第一预设时长t后,记录第二电压值U2,采样电压值为最大电压值U3,在最大电压值U3的第一预设时长t后,记录第三电压值U4,计算U2与U1的比值,记作λ1,计算U3与U4的比值,记作λ2,基于λ1与λ2相差不超过一半,认为符合斜率比对条件。
在其中一个实例中,如图8所示,具体地,基准电压为U0,在采样电压值大于基准电压U0时,记录第一电压值U1,在t/2后,即第一预设时 长t的一半后,记录第四电压值U1-2,再经过t/2后,即第一预设时长t的一半后,记录第二电压值U2,采样电压值为最大电压值U3,在最大电压值U3后t/2时,即第一预设时长t的一半后,记录第五电压值U3-2,再经过t/2后,即第一预设时长t的一半后,记录第三电压值U3,计算U1-2与U1的比值,记作μ1,计算U2与U1-2的比值,记作μ3,计算U3与U3-2的比值,记作μ3,计算U3-2与U4的比值,记作μ4,若μ1与μ4相差不超过一半,且μ2与μ3相差不超过一半认为符合斜率比对条件。
实施例十
在该实施例中,确定单元504具体用于限定了如何对电压信号进行时间对比,并得到处理后的电压信号的内容。
二进制数据是机器能够识别到的机器语言,即数据“1”和数据“0”,在本申请的实施例中,二进制数据中的第一个数码可以是数据“1”和数据“0”中的任意一个,对应的二进制数据中的第二个数码是除第一个数码的另一个数码,如在一种情况下,在第一个数码是数据“1”时,第二个数码是数据“0”,在另一种情况下在第一个数码是数据“0”时,第二个数码是数据“1”,在本申请的实施例中,选取第一个数码是数据“0”时,第二个数码是数据“1”。
具体地,确定单元504用于:以采样电压值大于基准电压所对应的时刻作为计时开始时刻,记录第二预设时长后的第一时刻;以总线的采样电压值为最大电压值所对应的时刻作为开始计时时刻,记录第二预设时长后的第二时刻;确定第一时刻和第二时刻之间的第一时长;根据第一时长与第一个数码对应的时长确定第一个数码的个数;以总线的采样电压值再次大于基准电压所对应的时刻作为开始计时时刻,记录第二预设时长后的第三时刻;确定第三时刻和第二时刻之间的第二时长;根据第二时长与第二个数码对应的时长确定第二个数码的个数;根据第一个数码的个数、第二个数码的个数、第一个数码和第二个数码确定处理后的电压信号。
通常情况下,确定总线上电压信号的方式是根据总线上高电平的持续时间或低电平的持续时间来确定二进制数据中的第一个数码和第二个数码的个数,由于总线上存在信号干扰,空调采集得到的电压波动较大,精度 较低。
为了解决上述问题,本申请的实施例采用时间对比的方式来确定二进制数据中的第一个数码和第二个数码的个数,并根据第一个数码的个数和第二个数码的个数对电压信号进行数据还原,在此过程中,减少了上述情况对读取信号的影响,确保了信号的可信度。
在上述任一实施例中,在第一时长与M个第一个数码对应的时长的差值小于或等于设定值,确定第一时长对应M个连续的第一个数码;在第二时长与N个第二个数码对应的时长的差值小于或等于设定值,确定第二时长对应N个连续的第二个数码,其中,M,N为自然数。
在该实施例中,考虑到由于总线过长、或与总线连接的电容或者如与总线连接的采样电阻的影响,总线上的电压信号的长度会发生变化,为了消除该影响,给出第一时长与M个第一个数码对应的时长之间的波动区间,具体地,通过计算第一时长与M个第一个数码对应的时长的差值,并将该差值与设定值进行比较,以便判断该波动区间是否超出设定值。若不超过设定值时,认定第一时长对应M个连续的第一个数码,其中,可以理解的是,即第一时刻至第二时刻之间的电压信号对应M个连续的第一个数码,同理,第二时刻至第三时刻之间的电压信号对应N个连续的第二个数码,在上述过程中,实现了对采集得到的电压信号的还原,以便得到处理后的电压信号。
在上述任一实施例中,空调通信的控制方法还包括:获取空调的波特率和总线上的实际通信时间;以及根据波特率和实际通信时间确定第一个数码对应的时长以及第二个数码对应的时长。
在该实施例中,考虑到空调进行通信的波特率不同,第一个数码对应的时长以及第二个数码对应的时长也会不同,为了确保目标数据模型的准确性,需要对第一个数码对应的时长以及第二个数码对应的时长进行标定,根据空调的波特率以及总线上的实际通信时间来确定第一个数码对应的时长以及第二个数码对应的时长。
在上述任一实施例中,实际通信时间即总线上的理论通信时间与第一等待时间、第二等待时间的差值,其中,理论通信时间可以理解为在总线 上的电压值大于或等于基准电压的时长,第一等待时长为总线上的电压值大于基准电压的时长为第一等待时间之后,才开始进行获取总线上的采样电压值,同理,第二等待时间为不进行采样的时间,其对应理论通信时间的尾部。
在其中一个实施例中,第一等待时间、第二等待时间属于不对总线上的电压信号进行采样的时间,其具体数值可以预先进行设定。
举例来说,如图9所示,在波特率以及实际通信时间确定下来的情况下,第一个数码以及第二个数码的时长也确定下来了,即单个bit的时间也固定下来了。
在第一时长T1确定下来之后,计算第一时长T1与固定时间T的差值,并将该差值与设定值进行比较,其中,设定值可以取值0.5,如第一时长T1与固定时间T的差值小于0.5,认为固定时间T与第一时长T1相等,认为空调接收到一个“0”,同理,第二时长T2与固定时间T的差值,小于0.5,认为固定时间T与第二时长T2相等,认为空调接收到一个“1”。
以同样的方式,确定第三时长T3,其中,第三时长T3与2个固定时间T的差值小于0.5,认为空调接收到两个“0”,依次类推,确定第N个时长Tn与n个固定时间T的差值小于0.5,认为空调接收到一个“0”。
实施例十一
在本申请的一个实施例中,如图6所示,提出了一种通信系统600,其包括处理器604,存储器602及存储在存储器602上并可在处理器604上运行的程序或指令,程序或指令被处理器604执行时实现如第一方面中任一项的空调通信的控制方法的步骤。
本申请的实施例提出了一种通信系统600,其中,该通信系统600包括存储器602以及处理器604,其中,处理器604执行存储在存储器602上的程序或指令实现如第一方面中任一项空调通信的控制方法的步骤,故通信系统600具有上述任一项的空调通信的控制方法的全部有益技术效果。
在该实施例中,通信系统600通过设置的通信芯片执行本申请的上述方法,具体地,建立通信数据模型,从斜率,电压,时间三个维度进行比 对,比对成功后输出数据模型中的正确通信数据,解决因为干扰,线缆等外界因素影响,导致通信信号错误,提高通信的稳定性。
实施例十二
在本申请的一个实施例中,提出了一种可读存储介质,其中,可读存储介质上存储程序或指令,程序或指令被处理器执行时实现如第一方面中任一项的空调通信的控制方法的步骤。
本申请的实施例提出了一种可读存储介质,其中,该可读存储介质上存储的程序或指令被执行时实现如第一方面中任一项空调通信的控制方法的步骤,故可读存储介质具有上述任一项的空调通信的控制方法的全部有益技术效果。
在本申请的描述中,术语“多个”则指两个或两个以上,除非另有明确的限定,术语“上”、“下”等指示的方位或位置关系为基于附图所示的方位或位置关系,仅是为了便于描述本申请和简化描述,而不是指示或暗示所指的装置或元件必须具有特定的方位、以特定的方位构造和操作,因此不能理解为对本申请的限制;术语“连接”、“安装”、“固定”等均应做广义理解,例如,“连接”可以是固定连接,也可以是可拆卸连接,或一体地连接;可以是直接相连,也可以通过中间媒介间接相连。对于本领域的普通技术人员而言,可以根据具体情况理解上述术语在本申请中的具体含义。
在本申请的描述中,术语“一个实施例”、“一些实施例”、“具体实施例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或特点包含于本申请的至少一个实施例或示例中。在本申请中,对上述术语的示意性表述不一定指的是相同的实施例或实例。而且,描述的具体特征、结构、材料或特点可以在任何的一个或多个实施例或示例中以合适的方式结合。
以上仅为本申请的优选实施例而已,并不用于限制本申请,对于本领域的技术人员来说,本申请可以有各种更改和变化。凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。

Claims (10)

  1. 一种空调通信的控制方法,其中,所述空调与总线连接,所述空调通信的控制方法包括:
    获取所述总线的电压信号;
    基于所述电压信号满足所述空调的供电电压和所述总线上的基准电压的比对条件,确定所述电压信号中的电压上升沿斜率以及电压下降沿斜率;
    基于所述电压上升沿斜率和所述电压下降沿斜率满足斜率比对条件,对所述电压信号进行时间比对,得到处理后的电压信号;
    确定数据模型库中与处理后的电压信号一致的目标数据模型;
    输出所述目标数据模型对应的数据信息。
  2. 根据权利要求1所述的空调通信的控制方法,其中,
    基于所述电压信号中任一采样电压值小于或等于所述空调的供电电压,且与所述基准电压的差值大于预设阈值,确定所述电压信号满足所述空调的供电电压、所述总线上的基准电压的比对条件。
  3. 根据权利要求1所述的空调通信的控制方法,其中,
    确定所述电压上升沿斜率所对应的第一幅值和所述电压下降沿斜率对应的第二幅值;
    基于所述第一幅值与所述第二幅值之间的比值大于0.5、且小于2,确定所述电压上升沿斜率和所述电压下降沿斜率满足斜率比对条件。
  4. 根据权利要求1所述的空调通信的控制方法,其中,所述确定所述电压信号中的电压上升沿斜率以及电压下降沿斜率的步骤,具体包括:
    基于所述总线的采样电压值大于所述基准电压,记录所述采样电压值为第一电压值;
    基于所述总线的采样电压值大于所述基准电压的持续时长大于或等于第一预设时长,记录所述采样电压值为第二电压值;
    将所述第二电压值与所述第一电压值的比值作为所述电压上升沿斜率;
    查找以所述总线的采样电压值为最大电压值作为开始时刻,所述第一 预设时长后记录的所述采样电压值为第三电压值;
    将所述最大电压值与所述第三电压值的比值作为所述电压下降沿斜率。
  5. 根据权利要求1至4中任一项所述的空调通信的控制方法,其中,所述对所述电压信号进行时间比对,得到处理后的电压信号的步骤,具体包括:
    确定以所述总线的采样电压值大于所述基准电压所对应的时刻作为开始时刻,第二预设时长后的第一时刻;
    确定以所述总线的采样电压值为最大电压值对应的时刻作为开始时刻,所述第二预设时长后的第二时刻;
    根据所述第一时刻和所述第二时刻确定第一时长;
    根据所述第一时长与二进制数据中的第一个数码对应的时长确定所述第一时长代表的第一个数码的个数;
    确定以所述总线的采样电压值再次大于所述基准电压所对应的时刻作为开始时刻,所述第二预设时长后的第三时刻;
    根据所述第三时刻和所述第二时刻确定第二时长;
    根据所述第二时长与二进制数据中的第二个数码对应的时长确定所述第二时长代表的第二个数码的个数;
    根据所述第一个数码的个数、所述第二个数码的个数、所述第一个数码和所述第二个数码确定处理后的电压信号。
  6. 根据权利要求5所述的空调通信的控制方法,其中,还包括:
    基于所述第一时长与M个所述第一个数码对应的时长的差值小于或等于设定值,确定所述第一时长对应M个连续的所述第一个数码;
    基于所述第二时长与N个所述第二个数码对应的时长的差值小于或等于设定值,确定所述第二时长对应N个连续的所述第二个数码,
    其中,M,N为自然数。
  7. 根据权利要求5所述的空调通信的控制方法,其中,还包括:
    获取所述空调的波特率以及所述总线上的实际通信时间;
    根据所述波特率和所述实际通信时间确定所述第一个数码对应的时长 以及所述第二个数码对应的时长。
  8. 一种空调通信的控制装置,其中,所述空调与总线连接,所述空调通信的控制装置包括:
    获取单元,用于获取所述总线的电压信号;
    确定单元,用于基于所述电压信号满足所述空调通信的供电电压和所述总线上的基准电压的比对条件,确定所述电压信号中的电压上升沿斜率以及电压下降沿斜率;
    基于所述电压上升沿斜率和所述电压下降沿斜率满足斜率比对条件,对所述电压信号进行时间比对,得到处理后的电压信号;
    确定数据模型库中与处理后的电压信号一致的目标数据模型;
    输出单元,用于输出所述目标数据模型对应的数据信息。
  9. 一种通信系统,其中,包括:处理器,存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如权利要求1至7中任一项所述的空调通信的控制方法的步骤。
  10. 一种可读存储介质,其中,所述可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如权利要求1至7中任一项所述的空调通信的控制方法的步骤。
PCT/CN2021/117574 2020-12-09 2021-09-10 空调通信的控制方法、装置、通信系统和可读存储介质 WO2022121409A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21902117.7A EP4134831A4 (en) 2020-12-09 2021-09-10 METHOD AND APPARATUS FOR COMMUNICATION CONTROL FOR AN AIR CONDITIONER, AND COMMUNICATION SYSTEM AND READABLE STORAGE MEDIUM
US17/922,971 US20230160600A1 (en) 2020-12-09 2021-09-10 Communication control method and apparatus for air conditioner, and communication system and readable storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011433039.4 2020-12-09
CN202011433039.4A CN112559417B (zh) 2020-12-09 2020-12-09 空调通信的控制方法、装置、通信系统和可读存储介质

Publications (1)

Publication Number Publication Date
WO2022121409A1 true WO2022121409A1 (zh) 2022-06-16

Family

ID=75060129

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/117574 WO2022121409A1 (zh) 2020-12-09 2021-09-10 空调通信的控制方法、装置、通信系统和可读存储介质

Country Status (4)

Country Link
US (1) US20230160600A1 (zh)
EP (1) EP4134831A4 (zh)
CN (1) CN112559417B (zh)
WO (1) WO2022121409A1 (zh)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112559417B (zh) * 2020-12-09 2023-04-25 广东美的暖通设备有限公司 空调通信的控制方法、装置、通信系统和可读存储介质
CN114963409B (zh) * 2022-06-15 2024-06-11 合肥美的暖通设备有限公司 通信供电电路、控制方法、装置、存储介质和空调设备
CN118091224B (zh) * 2024-02-05 2024-10-01 青岛飞奕科技有限公司 一种空调品牌辨识电路及辨识方法

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108063640A (zh) * 2017-11-13 2018-05-22 广东欧珀移动通信有限公司 抗mipi总线干扰的方法及系统、装置及计算机可读存储介质
CN109063652A (zh) * 2018-08-06 2018-12-21 高维度(深圳)生物信息智能应用有限公司 一种信号处理方法、系统及计算机存储介质
WO2019002027A1 (en) * 2017-06-28 2019-01-03 Philips Lighting Holding B.V. SYSTEM AND METHOD FOR VOLTAGE DETECTION
CN109889419A (zh) * 2019-02-26 2019-06-14 北京强联通讯技术有限公司 总线供电及通讯方法、装置及存储介质
CN111412580A (zh) * 2020-03-30 2020-07-14 美的集团股份有限公司 波特率校准方法、空调器及计算机可读存储介质
CN112559417A (zh) * 2020-12-09 2021-03-26 广东美的暖通设备有限公司 空调通信的控制方法、装置、通信系统和可读存储介质

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103250339B (zh) * 2010-12-07 2015-11-25 日立汽车系统株式会社 电力变换装置
KR20210145306A (ko) * 2016-05-13 2021-12-01 메르크 파텐트 게엠베하 용융 압출 적용을 위한 중합체의 입자 크기 및 분포
EP3535625B1 (en) * 2016-12-07 2021-02-24 Arilou Information Security Technologies Ltd. System and method for using signal waveform analysis for detecting a change in a wired network
GB201710674D0 (en) * 2017-07-03 2017-08-16 Centrica Connected Home Ltd Method of utility usage analysis
CN109147643B (zh) * 2018-10-08 2020-12-22 惠科股份有限公司 上升/下降沿的鉴别方法、装置、显示面板及存储介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019002027A1 (en) * 2017-06-28 2019-01-03 Philips Lighting Holding B.V. SYSTEM AND METHOD FOR VOLTAGE DETECTION
CN108063640A (zh) * 2017-11-13 2018-05-22 广东欧珀移动通信有限公司 抗mipi总线干扰的方法及系统、装置及计算机可读存储介质
CN109063652A (zh) * 2018-08-06 2018-12-21 高维度(深圳)生物信息智能应用有限公司 一种信号处理方法、系统及计算机存储介质
CN109889419A (zh) * 2019-02-26 2019-06-14 北京强联通讯技术有限公司 总线供电及通讯方法、装置及存储介质
CN111412580A (zh) * 2020-03-30 2020-07-14 美的集团股份有限公司 波特率校准方法、空调器及计算机可读存储介质
CN112559417A (zh) * 2020-12-09 2021-03-26 广东美的暖通设备有限公司 空调通信的控制方法、装置、通信系统和可读存储介质

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4134831A4

Also Published As

Publication number Publication date
EP4134831A1 (en) 2023-02-15
EP4134831A4 (en) 2023-11-22
CN112559417A (zh) 2021-03-26
US20230160600A1 (en) 2023-05-25
CN112559417B (zh) 2023-04-25

Similar Documents

Publication Publication Date Title
WO2022121409A1 (zh) 空调通信的控制方法、装置、通信系统和可读存储介质
WO2020253175A1 (zh) 一种甲醛浓度检测方法、装置及空气净化器
CN203909605U (zh) 过程控制系统
CN112798963A (zh) 基于时间序列的电池充电特性异常检测方法、装置及介质
CN104361374A (zh) 一种射频信号的采集与处理系统及其方法
US6366081B1 (en) Method and apparatus for high throughput media defect testing using true reference value
WO2006131021A1 (en) Error detection and prevention in acoustic data
CN110704257A (zh) 固态硬盘及其质量监测方法、装置和计算机可读存储介质
CN102222211B (zh) 一种磁卡解码方法及磁卡读取装置
CN106847232A (zh) 一种钢琴调音仪器
US9992045B2 (en) On-line signal event detection and identification method and apparatus
CN110702972B (zh) 一种模拟信号自适应采样方法及装置
CN204389097U (zh) 一种基于rfid物联网技术的压力仪表
CN114726892B (zh) 基于人工智能大数据的边缘数据收集方法
US11558533B2 (en) Method of reading data and data-reading device
CN108574565A (zh) 一种s模式发射机信号质量检测装置及方法
CN114741377B (zh) 识别天然气异常数据并对其处理的方法和装置
CN108614798B (zh) PCIe链路弹性缓冲区电路
CN106201759B (zh) 一种防止fpga寄存器粘连的检测系统及方法
JP2856939B2 (ja) データ受信方法
CN111355624B (zh) 一种自适应的设备性能采集方法及装置
CN118381867B (zh) 解串器、串行器及车载视频数据传输系统、方法、介质
JP3684821B2 (ja) 記録媒体ドライバのシミュレータ装置
CN101498742A (zh) 信号自动判断方法与时序差异自动量测方法
US20020093364A1 (en) Apparatus and method for extracting data values from a signal encoded with AES3 data

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21902117

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2021902117

Country of ref document: EP

Effective date: 20221111

NENP Non-entry into the national phase

Ref country code: DE