Summary of the invention
Present invention mainly solves the technical issues of one of be to provide it is a kind of based on more air-conditioning single wire control methods, should be based on more
Air-conditioning single wire control method can mention to avoid the waste for both having influenced applicability and microcontroller resource that it is used when bilinear con- trol
The safety and reliability of height communication.
To solve the above-mentioned problems, the present invention also provides another kinds to be based on more air-conditioning single wire control methods, should be based on mostly empty
Single wire control method is adjusted, multiple air-conditioner controllers are controlled by master control equipment, including master control equipment is to any one sky
Controller operating steps are adjusted, which includes to any one air-conditioner controller operating steps, single total under idle state
Line is high level, and master control equipment sends guidance code to monobus, all air-conditioner controllers for receiving low level guidance code into
Enter first state, which refers to air-conditioner controller in an idle state, receives the guidance code of master control equipment sending
The state entered afterwards;
Master control equipment, which encodes to send to air-conditioner controller with the first, manipulates specified air-conditioner controller inquiry code, air-conditioning control
After device processed receives inquiry code, the second state is entered when air-conditioner controller is currently first state, master control equipment is with the second coding
Air-conditioner controller number is sent to air-conditioner controller, if there is an air-conditioner controller to be in the second state, and the equipment that air-conditioning receives
Number identical with the device number of itself, air-conditioner controller passes the current status information of the device number of itself and equipment with the second coding
To master control equipment, when master control equipment receives the information of air-conditioner controller and information is in correct range within a preset time,
Master control equipment updates air-conditioner controller information, wherein the second state refers to that air-conditioner controller in first state, receives
Master control equipment issues the state entered after inquiry code with the first coding.
It further says, further includes that operating steps are carried out to an air-conditioner controller, which includes,
Under idle state, bus is high level, sends guidance code from master control equipment to monobus, all to receive guidance
The air-conditioner controller of code enters first state;Master control equipment sends the manipulation of one air-conditioner controller of manipulation with the first coding
Code;
After air-conditioner controller receives manipulation code, third shape is entered when air-conditioner controller current state is in first state
State, the third state refer to that air-conditioner controller in first state, is received master control equipment and issued with the first coding to certain
The state entered after the manipulation code of one air-conditioner controller;
Master control equipment encodes device number to the transmission air-conditioning of air-conditioner controller with second, when having at an air-conditioner controller
In the third state, and the device number received is identical as the device number of itself, and air-conditioner controller is by the device number of itself, with second
Response is encoded to master control equipment, air-conditioner controller enters the 4th state, and the 4th state refers to air-conditioner controller in the
Three condition receives master control equipment with the second coding and issues device number, if the device number and air-conditioner controller that issue are set
Standby number enters state when identical.
In correct range, master control equipment transmission is encoded the information that master control equipment receives within the set time with third
Data are sent to air-conditioner controller, when there is an air-conditioner controller be in the 4th state, and receiving the information that third encodes is just
Really, after air-conditioner controller updates the data received, the device number of itself and equipment current state are transmitted to master with third coding
Control equipment.
It further says, further includes that operating steps are carried out to all air-conditioner controllers, which includes:
Under idle state, bus is high level, and master control equipment sends guidance code;
Master control equipment encodes to air-conditioner controller with first and sends the manipulation code manipulated to all air-conditionings;
Master control equipment encodes to air-conditioner controller with second and sends the device number manipulated to all air-conditionings;
Master control equipment is encoded to air-conditioner controller with third and sends information.
It further says, it includes opening that the master control equipment, which sends and sends data to air-conditioner controller with third coding mode,
Off status, mode, wind speed, set temperature and check code.
It further says, the guidance code is 20ms low level.
Further say, it is described first coding 0 and 1 representation method data 0 with 0.5ms high level+0.5ms low level=
1ms indicates that data 1 are indicated with high level 0.5ms+ low level 1.5ms=2ms.
It further says, 0 and 1 representation method data 0 1ms high level+1ms low level=2ms of second coding
It indicates, data 1 are indicated with high level 1ms+ low level 3ms=4ms.
Further say, the 0 and 1 representation method data 0 use 1.5ms high level+1.5ms low level that the third encodes=
3ms indicates that data 1 are indicated with high level 1.5ms+ low level 4.5ms=6ms.
The present invention is based on more air-conditioning single wire control methods, including master control equipment to manipulate and walk to any one air-conditioner controller
Suddenly, which includes that under idle state, monobus is high level to any one air-conditioner controller operating steps, main
It controls equipment and sends guidance code to monobus, all air-conditioner controllers for receiving low level guidance code enter first state, should
First state refers to air-conditioner controller in an idle state, receives the state entered after the guidance code of master control equipment sending;
Master control equipment, which encodes to send to air-conditioner controller with the first, manipulates specified air-conditioner controller inquiry code, and air-conditioner controller receives
After inquiry code, the second state is entered when air-conditioner controller is currently first state, master control equipment is encoded with second to air-conditioning control
Device processed sends air-conditioner controller number, if there is an air-conditioner controller to be in the second state, and the device number that receives of air-conditioning and itself
Device number it is identical, air-conditioner controller by the current status information of the device number of itself and equipment with second coding be transmitted to main control
Equipment, when master control equipment receives the information of air-conditioner controller and information is in correct range within a preset time, master control is set up
It is standby to update air-conditioner controller information, wherein the second state refers to that air-conditioner controller in first state, receives master control and sets up
It is standby that the state entered after inquiry code is issued with the first coding.The only communication state locating for the air-conditioner controller, the volume received
Code is synchronous, and carries out next step communication when the data and air-conditioning received itself matching, avoid the occurrence of malfunction.It keeps away simultaneously
Exempt from the waste to microcontroller resource, improves the safety and reliability of applicability, communication.
Specific embodiment
In order to keep the purposes, technical schemes and advantages to be invented clearer, below in conjunction in the embodiment of the present invention
Attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is invention
A part of the embodiment, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art are not having
Every other embodiment obtained under the premise of creative work is made, shall fall within the protection scope of the present invention.
As depicted in figs. 1 and 2, the present invention provides a kind of based on more air-conditioning single wire control communication system embodiments.
More air-conditioning single wire control methods should be based on, multiple air-conditioner controllers were controlled by master control equipment, comprising:
Step S10, status inquiry step of the master control equipment to an air-conditioner controller;
Step S11, master control equipment is to any one air-conditioner controller operating steps.
Specifically, the step S10, master control equipment include to any one air-conditioner controller query steps, it is idle
Under state, monobus is high level, and master control equipment sends guidance code, all skies for receiving low level guidance code to monobus
Controller is adjusted to enter first state, which refers to air-conditioner controller in an idle state, receives master control equipment hair
The state entered after guidance code out;
Master control equipment, which encodes to send to air-conditioner controller with the first, manipulates specified air-conditioner controller inquiry code, air-conditioning control
After device processed receives inquiry code, the second state is entered when air-conditioner controller is currently first state, master control equipment is with the second coding
Air-conditioner controller number is sent to air-conditioner controller, if there is an air-conditioner controller to be in the second state, and the equipment that air-conditioning receives
Number identical with the device number of itself, air-conditioner controller passes the current status information of the device number of itself and equipment with the second coding
To master control equipment, when master control equipment receives the information of air-conditioner controller and information is in correct range within a preset time,
Master control equipment updates air-conditioner controller information, wherein the second state refers to that air-conditioner controller in first state, receives
Master control equipment issues the state entered after inquiry code with the first coding.
Step S11 carries out operating steps to an air-conditioner controller, which includes:
Under idle state, bus is high level, sends guidance code from master control equipment to monobus, all to receive guidance
The air-conditioner controller of code enters first state;Master control equipment sends the manipulation of one air-conditioner controller of manipulation with the first coding
Code;
After air-conditioner controller receives manipulation code, third shape is entered when air-conditioner controller current state is in first state
State, the third state refer to that air-conditioner controller in first state, is received master control equipment and issued with the first coding to certain
The state entered after the manipulation code of one air-conditioner controller;
Master control equipment encodes device number to the transmission air-conditioning of air-conditioner controller with second, when having at an air-conditioner controller
In the third state, and the device number received is identical as the device number of itself, and air-conditioner controller is by the device number of itself, with second
Response is encoded to master control equipment, air-conditioner controller enters the 4th state, and the 4th state refers to air-conditioner controller in the
Three condition receives master control equipment with the second coding and issues device number, if the device number and air-conditioner controller that issue are set
Standby number enters state when identical.
In correct range, master control equipment transmission is encoded the information that master control equipment receives within the set time with third
Data are sent to air-conditioner controller, when there is an air-conditioner controller be in the 4th state, and receiving the information that third encodes is just
Really, after air-conditioner controller updates the data received, the device number of itself and equipment current state are transmitted to master with third coding
Control equipment.
In the above-described embodiments, the master control equipment, which is sent, sends data to air-conditioner controller with third coding mode
Including switch state, mode, wind speed, set temperature and check code.The guidance code is 20ms low level.First coding
0 and 1 representation method data 0 indicate with 0.5ms high level+0.5ms low level=1ms, the low electricity of high level 0.5ms+ of data 1
Flat 1.5ms=2ms is indicated.0 and 1 representation method data 0 1ms high level+1ms low level=2ms table of second coding
Show, data 1 are indicated with high level 1ms+ low level 3ms=4ms.0 and 1 representation method data 0 of the third coding are used
1.5ms high level+1.5ms low level=3ms indicates that data 1 are indicated with high level 1.5ms+ low level 4.5ms=6ms.
As only working as communication state locating for an air-conditioner controller, the code synchronism received, and the data received
Next step communication is carried out when with air-conditioning itself matching, avoids the occurrence of malfunction.It avoids providing microcontroller when bilinear con- trol simultaneously
The waste in source improves the safety and reliability of applicability, communication.
In the above-described embodiments, it is described based on more air-conditioning single wire control methods further include that all air-conditioner controllers are grasped
Step is controlled, which includes:
Under idle state, bus is high level, and master control equipment sends guidance code;
Master control equipment encodes to air-conditioner controller with first and sends the manipulation code manipulated to all air-conditionings;
Master control equipment encodes to air-conditioner controller with second and sends the device number manipulated to all air-conditionings;
Master control equipment is encoded to air-conditioner controller with third and sends information.
Described pair of all air-conditioner controllers carry out operating steps, set up to air-conditioner controller progress operating steps and master control
It is standby there is no an association in timing to the status inquiry step of an air-conditioner controller, i.e., any one step all disobey be against it is another
The implementation of step.
In order to be best understood from technical solution of the present invention, the principle of the present invention, method are described below by example.Lower example institute
Principle, the method, apparatus of narration can be generalized to different parameter and use-case.All possible parameter and use-case are in this hair
Within the scope of bright.
Communication of the main equipment to air-conditioning has following three kinds of situations:
1. main equipment is to a certain device status inquiries step
Under 1.1 idle states, bus is high level;Master control equipment sends the low level guidance code of 20ms.
1.2 all equipment for receiving guidance code enter ready for receiving first state;
After 1.3 20ms, main equipment transmission sends downwards byte Byte [0]=0x01 inquiry code in a manner of A code.
After 1.4 air-conditioner controllers receive Byte [0]=0x01 inquiry code, if current state is in first state, that
Enter the second state;
After 1.5 20ms, main equipment sends the device number Byte [1] of the downward target air-conditioning in a manner of B code;
If 1.6 certain air-conditioner controller are in state 2, and the device number Byte [1] that receives of air-conditioning and the equipment of itself
Number
It is identical, the air-conditioning switch that the device number of itself and equipment is current, mode, wind speed, set temperature, current temperature
Degree, check code are transmitted to main equipment in a manner of B code.
If the message that 1.7 main equipments receive in 2S, in correct range, main equipment updates air-conditioner controller information,
Communication terminates;If the time is more than 2S, or the data received are incorrect, repeat more than step;If continuous 3 mistakes
It loses, it is believed that equipment is out of order then, stops to the equipment query.
2. pair a certain equipment carries out operating steps:
Under 2.1 idle states, bus is high level;Master control equipment sends the low level guidance code of 20ms.
2.2 all equipment for receiving guidance code enter ready for receiving first state;
After 2.3 20ms, main equipment transmission sends downwards byte Byte [0]=0x02 override code in a manner of A code.
After 2.4 air-conditioner controllers receive Byte [0]=0x02 inquiry code, if current state is in first state,
Into the third state;
After 2.5 20ms, main equipment sends the device number Byte [1] of the downward target air-conditioning in a manner of B code;
If 2.6 certain air-conditioning are in state 2, and the device number Byte [1] that receives of air-conditioning and the device number phase of itself
Together, air-conditioning is by the device number of itself, and response enters the 4th state to main equipment, air-conditioner controller in a manner of B code;
If the message that 2.7 main equipments receive in 2S enters step 2.8 in correct range;If the time is more than 2S, or
The data that person receives are incorrect, 2.1 steps repeated, if continuous 3 failures, it is believed that equipment is out of order then, stops grasping the equipment
Control.
2.8 main equipments, which are sent, sends 5 byte datas to air-conditioner controller in a manner of C code: including 4 bytes: switch shape
State, mode, wind speed, set temperature and a byte check code.
If 2.9 certain air-conditioning are in K4, and the data for receiving C code mode are, after air-conditioner controller has updated data,
By the current switch state of the device number of itself and equipment, mode, wind speed, set temperature, Current Temperatures and check code with C
Code mode is transmitted to main equipment.
If the message that 2.10 main equipments receive in 2S, in correct range, main equipment sets air-conditioning success, communication knot
Beam;If the time is more than 2S, or the data received are incorrect, 2.8 steps repeated, if continuous 3 failures, it is believed that equipment is out of order
Then, stop manipulating the equipment.
3. pair all air-conditioner controllers carry out operating steps:
Under 3.1 idle states, bus is high level;The main low level guidance code of transmission 20ms of master control equipment.
After 3.2 20ms, main equipment transmission sends downwards byte Byte [0]=0xff to having time in a manner of A code
The manipulation code of tune.
After 3.3 20ms, main equipment transmission sends downwards 5 byte datas in a manner of C code: including 4 bytes: switch shape
State, mode, wind speed, set temperature and a byte check code.
Described the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although referring to aforementioned reality
Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each
Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features, and these are modified
Or replacement, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution.