Summary of the invention
Present invention is primarily targeted at address distribution method and device that a kind of air-conditioning equipment is provided, it is intended to when solving to carry out communication between existing air-conditioning equipment, it is necessary to manually address is set for indoor set, causes unhandy problem.
For achieving the above object, the address distribution method of a kind of air-conditioning equipment provided by the invention, the address distribution method of described air-conditioning equipment comprises the following steps:
Off-premises station is at least one indoor set broadcast address roll-call instruction, wherein, and the default bit address in the physical address of the address correspondence indoor set in the roll-call instruction of described address;
Described off-premises station receives the data that at least one indoor set described returns according to the roll-call instruction of described address;
Described off-premises station judges that whether the data received are correct;
If so, then described off-premises station is to the indoor set distribution address returning just data, and the indoor set for described return just data arranges Self address according to the address of distribution.
Alternatively, described off-premises station also includes after judging the step whether described data of reception are correct:
If not, then described off-premises station broadcasts the address roll-call instruction of the next stage in the physical address of indoor set at least one indoor set described, wherein, the figure place that the address in the address roll-call instruction of previous stage is residing in the physical address of indoor set from the address in the address roll-call instruction of rear stage is different.
Alternatively, described off-premises station judge receive described data as incorrect data particularly as follows:
If described off-premises station receives the data that multiple indoor set returns according to the roll-call instruction of described address, then judge that the data that described off-premises station receives are incorrect.
Alternatively, described off-premises station also includes before receiving the step of the data that at least one indoor set described returns according to the roll-call instruction of described address:
If described off-premises station does not receive the data that indoor set returns according to the roll-call instruction of described address, the next address roll-call instruction in the default bit address in the physical address of indoor set is then broadcasted at least one indoor set described, wherein, the previous address in the roll-call instruction of address is different from the address in the address roll-call instruction of later.
Alternatively, the address distribution method of air-conditioning equipment also includes:
After described off-premises station has broadcasted all addresses roll-call instruction in the default bit address in the physical address of indoor set, if not receiving the data that indoor set returns according to the roll-call instruction of described address yet, then judge that all indoor sets successfully arrange Self address.
Additionally, for achieving the above object, the present invention also provides for the address distributing device of a kind of air-conditioning equipment, and the address distributing device of described air-conditioning equipment includes:
Broadcast module, is used at least one indoor set broadcast address roll-call instruction, wherein, and the default bit address in the physical address of the address correspondence indoor set in the roll-call instruction of described address;
Receiver module, for receiving the data that at least one indoor set described returns according to the roll-call instruction of described address;
Judge module, for judging that whether the data received are correct;
Distribution module, if the data for receiving are correct, then to the indoor set distribution address returning just data, the indoor set for described return just data arranges Self address according to the address of distribution.
Alternatively, described broadcast module, if the data being additionally operable to receive are incorrect, then to the address roll-call instruction of the next stage in the physical address of at least one indoor set described broadcast indoor set, wherein, the figure place that the address in the address roll-call instruction of previous stage is residing in the physical address of indoor set from the address in the address roll-call instruction of rear stage is different.
Alternatively, if described judge module is additionally operable to receive the data that multiple indoor set returns according to the roll-call instruction of described address, then judge that the data that described off-premises station receives are incorrect.
Alternatively, described broadcast module, if being additionally operable to not receive the data that indoor set returns according to the roll-call instruction of described address, the next address roll-call instruction in the default bit address in the physical address of indoor set is then broadcasted at least one indoor set described, wherein, the previous address in the roll-call instruction of address is different from the address in the address roll-call instruction of later.
Alternatively, described judge module, after being additionally operable to all addresses roll-call instruction in the default bit address in the physical address having broadcasted indoor set, if not receiving the data that indoor set returns according to the roll-call instruction of described address yet, then judge that all indoor sets successfully arrange Self address.
The present invention by off-premises station at least one indoor set broadcast address roll-call instruction, if the physical address of indoor set includes the address in the roll-call instruction of described address, then described indoor set response described address roll-call instruction, namely data are returned to described off-premises station, described off-premises station judges that whether the data received are correct, if the data received are correct, then described off-premises station gives the indoor set distribution address returning just data, for it, Self address is set according to the address of distribution, thus the address realizing indoor set is distributed automatically, the unhandy problem caused when efficiently solving manual allocation address.
Detailed description of the invention
Should be appreciated that specific embodiment described herein is only in order to explain the present invention, is not intended to limit the present invention.
Based on the problems referred to above, the present invention provides the address distribution method of a kind of air-conditioning equipment.
Schematic flow sheet with reference to the first embodiment of the address distribution method that Fig. 1, Fig. 1 are air-conditioning equipment of the present invention.
In the present embodiment, the address distribution method of described air-conditioning equipment includes:
Step S10, off-premises station is at least one indoor set broadcast address roll-call instruction;
When being energized first after air-conditioning equipment (including indoor set and off-premises station) installation, will automatically into address allocation flow, off-premises station is at least one indoor set broadcast address roll-call instruction, it is preferred that at least one indoor set described is all indoor sets in air conditioning system.Wherein, the default bit address in the physical address of the address correspondence indoor set in the roll-call instruction of described address.Described physical address is the identifier of each indoor set, it is generally adopted hexadecimal number to represent, have 6 bytes (Byte), 12 nibbles (Byte), assuming to use SEG0~SEG11 to represent this 12 nibbles (Byte) respectively, each nibble (Byte) in indoor set physical address can be some in hexadecimal number 0~F.In this embodiment, the default bit address in described physical address is preferably the first address of described physical address, i.e. SEG0, and certainly, the default bit address in described physical address can also be other bit address of described physical address, for instance the 12nd bit address, i.e. SEG11.The physical address having due to different indoor sets is different, namely the physical address of indoor set is unique, and off-premises station does not know the physical address of each indoor set in advance, therefore, different indoor sets can be distinguished at least one indoor set broadcast address roll-call instruction by off-premises station, preferably, when carrying out broadcast address and calling the roll, the address of the nybble can every time called the roll in the physical address of indoor set, i.e. each some nibble address in SEG0~SEG11 of only calling the roll, for instance the address that roll-call SEG0 is corresponding.
Step S20, described off-premises station receives the data that at least one indoor set described returns according to the roll-call instruction of described address;
If the address comprised in the physical address of the prespecified indoor set of the communication protocol of described air-conditioning equipment in the roll-call instruction of described off-premises station address, then this indoor set is after the address roll-call instruction receiving the broadcast of described off-premises station, described off-premises station can be returned data to, these data are replied by data message, the concrete data returned are determined by message protocol, do not limit herein.
If it should be noted that indoor set has had address, then will not responding the address roll-call instruction of described off-premises station broadcast, namely indoor set will not return data to described off-premises station.
Step S30, described off-premises station judges that whether the data received are correct;
Step S40, if so, then described off-premises station, to the indoor set distribution address returning just data, arranges Self address for it according to the address of distribution.
Described off-premises station is after receiving the data that indoor set returns, it is judged that whether the data received correct, concrete, it can be determined that whether the data received are preset data, if described in the data that receive be preset data, it is determined that the data received are correct.In the present embodiment, when only one of which indoor set returns data according to the roll-call instruction of described address, off-premises station just can receive the correct data that at least one indoor set described returns, when there is multiple indoor set and returning data according to the roll-call instruction of described address, due to interfering between the data of each return, make the data that described off-premises station receives incorrect, and then cause that described off-premises station not can determine that the indoor set returning data.Therefore, described off-premises station, only when receiving correct return data, just to the indoor set distribution address returning just data, can be arranged the address of self, namely arrange the address of this indoor set for this indoor set according to the address of distribution.Off-premises station can be pre-stored in the address in address table for described off-premises station to the address that indoor set distributes, and often distributes an address, all needs to record this address, to avoid the indoor set for other to distribute identical address.
The present embodiment by off-premises station at least one indoor set broadcast address roll-call instruction, if the physical address of indoor set includes the address in the roll-call instruction of described address, then described indoor set response described address roll-call instruction, namely data are returned to described off-premises station, described off-premises station judges that whether the data received are correct, if the data received are correct, then described off-premises station gives the indoor set distribution address returning just data, for it, Self address is set according to the address of distribution, thus the address realizing indoor set is distributed automatically, the unhandy problem caused when efficiently solving manual allocation address.
Further, propose the second embodiment of the address distribution method of air-conditioning equipment of the present invention based on above-mentioned first embodiment, with reference to Fig. 2, in the present embodiment, after described step S30, also include:
Step S50, if it is not, then described off-premises station broadcasts the address roll-call instruction of the next stage in the physical address of indoor set at least one indoor set described.
When described off-premises station judges the data received as incorrect data, namely described off-premises station receives the data that multiple indoor set returns according to the roll-call instruction of described address, described off-premises station broadcasts the address roll-call instruction of next stage in the physical address of indoor set at least one indoor set described, wherein, the figure place that the address in the address roll-call instruction of previous stage is residing in the physical address of indoor set from the address in the address roll-call instruction of rear stage is different.nullSuch as,If the address that address is the first order in address roll-call instruction last time,Then the address in the address roll-call instruction of this time broadcast is then the address of the next stage in the physical address of indoor set,The i.e. address of the second level,The rest may be inferred,If the address that address is the tenth one-level in address roll-call instruction last time,Then the address of this time broadcast is then the address of the 12nd grade,It should be noted that,The address of each rank described above correspond to each the address from low to high of the physical address of described indoor set,Specifically,The address of the first order correspond to the first bit address of described indoor set physical address,I.e. SEG0,The address of the second level correspond to the second address of described indoor set physical address,I.e. SEG1,The address of the third level correspond to the 3rd bit address of described indoor set physical address,I.e. SEG2,The rest may be inferred,Dozenth address correspond to the tenth two digit address of described indoor set physical address,I.e. SEG11.One specific embodiment of the present invention is as follows:
nullAssume when off-premises station receives incorrect data,In the address that address is the first order of the address roll-call instruction of broadcast 5,Then off-premises station will broadcast the address of the second level next time,I.e. 0~F in SEG1,First start from address 0 to call the roll,If not having indoor set to respond this address 0,Then by continuation roll-call address 1,The address F until calling the roll,Call the roll in the address then returning to the first order,In the address of the first order of namely calling the roll 6,If when calling the roll certain address,Have multiple indoor set to respond this address to call the roll,Then off-premises station will continue the address roll-call instruction of broadcast next stage,That is the address of the broadcast third level will be continued,In like manner,It is start from address 0 to call the roll,The address F until calling the roll,If in roll-call address 0 to the process of address F,There is not receiving the situation of multiple indoor set response address roll-call instruction,Then calling the roll after the F of address,Call the roll in the address returning to the first order,In the address of the first order of namely calling the roll 6,In like manner,If in roll-call address 0 to the process of address F,Still there is receiving the situation of multiple indoor set response address roll-call instruction,Then off-premises station will continue the address roll-call instruction of broadcast next stage.
The present embodiment is by when off-premises station receives the data that multiple indoor set returns according to address roll-call instruction, and different indoor sets is distinguished in the address roll-call instruction of broadcast next stage, thus being embodied as each indoor set automatically distribute address.
Further, propose the 3rd embodiment of the address distribution method of air-conditioning equipment of the present invention based on any of the above-described embodiment, with reference to Fig. 3, in the present embodiment, before described step S20, also include:
Step S60, if described off-premises station does not receive the data that indoor set returns according to the roll-call instruction of described address, then broadcasts the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described.
When off-premises station is at least one indoor set broadcast address roll-call instruction described, within the default time, described off-premises station does not receive the data that indoor set returns according to the roll-call instruction of described address, then show the physical address of at least one indoor set described is all absent from the address in the address roll-call instruction of current broadcast, then off-premises station broadcasts the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described, wherein, the previous address in the roll-call instruction of address is different from the address in the address roll-call instruction of later.Such as, if in the default bit address in the physical address that address is indoor set in the roll-call instruction of previous address 0, then the address in the address roll-call instruction of later is then 1, if the address in the roll-call instruction of previous address is 1, then the address in the address roll-call instruction of later is then 2, by that analogy, if the address in the roll-call instruction of previous address is E, then the address in the address roll-call instruction of later is then F.After off-premises station broadcasts the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described, if after Preset Time, indoor set does not receive the data that indoor set returns according to the roll-call instruction of described address yet, then repeated execution of steps S60, until off-premises station receives the data that indoor set returns.
When the present embodiment does not have indoor set to respond by the address roll-call instruction broadcasted at off-premises station, different indoor sets is distinguished in broadcast next address roll-call instruction, thus realizing automatically distributing address to each indoor set.
Further, proposing the 4th embodiment of the address distribution method of air-conditioning equipment of the present invention based on first embodiment, with reference to Fig. 4, in the present embodiment, the address distribution method of described air-conditioning equipment also includes:
Step S70, after described off-premises station has broadcasted all addresses roll-call instruction in the default bit address in the physical address of indoor set, if not receiving the data that indoor set returns according to the roll-call instruction of described address yet, then judge that all indoor sets successfully arrange Self address.
The all addresses in the default bit address in the physical address of indoor set have been broadcasted at described off-premises station, namely after the address roll-call instruction that address is F in the described off-premises station default bit address in the physical address having broadcasted indoor set, when not receiving the data that indoor set returns according to the roll-call instruction of described address yet, judge that all of indoor set successfully arranges Self address, address allocation flow terminates, access arrangement communication mode, namely off-premises station can with each indoor set normal communication.
The present invention further provides the address distributing device of a kind of air-conditioning equipment.
High-level schematic functional block diagram with reference to the first embodiment of the address distributing device that Fig. 5, Fig. 5 are air-conditioning equipment of the present invention.
In the present embodiment, the address distributing device of described air-conditioning equipment includes: broadcast module 10, receiver module 20, judge module 30 and distribution module 40.
Described broadcast module 10, is used for all indoor set broadcast address roll-call instructions, wherein, and the default bit address in the physical address of the address correspondence indoor set in the roll-call instruction of described address;
When being energized first after air-conditioning equipment (including indoor set and off-premises station) installation, will automatically into address allocation flow, described broadcast module 10 is at least one indoor set indoor set broadcast address roll-call instruction, preferably, at least one indoor set described is all indoor sets in air conditioning system.Wherein, the default bit address in the physical address of the corresponding described all indoor sets in the address in the roll-call instruction of described address.Described physical address is the identifier of each indoor set, it is generally adopted hexadecimal number to represent, have 6 bytes (Byte), 12 nibbles (Byte), assuming to use SEG0~SEG11 to represent this 12 nibbles (Byte) respectively, each nibble (Byte) in indoor set physical address can be some in hexadecimal number 0~F.In this embodiment, the default bit address in described physical address is preferably the first address of described physical address, i.e. SEG0, and certainly, the default bit address in described physical address can also be other bit address of described physical address, for instance the 12nd bit address, i.e. SEG11.The physical address having due to different indoor sets is different, and the physical address of indoor set is unique, but, off-premises station does not know the physical address of each indoor set in advance, therefore, different indoor sets can be distinguished at least one indoor set indoor set broadcast address roll-call instruction by described broadcast module 10, preferably, when carrying out broadcast address and calling the roll, the address of the nybble can every time called the roll in the physical address of indoor set, i.e. each some nibble address in SEG0~SEG11 of only calling the roll, for instance the address that roll-call SEG0 is corresponding.
Described receiver module 20, for receiving the data that at least one indoor set described returns according to the roll-call instruction of described address;
If the address comprised in the physical address of the prespecified indoor set of the communication protocol of described air-conditioning equipment in the roll-call instruction of described off-premises station address, then this indoor set is after the address roll-call instruction receiving the broadcast of described off-premises station, described off-premises station can be returned data to, these data are replied by data message, the concrete data returned are determined by message protocol, do not limit herein.
If it should be noted that indoor set has had address, then will not responding the address roll-call instruction of described off-premises station broadcast, namely indoor set will not return data to described off-premises station.
Described judge module 30, for judging that whether the data received are correct;
Described distribution module 40, if the data for receiving are correct, then to the indoor set distribution address returning just data, the indoor set for described return just data arranges Self address according to the address of distribution.
Described receiver module 20 is after receiving the data that indoor set returns, described judge module 30 judges that whether the data received are correct, concrete, it can be determined that whether the data received are preset data, if described in the data that receive be preset data, it is determined that the data received are correct.In the present embodiment, when only one of which indoor set returns data according to the roll-call instruction of described address, receiver module 20 just can receive the correct data that at least one indoor set described returns, when there is multiple indoor set and returning data according to the roll-call instruction of described address, due to interfering between the data of each return, the data that described off-premises station receives can be made incorrect, and then cause that described receiver module 20 not can determine that the indoor set returning data.Therefore, only when receiving correct return data, described distribution module 40 just to the indoor set distribution address returning just data, can be arranged the address of self, namely arrange the address of this indoor set for this indoor set according to the address of distribution.Off-premises station can be pre-stored in the address in address table for described off-premises station to the address that indoor set distributes, and often distributes an address, all needs to record this address, to avoid the indoor set for other to distribute identical address.
Further, described broadcast module 10, if the data being additionally operable to receive are incorrect, then to the address roll-call instruction of the next stage in the physical address of at least one indoor set described broadcast indoor set.
When described judge module 30 judges the data received as incorrect data, namely described receiver module 20 receives the data that multiple indoor set returns according to the roll-call instruction of described address, described broadcast module 10 broadcasts the address roll-call instruction of next stage in the physical address of indoor set at least one indoor set described, wherein, the figure place that the address in the address roll-call instruction of previous stage is residing in the physical address of indoor set from the address in the address roll-call instruction of rear stage is different.nullSuch as,If the address that address is the first order in address roll-call instruction last time,Then the address in the address roll-call instruction of this time broadcast is then the address of the next stage in the physical address of indoor set,The i.e. address of the second level,The rest may be inferred,If the address that address is the tenth one-level in address roll-call instruction last time,Then the address of this time broadcast is then the address of the 12nd grade,It should be noted that,The address of each rank described above correspond to each the address from low to high of the physical address of described indoor set,Specifically,The address of the first order correspond to the first bit address of described indoor set physical address,I.e. SEG0,The address of the second level correspond to the second address of described indoor set physical address,I.e. SEG1,The address of the third level correspond to the 3rd bit address of described indoor set physical address,I.e. SEG2,The rest may be inferred,Dozenth address correspond to the tenth two digit address of described indoor set physical address,I.e. SEG11.One specific embodiment of the present invention is as follows:
nullAssume when receiver module 20 receives incorrect data,In the address that address is the first order of the address roll-call instruction of broadcast 5,Then described broadcast module 10 will broadcast the address of the second level next time,I.e. 0~F in SEG1,First start from address 0 to call the roll,If not having indoor set to respond this address 0,Then by continuation roll-call address 1,The address F until calling the roll,Call the roll in the address then returning to the first order,In the address of the first order of namely calling the roll 6,If when calling the roll certain address,Have multiple indoor set to respond this address to call the roll,Then broadcast module 10 will continue the address roll-call instruction of broadcast next stage,That is the address of the broadcast third level will be continued,In like manner,It is start from address 0 to call the roll,The address F until calling the roll,If in roll-call address 0 to the process of address F,There is not receiving the situation of multiple indoor set response address roll-call instruction,Then calling the roll after the F of address,Call the roll in the address returning to the first order,In the address of the first order of namely calling the roll 6,In like manner,If in roll-call address 0 to the process of address F,Still there is receiving the situation of multiple indoor set response address roll-call instruction,Then described broadcast module 10 will continue the address roll-call instruction of broadcast next stage.
Further, described broadcast module 10, if being additionally operable to not receive the data that indoor set returns according to the roll-call instruction of described address, then broadcast the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described.
When broadcast module 10 is at least one indoor set broadcast address roll-call instruction described, within the default time, described receiver module 20 does not receive the data that indoor set returns according to the roll-call instruction of described address, then show the physical address of at least one indoor set described is all absent from the address in the address roll-call instruction of current broadcast, then broadcast module 10 broadcasts the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described, wherein, the previous address in the roll-call instruction of address is different from the address in the address roll-call instruction of later.Such as, if in the default bit address in the physical address that address is indoor set in the roll-call instruction of previous address 0, then the address in the address roll-call instruction of later is then 1, if the address in the roll-call instruction of previous address is 1, then the address in the address roll-call instruction of later is then 2, by that analogy, if the address in the roll-call instruction of previous address is E, then the address in the address roll-call instruction of later is then F.After off-premises station broadcasts the next address roll-call instruction in the default bit address in the physical address of indoor set at least one indoor set described, if after Preset Time, indoor set does not receive the data that indoor set returns according to the roll-call instruction of described address yet, then repeated execution of steps S60, until receiver module 20 receives the data that indoor set returns.
Described judge module 30, after being additionally operable to all addresses roll-call instruction in the default bit address in the physical address having broadcasted indoor set, if not receiving the data that indoor set returns according to the roll-call instruction of described address yet, then judge that all indoor sets successfully arrange Self address.
When broadcast module 10 is after having broadcasted the roll-call instruction of described address, namely after the address roll-call instruction that address is F in the described broadcast module 10 default bit address in the physical address having broadcasted indoor set, when not receiving the data that indoor set returns according to the roll-call instruction of described address yet, described judge module 30 judges that all of indoor set successfully arranges Self address, address allocation flow terminates, access arrangement communication mode, namely off-premises station can with each indoor set normal communication.
The present embodiment by off-premises station at least one indoor set broadcast address roll-call instruction, if the physical address of indoor set includes the address in the roll-call instruction of described address, then described indoor set response described address roll-call instruction, namely data are returned to described off-premises station, described off-premises station judges that whether the data received are correct, if the data received are correct, then described off-premises station gives the indoor set distribution address returning just data, for it, Self address is set according to the address of distribution, thus the address realizing indoor set is distributed automatically, the unhandy problem caused when efficiently solving manual allocation address.
The invention described above embodiment sequence number, just to describing, does not represent the quality of embodiment.Through the above description of the embodiments, those skilled in the art is it can be understood that can add the mode of required general hardware platform by software to above-described embodiment method and realize, hardware can certainly be passed through, but in a lot of situation, the former is embodiment more preferably.Based on such understanding, the part that prior art is contributed by technical scheme substantially in other words can embody with the form of software product, this computer software product is stored in a storage medium (such as ROM/RAM, magnetic disc, CD), including some instructions with so that a station terminal equipment (can be mobile phone, computer, server, air-conditioner, or the network equipment etc.) perform the method described in each embodiment of the present invention.
These are only the preferred embodiments of the present invention; not thereby the scope of the claims of the present invention is limited; every equivalent structure utilizing description of the present invention and accompanying drawing content to make or equivalence flow process conversion; or directly or indirectly it is used in other relevant technical fields, all in like manner include in the scope of patent protection of the present invention.