The interface system of unmanned vehicle and interface control methodTechnical field
The present invention relates to unmanned vehicle technical field, particularly relate to a kind of unmanned vehicleInterface system and interface control method.
Background technology
Unmanned vehicle (also referred to as unmanned vehicle, unmanned plane etc.) be a kind of with wireless remotecontrol orThe person's unmanned aircraft under autonomous, half independent procedure control.Owing to its cost is relatively low, without personnelInjures and deaths risk, the advantages such as mobility is good, its all kinds of Aerial photographies, geological survey, line data-logging, shouldFirst aid the field such as is helped and is widely used.Wherein, due to integrated circuit and the development of microsystems technology so that nothingThe microminiaturization of people's aircraft is achieved, and have greatly expanded the executable task type of unmanned vehicle.RootDifferent according to performed task according to small unmanned vehicle, it usually needs to carry different load.
Owing to task is of a great variety, so the power rail number needed for load type extreme enrichment, all kinds of loadAmount, holding wire quantity, interface protocol mode vary, and existing general-purpose interface technology is difficult to fly smallThe generalization of all load is realized in the case of row device is size-constrained.
Summary of the invention
Technical problem
In view of this, the technical problem to be solved in the present invention is, how to provide a kind of unmanned vehicleGeneral interface system.
Solution
In order to solve above-mentioned technical problem, according to one embodiment of the invention, it is provided that a kind of unmannedThe interface system of aircraft, including:
Physical interface, including multiple pins;
At least one protocol conversion module, for the communication according to the target load accessing described physical interfaceProtocol type, communicates the conversion of agreement to described target load;
I/O drives by force module, is connected respectively with described protocol conversion module and described physical interface, is used forConfiguration data according to described target load and communication protocol type, enter each pin of described physical interfaceRow cutting;
Master controller, drives by force module respectively with described physical interface, protocol conversion module and described I/OConnect, for the configuration data according to described target load, configure the merit of each pin of described physical interfaceEnergy;The communication protocol type of described target load is determined according to described configuration data, and according to described targetThe communication protocol type of load configures the function of described protocol conversion module;Mould is driven by force through described I/OBlock and described protocol conversion module communicate with described target load, and perform the merit of described target loadEnergy.
For said system, in a kind of possible implementation, also include:
Insert detection and identification module;For whether described physical interface is inserted target load insertDetection and identification.
For said system, in a kind of possible implementation, described insertion is detected and identification module bagInclude:
Insert detector unit, for inserting detection and identifying the voltage of pin according to described physical interfaceValue, it is judged that whether described physical interface inserts described target load;
Load recognition unit, is connected with described insertion detector unit, for sentencing in described insertion detector unitIn the case of being set to the described target load of insertion, insert detection by described and identify pin from described targetLoad reads configuration data, and described configuration data are verified.
For said system, in a kind of possible implementation, described insertion detector unit is additionally operable toDetect described target load in the case of described physical interface is extracted, control described I/O and drive by forceModule disconnects, and controls described protocol conversion module and quits work, and indicates described insertion detector unit to continueCarry out inserting detection.
For said system, in a kind of possible implementation, described physical interface includes general purpose I/OPin, described general purpose I/O pin drives by force module to be connected with described I/O.
For said system, in a kind of possible implementation,
Described master controller is additionally operable to, according to described configuration data, configure the function of each general purpose I/O pin;
It is defeated that described I/O drives by force module to be additionally operable to the first general purpose I/O pin configuration at described master controllerIn the case of entering, control described first general purpose I/O pin and lead directly to described protocol conversion module;DescribedIn the case of second general purpose I/O pin configuration is numeral output by master controller, control described second generalI/O pin leads directly to described protocol conversion module;At described master controller by the 3rd general I/O pin configurationIn the case of strong output, send after the signal received from described protocol conversion module is carried out enhancement processTo described 3rd general I/O pin;It is that power supply is defeated at described master controller by the 4th general I/O pin configurationIn the case of going out, control described 4th general I/O pin and lead directly to corresponding power rail.
For said system, in a kind of possible implementation, described physical interface also includes inserting inspectionSurveying and identify pin and grounding pin, described master controller is additionally operable to control described insertion detection and draws with identificationFoot with insert detection be connected with identification module, described grounding pin be systematically connected.
The present invention also provides for the interface control method of a kind of unmanned vehicle, described nolo flightThe physical interface of device includes multiple pin;
Described method includes:
According to the configuration data of the target load accessing described physical interface, configure each of described physical interfaceThe function of pin;
The communication protocol type of described target load is determined according to described configuration data, and according to described targetThe function of the communication protocol type configuration protocol modular converter of load;
Drive by force module and described protocol conversion module to communicate with described target load through I/O, andPerform the function of described target load.
For said method, in a kind of possible implementation, also include:
Whether described physical interface inserts target load carry out inserting detection and identifying.
For said method, in a kind of possible implementation, whether described physical interface is inserted meshMark load carries out inserting detection and identifying, including:
The magnitude of voltage inserting detection and identification pin according to described physical interface, it is judged that described physical interfaceWhether insert described target load;
Judging that described physical interface inserts in the case of described target load, by described insert detection withIdentify that pin reads configuration data from described target load, and described configuration data are verified.
For said method, in a kind of possible implementation, also include:
Detecting described target load in the case of described physical interface is extracted, controlling described I/OStrong driving module disconnects, and controls described protocol conversion module and quits work, and return proceeds to insert inspectionSurvey.
For said method, in a kind of possible implementation, described physical interface includes general purpose I/OPin, described general purpose I/O pin drives by force module to be connected with described I/O, and described method also includes:
According to described configuration data, configure the function of each general purpose I/O pin.
For said method, in a kind of possible implementation, described according to described configuration data, joinPut the function of each general purpose I/O pin, including:
In the case of the first general purpose I/O pin configuration is input by master controller, described I/O drives by force mouldBlock controls described first general purpose I/O pin and leads directly to described protocol conversion module;
In the case of the second general purpose I/O pin configuration is numeral output by master controller, described I/O drives by forceDynamic model block controls described second general purpose I/O pin and leads directly to described protocol conversion module;
In the case of the 3rd general I/O pin configuration is strong output by master controller, described I/O drives by forceThe module signal to receiving from described protocol conversion module sends to described threeway after carrying out enhancement processUse I/O pin;
In the case of the 4th general I/O pin configuration is power supply output by described master controller, described I/OStrong driving module controls described 4th general I/O pin and leads directly to corresponding power rail.
For said method, in a kind of possible implementation, described physical interface also includes inserting inspectionSurveying and identify pin and grounding pin, described method also includes:
Insert detection described in main controller controls and identify that pin is connected with identification module with inserting detection, andControl described grounding pin and be systematically connected.
Beneficial effect
The embodiment of the present invention is capable of identify that the configuration data of the target load of insertion, each in configuration physical interfaceThe function of pin, to adapt to the requirement of various target load docking port, protocol conversion module can be by targetIn load, any defined protocol translation is that unified puppy parc is to realize target load and unmanned planeThe communication of master controller.By the embodiment of the present invention, the load of unmanned plane can be with less pin and thingReason interface size realizes bigger versatility, greatly strengthens the extensibility of unmanned plane.
Interface control method and interface system involved by the embodiment of the present invention can own by self-adjusted blockLink pin for power supply or data-interface, be adapted to arbitrary power rail, track and holding wire quantity,Holding wire can realize any defined interface protocol by interface switching device.
According to below with reference to the accompanying drawings to detailed description of illustrative embodiments, other of the embodiment of the present invention is specialLevy and aspect will be clear from.
Accompanying drawing explanation
The accompanying drawing of the part comprising in the description and constituting description together illustrates with descriptionThe exemplary embodiment of the present invention, feature and aspect, and for explaining the principle of the present invention.
Fig. 1 illustrates the structural representation of the interface system of unmanned vehicle according to an embodiment of the inventionFigure;
Fig. 2 illustrates that the structure of the interface system of unmanned vehicle according to another embodiment of the present invention is shownIt is intended to;
Fig. 3 illustrates the flow process of the interface control method of unmanned vehicle according to an embodiment of the inventionSchematic diagram;
Fig. 4 illustrate unmanned vehicle according to an embodiment of the invention interface control method anotherSchematic flow sheet;
Fig. 5 illustrates the stream of the interface control method of unmanned vehicle according to another embodiment of the present inventionJourney schematic diagram.
Detailed description of the invention
Various exemplary embodiments, feature and the aspect of the present invention is described in detail below with reference to accompanying drawing.AttachedReference identical in figure represents the same or analogous element of function.Although enforcement shown in the drawingsThe various aspects of example, but unless otherwise indicated, it is not necessary to accompanying drawing drawn to scale.
The most special word " exemplary " means " as example, embodiment or illustrative ".Here asAny embodiment illustrated by " exemplary " should not necessarily be construed as preferred or advantageous over other embodiments.
It addition, in order to better illustrate the present invention, detailed description of the invention below gives numerousDetail.It will be appreciated by those skilled in the art that do not have some detail, the present invention is equallyImplement.In some instances, for method well known to those skilled in the art, means, element and circuitIt is not described in detail, in order to highlight the purport of the present invention.
Embodiment 1
Fig. 1 illustrates the structural representation of the interface system of unmanned vehicle according to an embodiment of the inventionFigure.As it is shown in figure 1, the interface system of this unmanned vehicle mainly may include that
Physical interface 11, including multiple pins;
At least one protocol conversion module 13, for according to the target load 12 accessing described physical interface 11Communication protocol type, described target load 12 is communicated the conversion of agreement;
I/O (input/output, i.e. input/output end port) drives by force module 15, with described protocol conversionModule 13 and described physical interface 11 connect respectively, for according to the configuration data of described target load 12 andCommunication protocol type, is driven each pin of described physical interface 11;
Master controller 17, drives by force module with described physical interface 11, protocol conversion module 13 and described I/O15 connect respectively, for the configuration data according to described target load 12, configure described physical interface 11The function of each pin;The communication protocol type of described target load 12 is determined according to described configuration data, andCommunication protocol type according to described target load 12 configures the function of described protocol conversion module 13;Pass throughDescribed I/O drives by force module 15 and described protocol conversion module 13 to communicate with described target load 12,And perform the function of described target load 12.
The embodiment of the present invention is capable of a kind of general-purpose interface system being applied to small unmanned vehicle loadSystem, provides power supply supply and data transmission etc. by interface for the payload arbitrarily meeting this interface standardFunction.
Embodiment 2
Fig. 2 illustrates that the structure of the interface system of unmanned vehicle according to another embodiment of the present invention is shownIt is intended to.The assembly that in Fig. 2, label is identical with Fig. 1 has identical function, for simplicity's sake, omits thisThe detailed description of a little assemblies.
As in figure 2 it is shown, the differring primarily in that of the present embodiment and a upper embodiment, this nolo flightThe interface system of device can also include:
Insert detection and identification module 21;For whether described physical interface 11 is inserted target load 12 enterRow inserts detection and identifies.
In a kind of possible implementation, described insertion detection includes with identification module 21:
Insert detector unit, for inserting detection and identifying the voltage of pin according to described physical interface 11Value, it is judged that whether described physical interface 11 inserts described target load 12;
Load recognition unit, is connected with described insertion detector unit, for sentencing in described insertion detector unitIn the case of being set to the described target load 12 of insertion, insert detection by described and identify pin from described meshMark load 12 reads configuration data, and described configuration data are verified.
In a kind of possible implementation, described insertion detector unit is additionally operable to detecting described meshMark load 12, in the case of described physical interface 11 is extracted, controls described I/O and drives by force module 15 to disconnect,Control described protocol conversion module 13 to quit work, and indicate described insertion detector unit to proceed to insertDetection.
In a kind of possible implementation, described physical interface 11 includes general purpose I/O pin, described generalI/O pin drives by force module 15 to be connected with described I/O.
In a kind of possible implementation, described master controller 17 is additionally operable to according to described configuration data,Configure the function of each general purpose I/O pin;
Described I/O drives by force module 15 to be additionally operable to the first general purpose I/O pin configuration at described master controller 17In the case of input, control described first general purpose I/O pin and lead directly to described protocol conversion module 13;In the case of the second general purpose I/O pin configuration is numeral output by described master controller 17, control describedSecond general purpose I/O pin leads directly to described protocol conversion module 13;At described master controller 17 by threewayIn the case of being strong output with I/O pin configuration, the signal received from described protocol conversion module 13 is enteredSend to described 3rd general I/O pin after row enhancement process, in this case, drive by force mould through I/OThe driving force of signal after block 15 processes strengthens, and the signal level and the of protocol conversion module 13 outputThe signal level of three general I/O pins is identical;At described master controller 17 by the 4th general I/O pin configurationIn the case of exporting for power supply, control described 4th general I/O pin and lead directly to corresponding power rail.
In a kind of possible implementation, described physical interface 11 also includes inserting detection and identifying pinAnd grounding pin, described master controller 17 be additionally operable to described insert detection with identify pin with insert detection withIdentification module 21 is connected, described grounding pin be systematically connected.
Specifically, as in figure 2 it is shown, target load 12 is detected by physical interface 11 with inserting and identifies mouldBlock 21 connects, and inserts and judges the insert action of target load 12 with detection module, and identifies targetThe features such as the concrete model of load 12.Described target load 12 drives by force module 15 by physical interface 11 with I/OBeing connected, be attached with protocol conversion module 13 further, wherein I/O drives by force module 15 to strengthen associationThe output signal driving force of view modular converter 13.Unmanned plane master controller 17 and insertion detect and identify mouldBlock 21 is connected, and completes the identification of load.Unmanned plane master controller 17 is by such as USB (UniversalSerial Bus, USB (universal serial bus)) agreement is connected with protocol conversion module 13, it is achieved with the communication of load.Unmanned plane master controller 17 is logical drives by force module 15 to be connected with I/O, and I/O drives by force the functional configuration of module 15.
Wherein, each functions of modules is described below:
1) unmanned plane master controller 17: this part can be made up of application processor and peripheral circuit thereof;
2) target load 12: this part connects into the physical interface of small unmanned vehicle, are used for realizingThe load of certain function.Target load 12 include but not limited to video camera, The Cloud Terrace, mechanical arm, searchlight,Smoking device etc..Target load 12 should at least possess: memorizer (such as Flash chip), insertion detectionWith identification pin, grounding pin 4, general purpose I/O pin 1.Wherein target load 12 and physical interface 11Middle insertion is detected and identifies that output level clamper to such as 3.3V, target are carried by clamp diode by pinThe general purpose I of numbered the 0 of lotus 12/O pin is connected to the system power supply of load system, the data of Flash chipWith inserting, mouth detects and identifies that pin is connected;
3) physical interface 11: this part is the actual thing that small unmanned vehicle is connected with target load 12Reason interface 11, including some connected pins.Such as, physical interface 11 can comprise 1 insertion detectionWith identification pin, 4 grounding pins, some general purpose I/O pins etc..Insert detection and identify pin and insertEntering detection to be connected with identification module 21, general purpose I/O pin drives by force module 15 to be connected with I/O, grounding pinBe systematically connected;
4) detection and identification module 21 are inserted: this part includes insertion detection circuit and load identification module,Insertion detection is pulled to such as 3.6V electricity with identification pin by such as 100K resistance by insertion detection circuitSource, inserting detection and identifying pin is high resistant input.Load identification module, by inserting detection and identifyingPin utilizes such as 1-Wire agreement to communicate with the target load 12 of insertion, obtains target load 12Configuration data.
5) protocol conversion module 13: protocol conversion module 13 can be made up of such as PLD.Protocol conversion module 13 is according to inserting detection and the identification module 21 recognition result to target load 12, by nothingIt is reprogrammed with the communication Protocol Conversion realizing supporting load as standard by man-machine master controller 17USB device is connected with master control, completes the bridging functionality of communication;
6) I/O drives by force module 15: this module is for driving by force general purpose I/O pin output, if nothingCertain general purpose I/O pin configuration of physical interface is input by man-machine master controller 17, then I/O drives by force module15 control this pin leads directly to protocol conversion module 13.If certain general purpose I/O is drawn by unmanned plane master controller 17Foot is configured to numeral output, then I/O drives by force module 15 to control this pin and protocol conversion module 13 leads directly to.If certain general purpose I/O pin configuration is strong output by unmanned plane master controller 17, then I/O drives by force module 15 to controlMake this pin to be connected with by I/O drive circuit protocol conversion module 13.If unmanned plane master controller 17 willCertain general purpose I/O pin configuration is power supply output, then I/O drives by force module 15 to control this pin and corresponding powerRail is connected.
Embodiment 3
Fig. 3 illustrates the flow process of the interface control method of unmanned vehicle according to an embodiment of the inventionSchematic diagram.
The present embodiment interface control method can apply to as shown in Figure 1, Figure 2 in shown in any one structureUnmanned vehicle interface system in.
As it is shown on figure 3, the interface control method of this unmanned vehicle mainly may include that described sideMethod includes:
Step 401, according to accessing the configuration data of target load of described physical interface, configure described thingThe function of each pin of reason interface;
Step 402, determine the communication protocol type of described target load, and root according to described configuration dataFunction according to the communication protocol type configuration protocol modular converter of described target load;
Step 403, module and described protocol conversion module is driven by force to carry out with described target load through I/OCommunication, and perform the function of described target load.
In a kind of possible implementation, as shown in Figure 4, before step 401, the method also includes:
Step 400, whether physical interface is inserted target load carry out insert detection with identify.If inspectionMeasure target load and inserted physical interface, and successfully identified this target load, then perform step 401.
Specifically, step 400 may include that
Step 4001, inserting detection and identifying the magnitude of voltage of pin according to described physical interface, it is judged that instituteState whether physical interface inserts described target load;
Step 4002, judging that described physical interface inserts in the case of described target load, by describedInsert detection and identify that pin reads configuration data from described target load, and described configuration data are enteredRow verification.
In a kind of possible implementation, after step 403, the method also includes:
Step 404, detecting by described target load in the case of described physical interface is extracted, controlMaking described I/O drives by force module to disconnect, and controls described protocol conversion module and quits work, and returns continuationCarry out inserting detection.
In a kind of possible implementation, the physical interface of unmanned plane includes multiple pin, such as, thingReason interface includes general purpose I/O pin, and described general purpose I/O pin drives by force module to be connected with described I/O, describedMethod also includes: step 406, according to described configuration data, configures the function of each general purpose I/O pin.
Specifically, step 406 can include situations below any one or multiple:
In the case of the first general purpose I/O pin configuration is input by master controller, described I/O drives by force mouldBlock controls described first general purpose I/O pin and leads directly to described protocol conversion module;
In the case of the second general purpose I/O pin configuration is numeral output by master controller, described I/O drives by forceDynamic model block controls described second general purpose I/O pin and leads directly to described protocol conversion module;
In the case of the 3rd general I/O pin configuration is strong output by master controller, described I/O drives by forceThe module signal to receiving from described protocol conversion module sends to described threeway after carrying out enhancement processUse I/O pin;
In the case of the 4th general I/O pin configuration is power supply output by described master controller, described I/OStrong driving module controls described 4th general I/O pin and leads directly to corresponding power rail.
In a kind of possible implementation, described physical interface also include insert detection with identify pin andGrounding pin, described method also includes:
Insert detection described in step 407, main controller controls and identify pin and insert detection and identify mouldBlock is connected, and controls described grounding pin and be systematically connected.
Wherein, the sequential of step 406 and step 407 can be exchanged, it is also possible to perform simultaneously, the present embodimentThe most specifically limit.
Embodiment 4
Fig. 5 illustrates the stream of the interface control method of unmanned vehicle according to another embodiment of the present inventionJourney schematic diagram.
As it is shown in figure 5, carry out an exemplary mistake of Interface Controller for the interface system of embodiment 1,2Journey, can be divided into following steps: insert detection-phase 501, cognitive phase 502, the connection establishment stage 503,Stage of communication 504, extract the stage 505.
Insert detection-phase 501: this stage unmanned plane master controller 17 constantly reads insertion detection and identifiesPin voltage value, if 3.6V is then judged as being not inserted into load, remains in insertion detection-phase.IfReading voltage is 3.3V (the clamp diode impact on loaded), then it is assumed that already inserted into payload,Enter cognitive phase.This stage protocol modular converter 13 does not works, and I/O drives by force module 15 to be in disconnectionState;
Cognitive phase 502: this stage first driven by force by I/O module 15 drive the general purpose I/O of numbered 0 toSystem power supply, load numeral power supply electrifying also starts, and inserts detection and the load identification in identification module 21Module reads the configuration data in the Flash in target load 12 by 1-Wire agreement and verifies.IfVerification is passed through, then enter the connection establishment stage, if verification is not passed through, returns to insert detection-phase;
The connection establishment stage 503: first this stage is inserted according in cognitive phase by unmanned plane master controller 17Enter detection and joining in the Flash in the target load 12 of the load identification module reading in identification module 21Put data determine all general purpose I/O pin in physical interface 11 function (input, numeral output, export by forceOr power supply exports), and configuration I/O drives by force module 15 on this basis.Afterwards by unmanned plane main controlDevice 17 determines the communication protocol type of load according to configuration data, and is followed successively by according to configuration protocol modulus of conversionBlock 13.Attempted driving by force through protocol conversion module 13 and I/O by unmanned plane master controller 17 after having configuredDynamic model block 15 initiates communication request to target load 12, if obtaining correct response, enters stage of communication, noThen return to cognitive phase;
Stage of communication 504: this stage is strong through protocol conversion module 13 and I/O by unmanned plane master controller 17Module 15 and target load 12 is driven to communicate and perform loading functionality, unmanned plane master controller 17 simultaneouslyConstantly read the magnitude of voltage inserting detection with identifying pin, if magnitude of voltage is 3.6V, enter the stage of extracting,Otherwise it is maintained at stage of communication;
Extract the stage 505: this stage is controlled I/O by unmanned plane master controller 17 and drives by force module 15 to return to breakOpen state, control protocol modular converter 13 quits work, and enters afterwards and inserts detection-phase.
Embodiments provide the general load of the complete set that can be applied to small unmanned vehicleLotus interface system and control method, in implementing, this interface system can be that load provides reconfigurableCut-in method, system be capable of identify that insertion target load configuration data the general purpose I/O in interface is joinedIt is set to several functions, to adapt to the requirement of various target load docking port.Protocol conversion module is permissible simultaneouslyThe usb protocol that defined protocol translation any on target load is unified is realized target load and nothingThe communication of man-machine master controller.By the embodiment of the present invention, the load of small unmanned plane can be with lessPin and physical interface size realize bigger versatility, greatly strengthen the extensibility of small unmanned plane.
The above, the only detailed description of the invention of the present invention, but protection scope of the present invention is not limited toIn this, any those familiar with the art, can be easily in the technical scope that the invention disclosesExpect change or replace, all should contain within protection scope of the present invention.Therefore, the protection of the present inventionScope should be as the criterion with described scope of the claims.