CN105338129A - Automatic address dividing method, display terminal, and module terminal - Google Patents

Automatic address dividing method, display terminal, and module terminal Download PDF

Info

Publication number
CN105338129A
CN105338129A CN201510771758.XA CN201510771758A CN105338129A CN 105338129 A CN105338129 A CN 105338129A CN 201510771758 A CN201510771758 A CN 201510771758A CN 105338129 A CN105338129 A CN 105338129A
Authority
CN
China
Prior art keywords
address
terminal
modular
random number
display terminal
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN201510771758.XA
Other languages
Chinese (zh)
Other versions
CN105338129B (en
Inventor
陈万兴
王驰
姚勇韬
程会恩
孙亚丽
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Gree Electric Appliances Inc of Zhuhai
Original Assignee
Gree Electric Appliances Inc of Zhuhai
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 Gree Electric Appliances Inc of Zhuhai filed Critical Gree Electric Appliances Inc of Zhuhai
Priority to CN201510771758.XA priority Critical patent/CN105338129B/en
Publication of CN105338129A publication Critical patent/CN105338129A/en
Application granted granted Critical
Publication of CN105338129B publication Critical patent/CN105338129B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5046Resolving address allocation conflicts; Testing of addresses

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses an automatic address dividing method, a display terminal, and a module terminal. The method comprises: after completion of monitoring, by the module terminal, of address allocation data sent by a display terminal, an address is allocated according to the address allocation data to obtain a target address; the module terminal sends the target address to a bus, so that the display terminal can carry out address verification; the module terminal monitors a confirmation request sent by the display terminal; if the confirmation request is monitored, the target address is used as the address; and if not confirmation request is monitored, the step of address allocation based on the address allocation data after completion of monitoring of the address allocation data sent by a display terminal is executed again. Therefore, a technical problem that a communication fault occurs at a set due to missing dialing up or wrong dialing up during manual debugging can be solved.

Description

Automatically point location method, display terminal and modular terminal
Technical field
The present invention relates to air conditioner field, automatically divide location method, display terminal and modular terminal in particular to one.
Background technology
For modular air conditioner handpiece Water Chilling Units, adopt toggle switch to carry out address differentiation in control system between each module, the address that when dispatching from the factory, toggle switch is dialled is all the same, manually carries out the dial-up of address when Installation and Debugging.
What usual toggle switch represented is binary code, need Installation and Debugging personnel that binary code can be utilized to regulate toggle switch, but commissioning staff's is uneven, causes unit to occur communication failure sometimes because dial-up leaks to dial or dial the wrong number.
For above-mentioned problem, at present effective solution is not yet proposed.
Summary of the invention
Embodiments provide a kind of point location method, display terminal and modular terminal automatically, dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks at least to solve.
According to an aspect of the embodiment of the present invention, provide a kind of point location method automatically, comprise: at least two modular terminals and display terminal by dereliction from CAN communicate, described method comprises: after modular terminal takes turns address assignment data monitored the transmission of described display terminal one, be its allocation address according to described address assignment data, obtain destination address; Described modular terminal sends described destination address to described bus, carries out address validation for described display terminal; Described modular terminal monitors the confirmation request that described display terminal sends; If listen to described confirmation request, then using the address of described destination address as himself; If do not listen to described confirmation request, then returning after taking turns address assignment data has monitored the transmission of described display terminal one is the step of its allocation address according to described address assignment data.
According to the another aspect of the embodiment of the present invention, additionally provide a kind of point location method automatically, comprise: at least two modular terminals and display terminal by dereliction from CAN communicate, described method comprises: after described display terminal takes turns address assignment data to described bus transmission one, by the response data that described bus acquisition module terminal sends, wherein, it is the destination address that himself distributes that described response data carries object module terminal, described object module terminal for described in any one terminal at least two modules; Described display terminal verifies the whether successful allocation address of described object module terminal according to the response data got; In the successful situation of address assignment of described object module terminal, described display terminal sends the indication information be allocated successfully according to described destination address; When the address assignment failure of described object module terminal, return described display terminal and send to described bus the step that takes turns address assignment data.
According to the another aspect of the embodiment of the present invention, additionally provide a kind of modular terminal, comprise at least two modular terminals and display terminal by dereliction from CAN communicate, described modular terminal comprises: allocation units, after taking turns address assignment data monitored the transmission of described display terminal one, be its allocation address according to described address assignment data, obtain destination address; First address transmitting element, for sending described destination address to described bus, carries out address validation for described display terminal; First monitoring unit, for monitoring the confirmation request that described display terminal sends; Determining unit, for when listening to described confirmation request, using the address of described destination address as himself; First call unit, for when not listening to described confirmation request, calls described allocation units.
According to the another aspect of the embodiment of the present invention, additionally provide a kind of display terminal, at least two modular terminals and display terminal by dereliction from CAN communicate, described display terminal comprises: acquiring unit, after taking turns address assignment data to described bus transmission one, by the response data that described bus acquisition module terminal sends, wherein, it is the destination address that himself distributes that described response data carries object module terminal, described object module terminal for described in any one terminal at least two modules; Authentication unit, for verifying the whether successful allocation address of described object module terminal according to the response data got; Instruction transmitting element, in the successful situation of address assignment of described object module terminal, described display terminal sends the indication information be allocated successfully according to described destination address; Data call unit, for when the address assignment failure of described object module terminal, calls described acquiring unit.
In embodiments of the present invention, after adopting modular terminal to take turns address assignment data monitored display terminal transmission one, be its allocation address according to address assignment data, obtain destination address; Modular terminal sends destination address to bus, carries out address validation for display terminal; Modular terminal monitors the confirmation request that display terminal sends; Request is confirmed, then using the address of destination address as himself if listened to; Request is confirmed if do not listened to, then return after taking turns address assignment data monitored display terminal transmission one the mode of the step according to address assignment data being its allocation address, solve and dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks.
Accompanying drawing explanation
Accompanying drawing described herein is used to provide a further understanding of the present invention, and form a application's part, schematic description and description of the present invention, for explaining the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the schematic diagram of the control system according to the embodiment of the present invention;
Fig. 2 is the flow chart of the automatic point location method according to the embodiment of the present invention 1;
Fig. 3 is the flow chart according to the preferred point location method automatically of the embodiment of the present invention 1;
Fig. 4 is the flow chart of the automatic point location method according to the embodiment of the present invention 2;
Fig. 5 is the flow chart according to the preferred point location method automatically of the embodiment of the present invention 2;
Fig. 6 is the schematic diagram of the modular terminal according to the embodiment of the present invention 3;
Fig. 7 is the schematic diagram of the display terminal according to the embodiment of the present invention 4.
Embodiment
The present invention program is understood better in order to make those skilled in the art person, below in conjunction with the accompanying drawing in the embodiment of the present invention, technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the embodiment of a part of the present invention, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, should belong to the scope of protection of the invention.
It should be noted that, term " first ", " second " etc. in specification of the present invention and claims and above-mentioned accompanying drawing are for distinguishing similar object, and need not be used for describing specific order or precedence.Should be appreciated that the data used like this can be exchanged in the appropriate case, so as embodiments of the invention described herein can with except here diagram or describe those except order implement.In addition, term " comprises " and " having " and their any distortion, intention is to cover not exclusive comprising, such as, contain those steps or unit that the process of series of steps or unit, method, system, product or equipment is not necessarily limited to clearly list, but can comprise clearly do not list or for intrinsic other step of these processes, method, product or equipment or unit.
Embodiment 1
According to the embodiment of the present invention, provide a kind of embodiment of the method for automatic point of location method, this automatically a point location method can be applied in control system as shown in Figure 1.As shown in Figure 1, at least two modular terminals and display terminal by dereliction from CAN carry out communication, the data that module sends can be received by other modules in this CAN simultaneously.Therefore, when display terminal sends data to bus, modular terminal all can listen to these data and reply.Meanwhile, the data that modular terminal sends also can be listened to by other modular terminals.This embodiment is exactly the above-mentioned principle according to CAN, multiple modular terminal all replys the address assignment data that display terminal sends, the delay time that each modular terminal is replied can be decided by random number, display terminal to stagger the reply data of modules terminal according to the time difference of delay time, thus achieved address assignment.
Random number produces and illustrates: because the crystal oscillator individuality that disparate modules terminal uses is discrepant, certain reference frequency deviation is had between each crystal oscillator, the cumulative number using crystal oscillator clock to produce will be had any different along with the increase of time, the collision probability of the pseudo random number using clock accumulated variables just to make same program obtain on different modular terminals as the seed producing pseudo random number is less, and along with the continuous forward of time, the collision probability of the pseudo random number obtained is also more and more less, namely adopt the probability of identical delay time less between multiple modular terminal, can be multiple modular terminal allocation address fast.
It should be noted that, can perform in the computer system of such as one group of computer executable instructions in the step shown in the flow chart of accompanying drawing, and, although show logical order in flow charts, but in some cases, can be different from the step shown or described by order execution herein.Step in embodiment 1 can be performed by modular terminal.
Fig. 2 is the flow chart of the automatic point location method according to the embodiment of the present invention 1, and as shown in Figure 2, the method comprises the steps:
Step S202, modular terminal is its allocation address according to address assignment data, obtains destination address after taking turns address assignment data monitored display terminal transmission one.
Step S204, modular terminal sends destination address to bus, carries out address validation for display terminal.
Step S206, modular terminal monitors the confirmation request that display terminal sends.
Step S208, confirms request if listened to, then using the address of destination address as himself.Confirm request if do not listened to, then returning after taking turns address assignment data has monitored display terminal transmission one is the step of its allocation address according to address assignment data.
Modular terminal can listen to by CAN the address assignment data that display terminal sends to all modular terminals, modular terminal listen to display terminal complete one take turns the transmission of address assignment data after, search minimum address in never occupied address as destination address.Because modular terminal can listen to the data of this CAN of all processes transmission by CAN, also the address that other modules send to display terminal is comprised, therefore, which address modular terminal can differentiate takies, which address is not occupied, and the address as oneself that in never occupied address, selection one is minimum, obtain destination address.The address that modular terminal adopts can be binary digital encoding, can distribute the figure place of binary digital encoding according to the quantity of the modular terminal that CAN connects.Namely alternatively, modular terminal is its allocation address according to address assignment data, obtains destination address and comprise: modular terminal monitors the data taking address transmitted in bus after taking turns address assignment data monitored display terminal transmission one; Modular terminal is searched not by the lowest address used according to the data taking address from address assignment data; Modular terminal using the address that finds as destination address.
After modular terminal distributes address for oneself, the address of distribution is sent to CAN, all modular terminals in such CAN and display terminal can both receive this address.Display terminal is verified this address, repeats to avoid producing with the address of other modular terminals or conflicts, and other modular terminals also can be made to avoid the address that this modular terminal selected selecting address.When the address of display terminal checking destination address and other modules is not repeated, send and confirm that request is so that modular terminal knows its whether successful allocation address.If according to confirming that the address assignment success of modular terminal is instructed in request, then using the address of destination address as himself, otherwise, again monitor the next round address assignment data that display terminal sends, again obtain distribute data and verify, until its successful allocation address.Display terminal sends repeatedly address assignment data to CAN, and the number of times of transmission is identical with the number of modular terminal, and after all sending address assignment data to all modular terminals, one takes turns address assignment data is sent completely.
In this embodiment, according to the principle that dereliction can be received by multiple terminal from the data of CAN simultaneously, make each modular terminal for oneself allocation address, and which address is occupied to make other modular terminals know, achieve automatic allocation address, simultaneously, display terminal and modular terminal is adopted to verify to the address that modular terminal distributes the accuracy ensureing modular terminal allocation address, thus solve in prior art because dial-up leakage during manual debugging is dialled or the technical problem causing unit to occur communication failure of dialing the wrong number, and then reach the technique effect that communication failure is avoided in accurate point location.
Be described for Fig. 1.
Display terminal A to modular terminal B1, modular terminal B2 ... modular terminal Bn sends address assignment data respectively, and when modular terminal B1 listens to after all address assignment data are all sent, modular terminal B1 is oneself allocation address.If transmission has the address of modular terminal B2 in CAN, then modular terminal B1 is listening to the information taking address of modular terminal B2, the address from modular terminal B2 can be avoided when allocation address, thus avoid identical with the address of modular terminal B2 and cause conflict.
Display terminal A receives the address that each modular terminal sends from CAN, and whether checking has the address of repetition, determine that when there is no the address of repeating this takes turns address assignment success, otherwise this takes turns address assignment failure, re-starts the address assignment of next round.The mode that next round is distributed is identical with the first round, and concrete steps are with reference to foregoing.If after the address of modular terminal B1 is specified to the distribution of work, when next round allocation address, its address is sent to CAN by modular terminal B1, so that other modular terminal calculated addresses.
Alternatively, after modular terminal takes turns address assignment data monitored display terminal transmission one, and before modular terminal sends destination address to bus, modular terminal generates random number; Modular terminal sends destination address to bus and comprises: modular terminal is when reaching delay time, and send address and random number to bus, wherein, modular terminal is according to generating random number delay time.Be when oneself being assigned with identical address at multiple modular terminal, display terminal determines the address assignment success of which modular terminal according to the random number of each modular terminal and time of replying data, the address assignment failure of which modular terminal.Modular terminal generates random number after the address assignment data listening to display terminal transmission, and determines delay time according to random number.Because delay time is determined by random number, when the probability that random number is identical is very little, the probability that delay time is identical is also very little, and this facilitates display terminal and carries out address validation.The scope of delay time is at 0 to 22 millisecond.
Such as, the time delay of modular terminal B1 is 2ms, its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, its address distributed for oneself is 11, then after display terminal sends allocation address order to CAN line, modular terminal monitored one take turns allocation address order after, the address 01 oneself distributed is replied to display terminal by modular terminal B1 time delay 2ms, and the address 11 oneself distributed is replied to display terminal by modular terminal B2 time delay 4ms.
Alternatively, confirm request if listened to, then the address of destination address as himself is comprised: judge to confirm that whether the random number of asking to carry is consistent with the random number that modular terminal generates; If judge to confirm that the random number of asking to carry is consistent with the random number that modular terminal sends, the address assignment success of determination module terminal; If judge to confirm that the random number of asking the random number of carrying and modular terminal to send is inconsistent, the address assignment of determination module terminal unsuccessfully.
Such as, the time delay of modular terminal B1 is 2ms, random number is 2, its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, and random number is 4, and its address distributed for oneself is 10, then the address 01 oneself distributed is replied to display terminal by modular terminal B1 time delay 2ms, and the address 10 oneself distributed is replied to display terminal by modular terminal B2 time delay 4ms.
Display terminal receives the address of modular terminal B1 and modular terminal B2, then display terminal sends the confirmation request carrying random number 2 to the address 01 that modular terminal B1 sends, and sends the confirmation request carrying random number 4 to the address 10 that modular terminal B2 sends.After modular terminal B1 receives the confirmation request carrying random number, judge to confirm to ask whether the random number of carrying is 2, if confirm to ask the random number of carrying to be 2, then current address is allocated successfully; If confirm to ask the random number of carrying not to be 2, then determine that current address is distributed unsuccessfully.The verification method of modular terminal B2 is identical with modular terminal B1, repeats no more.
It should be noted that, confirmation request is tentatively judging in the successful situation of modular terminal allocation address, whether further checking address assignment is successful, that is display terminal can judge whether the address that multiple modular terminal generates has repetition, modular terminal can judge that whether the confirmation request of display terminal is accurate, to guarantee the situation that there will not be address assignment mistake further.Do not receive the confirmation request carrying random number, and directly have received next round address assignment data, then determine current address assignment failure.
Alternatively, after the address assignment success of determination module terminal, method comprises: monitor the generating random number request that display terminal sends; Judge the random number whether carrying modular terminal generation in generating random number request; When carrying the random number of modular terminal generation in generating random number request, modular terminal sends destination address to bus; When not carrying the random number that modular terminal generates in generating random number request, returning after taking turns address assignment data has monitored display terminal transmission one is the step of its allocation address according to address assignment data.
Display terminal send one take turns address assignment data after, if the modular terminal in CAN does not have all allocation address, when then again sending address assignment data, display terminal carries the random number of this modular terminal to the address assignment data that modular terminal sends, when modular terminal receives the address assignment data carrying random number, send its address information to CAN.If do not carry the random number that it generates in the address assignment data that modular terminal receives, be then oneself allocation address again.Namely last round of address assignment failure, needs deallocation.
In this embodiment, modular terminal verifies that whether its address distributed is successful for twice, is the confirmation request receiving display terminal transmission for the first time, if confirm that the random number of asking to carry is identical with the random number of its generation, then tentatively determines that address is allocated successfully; Second time is when again receiving address assignment data, alternatively when again receiving random number generation request, if carry random number, then determine that address is allocated successfully, only need send address to CAN, if do not carry random number, then modular terminal is oneself allocation address and generate random number again, according to first time allocation address method deallocation and verify.Each modular terminal can carry out automatic allocation address according to the method described above, until the address of all modular terminals in this CAN is all assigned.Because whether twice checking address becomes the distribution of work, avoid the address assignment mistake of modular terminal or do not distribute caused communication failure, reaching the technique effect that accurate allocation address avoids communication failure.Meanwhile, the data due to CAN transmission are that all modular terminals connected on the bus are shared, and improve the dispensing rate of address.
Automatically point location method of composition graphs 3 specification module terminal.
Step S302, receives the address assignment data frame that display terminal sends.
Step S304, has monitored one and has taken turns address assignment data frame, distributes not by the lowest address used to this modular terminal.
Step S306, time delay random time, sends address assignment response Frame.Modular terminal generates random number, according to generating random number random time, returns responsive data frame after time delay random time to display terminal.
Step S308, receives the request acknowledgement frame that display terminal sends.
Step S310, judges the data whether comprised in this frame in the responsive data frame of deuterzooid module transmission.If so, then perform step S312, if not, return step S302.
Step S312, replys display terminal Address Confirmation frame, the success of this modular terminal address assignment.
Embodiment 2
According to the embodiment of the present invention, provide a kind of embodiment of the method for automatic point of location method, this divides location method to perform by display terminal as shown in Figure 1 automatically.Display terminal can say the host computer in air-conditioner control system.
Fig. 4 is the flow chart of the automatic point location method according to the embodiment of the present invention 2.As shown in Figure 4, the method comprises the steps:
Step S402, after display terminal takes turns address assignment data to bus transmission one, the response data sent by bus acquisition module terminal, wherein, it is the destination address that himself distributes that response data carries object module terminal, and object module terminal is any one terminal at least two modules.
Step S404, display terminal is according to the whether successful allocation address of response data checking object module terminal got.
Step S406, in the successful situation of the address assignment of object module terminal, display terminal sends the indication information be allocated successfully according to destination address.When the address assignment failure of object module terminal, return display terminal and send to bus the step that takes turns address assignment data.
Display terminal sends address assignment data to CAN, namely sends generating random number request to each modular terminal, and receives the destination address that each modular terminal is oneself generation.The destination address that display terminal checking modules terminal sends also is verified.After being verified, sending the information be allocated successfully to this destination address, otherwise resend address assignment data, to allow each modular terminal again for oneself allocation address.Take turns after address assignment data is sent completely one, the address of part of module terminal may be had successfully to determine, also may the address of whole modular terminals can successfully determine.If there is the address of part of module terminal successfully to determine, then again sends one and take turns address assignment data, until the address of remaining all modular terminals can successfully be determined.
By this embodiment, after display terminal sends address assignment data, each modular terminal is oneself allocation address, achieve point location automatically, display terminal is verified the address that modular terminal distributes, what ensure that allocation address does not repeat that make between modules terminal can proper communication, thus solves in prior art and dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks, and then reaches accurately point location and avoid the technique effect of communication failure.
Alternatively, it is characterized in that, response data carries the random number that object module terminal generates, and display terminal comprises according to the whether successful allocation address of response data checking object module terminal got: display terminal judges whether the address entrained by two response datas of first receiving has repetition; If judge that there is repetition the address entrained by two response datas of first receiving, then determine the failure of object module terminal distribution address; If judge that the address entrained by two response datas of first receiving is not repeated, then determine the success of object module terminal distribution address.
Under normal circumstances, modular terminal transmits its address distributed for oneself by CAN, other modular terminals can avoid selected address when selecting address, therefore, the modular terminal of time delay same time may select identical address, especially when the address that the first two modular terminal sends is identical, also may make mistakes in the address that modular terminal below sends, therefore, when the address that the first two modular terminal sends is repeated, determine the failure of epicycle address assignment.
Be described for Fig. 1.
Display terminal A is to modular terminal B1, modular terminal B2 ... modular terminal Bn sends address assignment data respectively, and when modular terminal B1 listens to after all address assignment data are all sent, modular terminal B1 is oneself allocation address.If transmission has the address of modular terminal B2 in CAN, then modular terminal B1 is listening to the information taking address of modular terminal B2, the address from modular terminal B2 can be avoided when allocation address, thus avoid identical with the address of modular terminal B2 and cause conflict.
Display terminal A receives the address that each modular terminal sends from CAN, and whether checking has the address of repetition, determine that when there is no the address of repeating this takes turns address assignment success, otherwise this takes turns address assignment failure, re-starts the address assignment of next round.The mode that next round is distributed is identical with the first round, and concrete steps are with reference to foregoing.If after the address of modular terminal B1 is specified to the distribution of work, when next round allocation address, its address is sent to CAN by modular terminal B1, so that other modular terminal calculated addresses.
Be when oneself being assigned with identical address at multiple modular terminal, display terminal determines the address assignment success of which modular terminal according to the delay time of each modular terminal, the address assignment failure of which modular terminal.Modular terminal generates random number after the address assignment data listening to display terminal transmission, and determines delay time according to random number.Because delay time is determined by random number, when the probability that random number is identical is very little, the probability that delay time is identical is also very little, and this facilitates display terminal and carries out address validation.The scope of delay time is at 0 to 22 millisecond.
Such as, the time delay of modular terminal B1 is 2ms, and its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, its address distributed for oneself is 11, then modular terminal B1 sends address 01 after time delay 2ms, and modular terminal B2 sends address 11 after time delay 4ms.Do not conflict in the address of display terminal determination module terminal B1 and modular terminal B2, determination module terminal B1 and modular terminal B2 success allocation address.
If modular terminal B1 and modular terminal B2 is the address that oneself distributes be 01, but the time delay of modular terminal B1 is 2ms, the delay time of modular terminal B2 is 4ms, then the address of determination module terminal B1 is 01, the address assignment failure of modular terminal B2.If modular terminal B1 and modular terminal B2 is the address that oneself distributes be 01, and time delay is in 2ms, display terminal cannot determine that the address of which modular terminal is 01, therefore, by judging whether successfully delay time carrys out the address assignment of determination module terminal.
Whether display terminal checking shows identical address to different modular terminals, avoid address assignment error, delay time is verified further when there is identical address, by same address assignment to the shorter modular terminal of delay time, thus ensure that the correctness of the address assignment of modular terminal.
Alternatively, determine that object module terminal distribution address successfully comprises: display terminal confirms request according to the generating random number of modular terminal, and confirmation request is sent to destination address, confirm that request carries the random number of modular terminal generation; Confirmation response monitored by display terminal, wherein, confirmation response be random number that modular terminal demonstration validation request corresponding to destination address is carried consistent with the random number that this modular terminal generates time generate; When display terminal listens to confirmation response, determine the success of object module terminal distribution address; When display terminal does not receive the confirmation response, return display terminal and send to bus the step that takes turns address assignment data.
Such as, the time delay of modular terminal B1 is 2ms, random number is 2, and its address distributed for oneself is 01, and the delay time of modular terminal B2 is 4ms, random number is 4, its address distributed for oneself is 01, then display terminal determination display terminal B1 is identical with the address of display terminal B2, then judges delay time further, because the delay time of modular terminal B1 is shorter, then modular terminal B1 is distributed in address 01.Display terminal sends to modular terminal B1 and confirms request, carries random number 2 in this confirmation request, and after modular terminal B1 receives the confirmation request, checking random number 2 is identical with the random number of its generation, then confirm address assignment success.Because the address assignment of modular terminal B2 is unsuccessful, then display terminal is when sending next round address assignment data, sends address assignment data to modular terminal B2.
Display terminal, when sending next round address assignment data, sends the address assignment data carrying random number to modular terminal B1; The address assignment data not having random number is sent to modular terminal B2.Modular terminal B1 sends its address distributed to bus, and modular terminal B2 is according to the above-mentioned steps deallocation of the present embodiment.
Alternatively, when display terminal listens to confirmation response, after determining the success of object module terminal distribution address, method also comprises: display terminal judges whether at least two modular terminals all complete address assignment; If display terminal judges that at least two modular terminals all do not complete address assignment, then again send address assignment data at least two modular terminals, wherein, the address assignment data sent to object module terminal carries the random number that object module terminal generates.
When having after the address of modular terminal determines, this modular terminal can send its address to CAN, therefore, other do not have the modular terminal of allocation address to select address as the address distributed to oneself in never occupied address, and carry out the process verified.When storage in CAN does not have the modular terminal of allocation address, display terminal all can send one and take turns address assignment data, often take turns address assignment to complete, display terminal can judge whether all modular terminals in CAN all complete address assignment again, if completed, terminate point location automatically, if do not completed, proceed the address assignment of next round, until all modular terminals all complete point location automatically.
By this embodiment, achieve each modular terminal allocation address automatically, and can not conflict in the address between modules terminal, solve in prior art and dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks, and then reach the technique effect that communication failure is avoided in accurate point location.
Composition graphs 5 illustrates the automatic point location method of display terminal.
Step S502, sends address assignment data frame.
Step S504, receives all Frames of response, receives the responsive data frame of display terminal response address distribute data frame, and responsive data frame comprises random number and the address of modular terminal generation.
Step S506, judges the data whether having repetition in response frame, namely judges whether the address of repetition, if had, then return step S502, if do not had, then performs step S508.
Step S508, sends address validation data frame, namely sends and confirms request.
Step S510, judges whether only to receive frame response frame data, if so, then performs step S512, if not, then returns step S508.
Step S512, certain modular terminal address assignment success.
Step S514, judges whether all modular terminal addresses distribute, and if so, then end address is distributed, and if not, then returns step S502.
The step of above-mentioned automatic point of location method is as follows:
1, display terminal sends address assignment data, and namely display terminal produces claim frame to CAN random number.
2, modular terminal generates random number, and is oneself allocation address, and address and random number are sent to CAN.
3, display terminal sends request acknowledgement frame to destination address, and carries random number.Destination address is the address that modular terminal distributes.
4, modular terminal verifies that whether the random number entrained by request acknowledgement frame received is identical with the random number that this modular terminal generates, if identical, then returns acknowledgement frame response; If do not carried, then do not reply.
5, when display terminal is judged to receive only a response for same destination address, this address assignment success is confirmed.If when not receiving response or when receiving multiple response, then address assignment is unsuccessful.
Embodiment 3
According to the embodiment of the present invention, provide a kind of embodiment of modular terminal, this modular terminal can perform the automatic point location method in above-described embodiment.In this embodiment, at least two modular terminals and display terminal by dereliction from CAN communicate, as shown in Figure 6, this modular terminal comprises allocation units 60, first address transmitting element 62, first monitoring unit 64, determining unit 66 and the first call unit 68.
Allocation units 60 for monitored display terminal send one take turns address assignment data after, be its allocation address according to address assignment data, obtain destination address.
First address transmitting element 62, for sending destination address to bus, carries out address validation for display terminal.
The confirmation request that first monitoring unit 64 sends for monitoring display terminal.
Determining unit 66 for listen to confirm request time, using the address of destination address as himself.
First call unit 68, for when not listening to confirmation request, calls allocation units.
Modular terminal can listen to by CAN the address assignment data that display terminal sends to all modular terminals, modular terminal listen to display terminal complete one take turns the transmission of address assignment data after, search minimum address in never occupied address as destination address.Because modular terminal can listen to the data of this CAN of all processes transmission by CAN, also the address that other modules send to display terminal is comprised, therefore, which address modular terminal can differentiate takies, which address is not occupied, and the address as oneself that in never occupied address, selection one is minimum, obtain destination address.The address that modular terminal adopts can be binary digital encoding, can distribute the figure place of binary digital encoding according to the quantity of the modular terminal that CAN connects.Namely alternatively, modular terminal is its allocation address according to address assignment data, obtains destination address and comprise: modular terminal monitors the data taking address transmitted in bus after taking turns address assignment data monitored display terminal transmission one; Modular terminal is searched not by the lowest address used according to the data taking address from address assignment data; Modular terminal using the address that finds as destination address.Namely allocation units comprise: monitor module, for monitoring the data taking address transmitted in bus; Search module, for searching not by the lowest address used from address assignment data according to the data taking address; 3rd determination module, for the address that will find as destination address.
After modular terminal distributes address for oneself, the address of distribution is sent to CAN, all modular terminals in such CAN and display terminal can both receive this address.Display terminal is verified this address, repeats to avoid producing with the address of other modular terminals or conflicts, and other modular terminals also can be made to avoid the address that this modular terminal selected selecting address.When the address of display terminal checking destination address and other modules is not repeated, send and confirm that request is so that modular terminal knows its whether successful allocation address.If according to confirming that the address assignment success of modular terminal is instructed in request, then using the address of destination address as himself, otherwise, again monitor the next round address assignment data that display terminal sends, again obtain distribute data and verify, until its successful allocation address.Display terminal sends repeatedly address assignment data to CAN, and the number of times of transmission is identical with the number of modular terminal, and after all sending address assignment data to all modular terminals, one takes turns address assignment data is sent completely.
In this embodiment, according to the principle that dereliction can be received by multiple terminal from the data of CAN simultaneously, make each modular terminal for oneself allocation address, and which address is occupied to make other modular terminals know, achieve automatic allocation address, simultaneously, display terminal and modular terminal is adopted to verify to the address that modular terminal distributes the accuracy ensureing modular terminal allocation address, thus solve in prior art because dial-up leakage during manual debugging is dialled or the technical problem causing unit to occur communication failure of dialing the wrong number, and then reach the technique effect that communication failure is avoided in accurate point location.
Be described for Fig. 1.
Display terminal A is to modular terminal B1, modular terminal B2 ... modular terminal Bn sends address assignment data respectively, and when modular terminal B1 listens to after all address assignment data are all sent, modular terminal B1 is oneself allocation address.If transmission has the address of modular terminal B2 in CAN, then modular terminal B1 is listening to the information taking address of modular terminal B2, the address from modular terminal B2 can be avoided when allocation address, thus avoid identical with the address of modular terminal B2 and cause conflict.
Display terminal A receives the address that each modular terminal sends from CAN, and whether checking has the address of repetition, determine that when there is no the address of repeating this takes turns address assignment success, otherwise this takes turns address assignment failure, re-starts the address assignment of next round.The mode that next round is distributed is identical with the first round, and concrete steps are with reference to foregoing.If after the address of modular terminal B1 is specified to the distribution of work, when next round allocation address, its address is sent to CAN by modular terminal B1, so that other modular terminal calculated addresses.
Alternatively, generation unit, after taking turns address assignment data monitored display terminal transmission one, and before modular terminal sends destination address to bus, generates random number; First address transmitting element is also for when reaching delay time, and send address and random number to bus, wherein, modular terminal is according to generating random number delay time.Be when oneself being assigned with identical address at multiple modular terminal, display terminal determines the address assignment success of which modular terminal according to the random number of each modular terminal and time of replying data, the address assignment failure of which modular terminal.Modular terminal generates random number after the address assignment data listening to display terminal transmission, and determines delay time according to random number.Because delay time is determined by random number, when the probability that random number is identical is very little, the probability that delay time is identical is also very little, and this facilitates display terminal and carries out address validation.The scope of delay time is at 0 to 22 millisecond.
Such as, the time delay of modular terminal B1 is 2ms, its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, its address distributed for oneself is 11, then after display terminal sends allocation address order to CAN line, modular terminal monitored one take turns allocation address order after, the address 01 oneself distributed is replied to display terminal by modular terminal B1 time delay 2ms, and the address 11 oneself distributed is replied to display terminal by modular terminal B2 time delay 4ms.
Alternatively, determining unit comprises: judge module, confirms that whether the random number of asking to carry is consistent with the random number that modular terminal generates for judging; First determination module, for when the random number judging to confirm to ask to carry is consistent with the random number that modular terminal sends, the address assignment success of determination module terminal; Second determination module, when the random number for sending in the random number judging to confirm to ask to carry and modular terminal is inconsistent, the address assignment failure of determination module terminal.
Such as, the time delay of modular terminal B1 is 2ms, random number is 2, its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, and random number is 4, and its address distributed for oneself is 10, then the address 01 oneself distributed is replied to display terminal by modular terminal B1 time delay 2ms, and the address 10 oneself distributed is replied to display terminal by modular terminal B2 time delay 4ms.
Display terminal receives the address of modular terminal B1 and modular terminal B2, then display terminal sends the confirmation request carrying random number 2 to the address 01 that modular terminal B1 sends, and sends the confirmation request carrying random number 4 to the address 10 that modular terminal B2 sends.After modular terminal B1 receives the confirmation request carrying random number, judge to confirm to ask whether the random number of carrying is 2, if confirm to ask the random number of carrying to be 2, then current address is allocated successfully; If confirm to ask the random number of carrying not to be 2, then determine that current address is distributed unsuccessfully.The verification method of modular terminal B2 is identical with modular terminal B1, repeats no more.
It should be noted that, confirmation request is tentatively judging in the successful situation of modular terminal allocation address, whether further checking address assignment is successful, that is display terminal can judge whether the address that multiple modular terminal generates has repetition, modular terminal can judge that whether the confirmation request of display terminal is accurate, to guarantee the situation that there will not be address assignment mistake further.Do not receive the confirmation request carrying random number, and directly have received next round address assignment data, then determine current address assignment failure.
Alternatively, modular terminal also comprises: the second monitoring unit, for after the address assignment success of determination module terminal, monitors the generating random number request that display terminal sends; Judging unit, for judging the random number whether carrying modular terminal generation in generating random number request; Second address transmitting element, for carry in generating random number request modular terminal generate random number time, modular terminal sends destination address to bus; Second call unit, for do not carry in generating random number request modular terminal generate random number time, call allocation units.
Display terminal send one take turns address assignment data after, if the modular terminal in CAN does not have all allocation address, when then again sending address assignment data, display terminal carries the random number of this modular terminal to the address assignment data that modular terminal sends, when modular terminal receives the address assignment data carrying random number, send its address information to CAN.If do not carry the random number that it generates in the address assignment data that modular terminal receives, be then oneself allocation address again.Namely last round of address assignment failure, needs deallocation.
In this embodiment, modular terminal verifies that whether its address distributed is successful for twice, is the confirmation request receiving display terminal transmission for the first time, if confirm that the random number of asking to carry is identical with the random number of its generation, then tentatively determines that address is allocated successfully; Second time is when again receiving address assignment data, alternatively when again receiving random number generation request, if carry random number, then determine that address is allocated successfully, only need send address to CAN, if do not carry random number, then modular terminal is oneself allocation address and generate random number again, according to first time allocation address method deallocation and verify.Each modular terminal can carry out automatic allocation address according to the method described above, until the address of all modular terminals in this CAN is all assigned.Because whether twice checking address becomes the distribution of work, avoid the address assignment mistake of modular terminal or do not distribute caused communication failure, reaching the technique effect that accurate allocation address avoids communication failure.Meanwhile, the data due to CAN transmission are that all modular terminals connected on the bus are shared, and improve the dispensing rate of address.
Embodiment 4
According to the embodiment of the present invention, provide a kind of embodiment of display terminal, this display terminal can perform the automatic point location method of embodiment 2, can be the display terminal shown in Fig. 1, at least two modular terminals and display terminal by dereliction from CAN communicate.Display terminal can say the host computer etc. in air-conditioner control system.
As shown in Figure 7, this display terminal comprises: acquiring unit 70, authentication unit 72, instruction transmitting element 74 and data call unit 76.
Acquiring unit 70 for bus send one take turns address assignment data after, by the response data that bus acquisition module terminal sends, wherein, it is the destination address that himself distributes that response data carries object module terminal, and object module terminal is any one terminal at least two modules.
Authentication unit 72 is for verifying the whether successful allocation address of object module terminal according to the response data got.
Instruction transmitting element 74 is in the successful situation of the address assignment of object module terminal, and display terminal sends the indication information be allocated successfully according to destination address.
Data call unit 76, for when the address assignment failure of object module terminal, calls acquiring unit.
Display terminal sends address assignment data to CAN, namely sends generating random number request to each modular terminal, and receives the destination address that each modular terminal is oneself generation.The destination address that display terminal checking modules terminal sends also is verified.After being verified, sending the information be allocated successfully to this destination address, otherwise resend address assignment data, to allow each modular terminal again for oneself allocation address.Take turns after address assignment data is sent completely one, the address of part of module terminal may be had successfully to determine, also may the address of whole modular terminals can successfully determine.If there is the address of part of module terminal successfully to determine, then again sends one and take turns address assignment data, until the address of remaining all modular terminals can successfully be determined.
By this embodiment, after display terminal sends address assignment data, each modular terminal is oneself allocation address, achieve point location automatically, display terminal is verified the address that modular terminal distributes, what ensure that allocation address does not repeat that make between modules terminal can proper communication, thus solves in prior art and dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks, and then reaches accurately point location and avoid the technique effect of communication failure.
Alternatively, response data carries the random number that object module terminal generates, and authentication unit comprises: address judgment module, for judging whether the address entrained by two response datas first receiving has repetition; First address determination module, during for there being a repetition in the address entrained by two response datas judging first to receive, determines the failure of object module terminal distribution address; Second address determination module, for when the address entrained by two response datas judging first to receive is not repeated, determines the success of object module terminal distribution address.
Under normal circumstances, modular terminal transmits its address distributed for oneself by CAN, other modular terminals can avoid selected address when selecting address, therefore, the modular terminal of time delay same time may select identical address, especially when the address that the first two modular terminal sends is identical, also may make mistakes in the address that modular terminal below sends, therefore, when the address that the first two modular terminal sends is repeated, determine the failure of epicycle address assignment.
Be described for Fig. 1.
Display terminal A is to modular terminal B1, modular terminal B2 ... modular terminal Bn sends address assignment data respectively, and when modular terminal B1 listens to after all address assignment data are all sent, modular terminal B1 is oneself allocation address.If transmission has the address of modular terminal B2 in CAN, then modular terminal B1 is listening to the information taking address of modular terminal B2, the address from modular terminal B2 can be avoided when allocation address, thus avoid identical with the address of modular terminal B2 and cause conflict.
Display terminal A receives the address that each modular terminal sends from CAN, and whether checking has the address of repetition, determine that when there is no the address of repeating this takes turns address assignment success, otherwise this takes turns address assignment failure, re-starts the address assignment of next round.The mode that next round is distributed is identical with the first round, and concrete steps are with reference to foregoing.If after the address of modular terminal B1 is specified to the distribution of work, when next round allocation address, its address is sent to CAN by modular terminal B1, so that other modular terminal calculated addresses.
Be when oneself being assigned with identical address at multiple modular terminal, display terminal determines the address assignment success of which modular terminal according to the delay time of each modular terminal, the address assignment failure of which modular terminal.Modular terminal generates random number after the address assignment data listening to display terminal transmission, and determines delay time according to random number.Because delay time is determined by random number, when the probability that random number is identical is very little, the probability that delay time is identical is also very little, and this facilitates display terminal and carries out address validation.The scope of delay time is at 0 to 22 millisecond.
Such as, the time delay of modular terminal B1 is 2ms, and its address distributed for oneself is 01, the delay time of modular terminal B2 is 4ms, its address distributed for oneself is 11, then modular terminal B1 sends address 01 after time delay 2ms, and modular terminal B2 sends address 11 after time delay 4ms.Do not conflict in the address of display terminal determination module terminal B1 and modular terminal B2, determination module terminal B1 and modular terminal B2 success allocation address.
If modular terminal B1 and modular terminal B2 is the address that oneself distributes be 01, but the time delay of modular terminal B1 is 2ms, the delay time of modular terminal B2 is 4ms, then the address of determination module terminal B1 is 01, the address assignment failure of modular terminal B2.If modular terminal B1 and modular terminal B2 is the address that oneself distributes be 01, and time delay is in 2ms, display terminal cannot determine that the address of which modular terminal is 01, therefore, by judging whether successfully delay time carrys out the address assignment of determination module terminal.
Whether display terminal checking shows identical address to different modular terminals, avoid address assignment error, delay time is verified further when there is identical address, by same address assignment to the shorter modular terminal of delay time, thus ensure that the correctness of the address assignment of modular terminal.
Alternatively, the second address determination module comprises: request generates submodule, confirms request, and confirmation request is sent to destination address for the generating random number according to modular terminal, and confirmation request carries the random number that modular terminal generates; Monitor submodule, for monitoring confirmation response, wherein, confirmation response be random number that modular terminal demonstration validation request corresponding to destination address is carried consistent with the random number that this modular terminal generates time generate; Determine submodule, for when display terminal listens to confirmation response, determine the success of object module terminal distribution address; Call submodule, for when display terminal does not receive the confirmation response, call acquiring unit.
Such as, the time delay of modular terminal B1 is 2ms, random number is 2, and its address distributed for oneself is 01, and the delay time of modular terminal B2 is 4ms, random number is 4, its address distributed for oneself is 01, then display terminal determination display terminal B1 is identical with the address of display terminal B2, then judges delay time further, because the delay time of modular terminal B1 is shorter, then modular terminal B1 is distributed in address 01.Display terminal sends to modular terminal B1 and confirms request, carries random number 2 in this confirmation request, and after modular terminal B1 receives the confirmation request, checking random number 2 is identical with the random number of its generation, then confirm address assignment success.Because the address assignment of modular terminal B2 is unsuccessful, then display terminal is when sending next round address assignment data, sends address assignment data to modular terminal B2.
Display terminal, when sending next round address assignment data, sends the address assignment data carrying random number to modular terminal B1; The address assignment data not having random number is sent to modular terminal B2.
Alternatively, display terminal also comprises: judging unit, and for when display terminal listens to confirmation response, after determining the success of object module terminal distribution address, display terminal judges whether at least two modular terminals all complete address assignment; Data call unit is also for when judging that at least two modular terminals all do not complete address assignment, again send address assignment data at least two modular terminals, wherein, the address assignment data sent to object module terminal carries the random number that object module terminal generates.Modular terminal B1 sends its address distributed to bus, and modular terminal B2 is according to the above-mentioned steps deallocation of the present embodiment.
When having after the address of modular terminal determines, this modular terminal can send its address to CAN, therefore, other do not have the modular terminal of allocation address to select address as the address distributed to oneself in never occupied address, and carry out the process verified.When storage in CAN does not have the modular terminal of allocation address, display terminal all can send one and take turns address assignment data, often take turns address assignment to complete, display terminal can judge whether all modular terminals in CAN all complete address assignment again, if completed, terminate point location automatically, if do not completed, proceed the address assignment of next round, until all modular terminals all complete point location automatically.
By this embodiment, achieve each modular terminal allocation address automatically, and can not conflict in the address between modules terminal, solve in prior art and dial or the technical problem causing unit to occur communication failure of dialing the wrong number because dial-up during manual debugging leaks, and then reach the technique effect that communication failure is avoided in accurate point location.
The invention described above embodiment sequence number, just to describing, does not represent the quality of embodiment.
In the above embodiment of the present invention, the description of each embodiment is all emphasized particularly on different fields, in certain embodiment, there is no the part described in detail, can see the associated description of other embodiments.
In several embodiments that the application provides, should be understood that, disclosed technology contents, the mode by other realizes.Wherein, device embodiment described above is only schematic, the division of such as unit, can be that a kind of logic function divides, actual can have other dividing mode when realizing, such as multiple unit or assembly can in conjunction with or another system can be integrated into, or some features can be ignored, or do not perform.Another point, shown or discussed coupling each other or direct-coupling or communication connection can be by some interfaces, and the indirect coupling of unit or module or communication connection can be electrical or other form.
The unit illustrated as separating component or can may not be and physically separates, and the parts as unit display can be or may not be physical location, namely can be positioned at a place, or also can be distributed on multiple unit.Some or all of unit wherein can be selected according to the actual needs to realize the object of the present embodiment scheme.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, also can be that the independent physics of unit exists, also can two or more unit in a unit integrated.Above-mentioned integrated unit both can adopt the form of hardware to realize, and the form of SFU software functional unit also can be adopted to realize.
If integrated unit using the form of SFU software functional unit realize and as independently production marketing or use time, can be stored in a computer read/write memory medium.Based on such understanding, the part that technical scheme of the present invention contributes to prior art in essence in other words or all or part of of this technical scheme can embody with the form of software product, this computer software product is stored in a storage medium, comprises all or part of step of some instructions in order to make a computer equipment (can be personal computer, server or the network equipment etc.) perform each embodiment method of the present invention.And aforesaid storage medium comprises: USB flash disk, read-only memory (ROM, Read-OnlyMemory), random access memory (RAM, RandomAccessMemory), portable hard drive, magnetic disc or CD etc. various can be program code stored medium.
Below be only the preferred embodiment of the present invention; it should be pointed out that for those skilled in the art, under the premise without departing from the principles of the invention; can also make some improvements and modifications, these improvements and modifications also should be considered as protection scope of the present invention.

Claims (18)

1. an automatic point location method, is characterized in that, at least two modular terminals and display terminal by dereliction from CAN communicate, described method comprises:
Modular terminal is its allocation address according to described address assignment data, obtains destination address after taking turns address assignment data monitored the transmission of described display terminal one;
Described modular terminal sends described destination address to described bus, carries out address validation for described display terminal;
Described modular terminal monitors the confirmation request that described display terminal sends;
If listen to described confirmation request, then using the address of described destination address as himself;
If do not listen to described confirmation request, then returning after taking turns address assignment data has monitored the transmission of described display terminal one is the step of its allocation address according to described address assignment data.
2. method according to claim 1, is characterized in that,
After described modular terminal takes turns address assignment data monitored the transmission of described display terminal one, and before described modular terminal sends described destination address to described bus, described modular terminal generates random number;
Described modular terminal sends described destination address to described bus and comprises: described modular terminal, when reaching delay time, sends described address and described random number to described bus, and wherein, described modular terminal is delay time according to described generating random number.
3. method according to claim 2, is characterized in that, if listen to described confirmation request, is then comprised the address of described destination address as himself:
Judge that whether the described random number confirming that request is carried is consistent with the random number that described modular terminal generates;
If judge that the described random number confirming that request is carried is consistent with the random number that described modular terminal sends, determine the address assignment success of described modular terminal;
If judge describedly to confirm that the random number of asking the random number of carrying and described modular terminal to send is inconsistent, determine the address assignment of described modular terminal unsuccessfully.
4. method according to claim 3, is characterized in that, after the address assignment success determining described modular terminal, described method comprises:
Monitor the generating random number request that described display terminal sends;
Judge the random number whether carrying the generation of described modular terminal in described generating random number request;
When carrying the random number of described modular terminal generation in described generating random number request, described modular terminal sends described destination address to described bus;
When not carrying the random number that described modular terminal generates in described generating random number request, returning after taking turns address assignment data has monitored the transmission of described display terminal one is the step of its allocation address according to described address assignment data.
5. method according to claim 1, is characterized in that, modular terminal is its allocation address according to described address assignment data, obtains destination address and comprise after taking turns address assignment data monitored the transmission of described display terminal one:
Described modular terminal monitors in described bus the data taking address transmitted;
Described modular terminal is searched not by the lowest address used according to the described data having taken address from described address assignment data;
Described modular terminal using the address that finds as described destination address.
6. an automatic point location method, is characterized in that, at least two modular terminals and display terminal by dereliction from CAN communicate, described method comprises:
After described display terminal takes turns address assignment data to described bus transmission one, by the response data that described bus acquisition module terminal sends, wherein, it is the destination address that himself distributes that described response data carries object module terminal, described object module terminal for described in any one terminal at least two modules;
Described display terminal verifies the whether successful allocation address of described object module terminal according to the response data got;
In the successful situation of address assignment of described object module terminal, described display terminal sends the indication information be allocated successfully according to described destination address;
When the address assignment failure of described object module terminal, return described display terminal and send to described bus the step that takes turns address assignment data.
7. method according to claim 6, is characterized in that, described response data carries the random number that described object module terminal generates, according to the response data got, described display terminal verifies that the whether successful allocation address of described object module terminal comprises:
Described display terminal judges whether the address entrained by two response datas of first receiving has repetition;
If judge that there is repetition described address entrained by two response datas of first receiving, then determine the failure of described object module terminal distribution address;
If judge that described address entrained by two response datas of first receiving is not repeated, then determine the success of described object module terminal distribution address.
8. method according to claim 7, is characterized in that, determines that described object module terminal distribution address successfully comprises:
Described display terminal confirms request according to the generating random number of described modular terminal, and described confirmation request is sent to described destination address, and described confirmation request carries the random number that described modular terminal generates;
Confirmation response monitored by described display terminal, wherein, described confirmation response be the described random number confirming to ask to carry of modular terminal checking corresponding to described destination address consistent with the random number that this modular terminal generates time generate;
When described display terminal listens to described confirmation response, determine the success of described object module terminal distribution address;
When described display terminal does not receive described confirmation response, return described display terminal and send to described bus the step that takes turns address assignment data.
9. method according to claim 8, is characterized in that, when described display terminal listens to described confirmation response, after determining the success of described object module terminal distribution address, described method also comprises:
Described in described display terminal judges, whether at least two modular terminals all complete address assignment;
If described display terminal judge described at least two modular terminals all do not complete address assignment, then again send address assignment data to described at least two modular terminals, wherein, the address assignment data sent to described object module terminal carries the random number that described object module terminal generates.
10. a modular terminal, is characterized in that, at least two modular terminals and display terminal by dereliction from CAN communicate, described modular terminal comprises:
Allocation units, after taking turns address assignment data monitored the transmission of described display terminal one, are its allocation address according to described address assignment data, obtain destination address;
First address transmitting element, for sending described destination address to described bus, carries out address validation for described display terminal;
First monitoring unit, for monitoring the confirmation request that described display terminal sends;
Determining unit, for when listening to described confirmation request, using the address of described destination address as himself;
First call unit, for when not listening to described confirmation request, calls described allocation units.
11. modular terminals according to claim 10, is characterized in that,
Generation unit, after taking turns address assignment data monitored the transmission of described display terminal one, and before described modular terminal sends described destination address to described bus, generates random number;
Described first address transmitting element, also for when reaching delay time, sends described address and described random number to described bus, and wherein, described modular terminal is delay time according to described generating random number.
12. modular terminals according to claim 11, is characterized in that, described determining unit comprises:
Judge module, whether consistent with the random number that described modular terminal generates for judging the described random number confirming that request is carried;
First determination module, for when judging that the described random number confirming to ask to carry is consistent with the random number that described modular terminal sends, determines the address assignment success of described modular terminal;
Second determination module, for when judging the random number that described confirmation asks to carry and the random number that described modular terminal sends is inconsistent, determines the address assignment failure of described modular terminal.
13. modular terminals according to claim 12, is characterized in that, described modular terminal also comprises:
Second monitoring unit, for after the address assignment success determining described modular terminal, monitors the generating random number request that described display terminal sends;
Judging unit, for judging the random number whether carrying the generation of described modular terminal in described generating random number request;
Second address transmitting element, for carry in described generating random number request described modular terminal generate random number time, described modular terminal sends described destination address to described bus;
Second call unit, for do not carry in described generating random number request described modular terminal generate random number time, call described allocation units.
14. modular terminals according to claim 10, is characterized in that, described allocation units comprise:
Monitor module, for monitoring in described bus the data taking address transmitted;
Search module, for searching not by the lowest address used from described address assignment data according to the described data having taken address;
3rd determination module, for the address that will find as described destination address.
15. 1 kinds of display terminals, is characterized in that, at least two modular terminals and display terminal by dereliction from CAN communicate, described display terminal comprises:
Acquiring unit, after taking turns address assignment data to described bus transmission one, by the response data that described bus acquisition module terminal sends, wherein, it is the destination address that himself distributes that described response data carries object module terminal, described object module terminal for described in any one terminal at least two modules;
Authentication unit, for verifying the whether successful allocation address of described object module terminal according to the response data got;
Instruction transmitting element, in the successful situation of address assignment of described object module terminal, described display terminal sends the indication information be allocated successfully according to described destination address;
Data call unit, for when the address assignment failure of described object module terminal, calls described acquiring unit.
16. display terminals according to claim 15, is characterized in that, described response data carries the random number that described object module terminal generates, and described authentication unit comprises:
Address judgment module, for judging whether the address entrained by two response datas first receiving has repetition;
First address determination module, for when judging that there is repetition the address entrained by described two response datas first received, determines the failure of described object module terminal distribution address;
Second address determination module, for when judging that the address entrained by described two response datas first received is not repeated, determines the success of described object module terminal distribution address.
17. display terminals according to claim 16, is characterized in that, described second address determination module comprises:
Request generates submodule, and confirm request for the generating random number according to described modular terminal, and described confirmation request is sent to described destination address, described confirmation request carries the random number that described modular terminal generates;
Monitor submodule, for monitoring confirmation response, wherein, to be that modular terminal checking corresponding to described destination address is described confirm to generate when asking the random number of carrying consistent with the random number that this modular terminal generates in described confirmation response;
Determine submodule, for when described display terminal listens to described confirmation response, determine the success of described object module terminal distribution address;
Call submodule, for when described display terminal does not receive described confirmation response, call described acquiring unit.
18. display terminals according to claim 17, is characterized in that, described display terminal also comprises:
Judging unit, for when described display terminal listens to described confirmation response, after determining the success of described object module terminal distribution address, described in described display terminal judges, whether at least two modular terminals all complete address assignment;
Described data call unit is not also for when described in judging, at least two modular terminals all complete address assignment, again send address assignment data to described at least two modular terminals, wherein, the address assignment data sent to described object module terminal carries the random number that described object module terminal generates.
CN201510771758.XA 2015-11-11 2015-11-11 Automatically divide location method, display terminal and modular terminal Active CN105338129B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510771758.XA CN105338129B (en) 2015-11-11 2015-11-11 Automatically divide location method, display terminal and modular terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510771758.XA CN105338129B (en) 2015-11-11 2015-11-11 Automatically divide location method, display terminal and modular terminal

Publications (2)

Publication Number Publication Date
CN105338129A true CN105338129A (en) 2016-02-17
CN105338129B CN105338129B (en) 2019-03-22

Family

ID=55288399

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510771758.XA Active CN105338129B (en) 2015-11-11 2015-11-11 Automatically divide location method, display terminal and modular terminal

Country Status (1)

Country Link
CN (1) CN105338129B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111131536A (en) * 2019-12-09 2020-05-08 珠海格力电器股份有限公司 Efficient configuration method, device and system for communication address and electric meter
CN111586206A (en) * 2020-05-29 2020-08-25 四川艾贝斯科技发展有限公司 Automatic reporting method for address number of single-lamp controller for street lamp system
CN111711471A (en) * 2020-06-12 2020-09-25 江苏集能易新能源技术有限公司 Method for realizing power line carrier communication ad hoc network
CN112665035A (en) * 2021-01-19 2021-04-16 青岛海信日立空调系统有限公司 Multi-connected air conditioning system and control method thereof
CN113612868A (en) * 2021-08-06 2021-11-05 深圳市欧瑞博科技股份有限公司 Equipment address allocation method, device and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6700877B1 (en) * 1997-08-05 2004-03-02 Siemens Aktiengesellschaft Method and bus system for automatic address allocation
CN1655081A (en) * 2004-02-10 2005-08-17 上海新时达电气有限公司 Allocator for automatically allocating address to serial bus device and method for controlling the same
CN102292682A (en) * 2008-11-25 2011-12-21 皮尔茨公司 Method for transferring data in an automated control system
CN202528858U (en) * 2012-02-28 2012-11-14 华霆(合肥)动力技术有限公司 Electromobile battery management system
CN103676833A (en) * 2013-09-25 2014-03-26 江苏峰谷源储能技术研究院有限公司 An automatic configuration and correction method for battery electronic component communication addresses

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6700877B1 (en) * 1997-08-05 2004-03-02 Siemens Aktiengesellschaft Method and bus system for automatic address allocation
CN1655081A (en) * 2004-02-10 2005-08-17 上海新时达电气有限公司 Allocator for automatically allocating address to serial bus device and method for controlling the same
CN102292682A (en) * 2008-11-25 2011-12-21 皮尔茨公司 Method for transferring data in an automated control system
CN202528858U (en) * 2012-02-28 2012-11-14 华霆(合肥)动力技术有限公司 Electromobile battery management system
CN103676833A (en) * 2013-09-25 2014-03-26 江苏峰谷源储能技术研究院有限公司 An automatic configuration and correction method for battery electronic component communication addresses

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111131536A (en) * 2019-12-09 2020-05-08 珠海格力电器股份有限公司 Efficient configuration method, device and system for communication address and electric meter
CN111131536B (en) * 2019-12-09 2021-07-13 珠海格力电器股份有限公司 Efficient configuration method, device and system for communication address and electric meter
CN111586206A (en) * 2020-05-29 2020-08-25 四川艾贝斯科技发展有限公司 Automatic reporting method for address number of single-lamp controller for street lamp system
CN111586206B (en) * 2020-05-29 2022-05-31 四川艾贝斯科技发展有限公司 Automatic reporting method for address number of single lamp controller of street lamp system
CN111711471A (en) * 2020-06-12 2020-09-25 江苏集能易新能源技术有限公司 Method for realizing power line carrier communication ad hoc network
CN112665035A (en) * 2021-01-19 2021-04-16 青岛海信日立空调系统有限公司 Multi-connected air conditioning system and control method thereof
CN113612868A (en) * 2021-08-06 2021-11-05 深圳市欧瑞博科技股份有限公司 Equipment address allocation method, device and system
CN113612868B (en) * 2021-08-06 2023-08-29 深圳市欧瑞博科技股份有限公司 Equipment address allocation method, device and system

Also Published As

Publication number Publication date
CN105338129B (en) 2019-03-22

Similar Documents

Publication Publication Date Title
CN105338129A (en) Automatic address dividing method, display terminal, and module terminal
CN101852472B (en) Automatic addressing method for air conditioning system and air conditioning controller
CN107734714B (en) Random access method and device in wireless communication system and user terminal
CN105430118B (en) A kind of MAC Address generation method and device
CN104101048A (en) Setting method for communication address of indoor unit in air conditioning system and air conditioning system
EP1471661A1 (en) Packet communication between a collecting unit and a plurality of control devices over the power supply line
US9313605B2 (en) Wireless communication system and information providing method
CN109654666B (en) Method, device and equipment for debugging unit
CN103168292A (en) Method for monitoring at least two microcontrollers
CN112671584B (en) Network topology identification method, device, system and storage medium
CN105940751A (en) Wireless communication system, wireless communication device, wireless communication method, and program
CN113114545B (en) Equipment ad hoc network method and device and air conditioning system
CN112272243A (en) Address allocation method
CN103856578A (en) Automatic slave station address acquisition method through Modbus RTU and slave station
CN112152887A (en) Network distribution method and device of household appliance, electronic device and storage medium
CN113114792A (en) Equipment ad hoc network method and device and air conditioning system
KR20160106064A (en) Method for starting a battery management system
CN115657646B (en) Test method and device of CAN controller
CN104283739A (en) Detection method and device based on distributed ISSU
CN113612868B (en) Equipment address allocation method, device and system
CN115334041A (en) Method for automatically allocating addresses to communication equipment of master station and slave station, master station, slave station and system
CN101783712B (en) Method, user terminal and network node for identifying LTE (Long Term Evolution) version
CN109245934B (en) Fault processing method, device, system, control equipment and management equipment
CN108068733B (en) Information configuration method and device and computer readable storage medium
CN112788636A (en) Method and device for determining cell state and network management system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant