Summary of the invention
The application provides a kind of equipment detection method and device, is equipped with shape to device element to more acurrate conveniently realize
Detect to state.
In a first aspect, the application provides a kind of equipment detection method, this method comprises: obtaining first from the mainboard of equipment
The register information of device, the register information of the first device are used to indicate the fit state of the first device.According to the first device
Register information, determine the fit state of the first device.For a device of equipment, completed in the device equipped
When, the information when information in the device register can not complete equipped from the device in register is different, and this programme passes through reading
The register information for taking device determines that the register information of current device is the register information or not when completing fit state
Register information when completing equipped, the fit state of device is determined with this.The deposit of device when due to fit state difference
There are difference for device information, and register information is easily readable, therefore this programme can be realized accurately and quickly and be equipped with shape to device
The detection of state.
In one possible implementation, the above-mentioned register information according to the first device, determines matching for the first device
Dress state, comprising: if the register information of the first device includes the first information, it is determined that the fit state of the first device is equipped
It completes.Alternatively, if the register information of the first device does not include the first information, it is determined that the fit state of the first device is equipped
It does not complete.In the program, the first information is that the first device is equipped with the information just appeared in the first device register when completing,
By judging whether the register information of first device includes fit state that the first information can determine whether the first device.
Further, above-mentioned first device can be camera, then the first information can be the sensor information of camera.
Or above-mentioned first device can be display screen, then the first information can be the starting information of display screen.In the program, camera
Sensor information the information in camera register is appeared in when to be that camera is equipped complete, the starting information of display screen is aobvious
Display screen is equipped to appear in information in display screen register when completing, thus can be determined by the present processes camera or
The fit state of person's display screen.
In another possible implementation, the above-mentioned register information according to first device determines described
The fit state of one device, comprising: if the register information of the first device includes the second information, it is determined that the first device is equipped with
State is equipped completes.Alternatively, if the register information of the first device includes third information, it is determined that the equipped shape of the first device
State is equipped do not complete.It is different according to the fit state of the first device in the program, it will appear difference in the first device register
Information, be the equipped shape that the second information or third information can determine the first device according to the information in the first register
State.
Further, above-mentioned first device is any one following device: camera, display screen.By judging camera
It perhaps include that the second information or third information can determine camera or display screen in the register information in display screen
Fit state.
In one possible implementation, obtained in the above-mentioned mainboard from equipment the first device register information it
Before, further includes: determine circuit communication between the platelet and/or flexible circuit board and the mainboard of equipment of equipment.When the platelet of equipment
And/or flexible circuit board is equipped with when completing, and may be implemented electric between the platelet and/or flexible circuit board and the mainboard of equipment of equipment
Road connection, to realize the register information for obtaining the first device from mainboard.
Second aspect, the application provide a kind of assembly detection apparatus, which includes: acquiring unit and detection unit.Its
In, acquiring unit is used to obtain the register information of the first device from the mainboard of equipment, and the register information of the first device is used
In the fit state for indicating first device.Detection unit determines described for the register information according to the first device
The fit state of one device.Letter for a device of equipment, when the device completes equipped, in the device register
Information when breath can not complete equipped from the device in register is different, and this programme is by the register information of reading device, really
Register letter when the register information for determining current device is register information when completing fit state or does not complete equipped
Breath, the fit state of device is determined with this.There are difference for the register information of device when due to fit state difference, and deposit
Device information is easily readable, therefore this programme can accurately and quickly realize the detection to device fit state.
In one possible implementation, above-mentioned detection unit is specifically used for the register information if it is determined that the first device
Including the first information, it is determined that the fit state of the first device is equipped completes.Or, however, it is determined that the register of the first device is believed
Breath does not include the first information, it is determined that the fit state of the first device is equipped do not complete.In the program, the first information first
Device is equipped with the information just appeared in the first device register when completing, by the register information for judging first device
It whether is the fit state that can determine whether the first device including the first information.
Further, above-mentioned first device can be camera, then the first information can be the sensor information of camera.
Or above-mentioned first device can be display screen, then the first information can be the starting information of display screen.In the program, camera
Sensor information the information in camera register is appeared in when to be that camera is equipped complete, the starting information of display screen is aobvious
Display screen is equipped to appear in information in display screen register when completing, thus can be determined by the present processes camera or
The fit state of person's display screen.
In another possible implementation, above-mentioned detection unit specifically can be used for: if it is determined that the first device is posted
Storage information includes the second information, it is determined that the fit state of the first device is equipped completes;Or, however, it is determined that the first device
Register information includes third information, it is determined that the fit state of the first device is equipped do not complete.In the program, according to first
The fit state of device is different, will appear different information in the first device register, is according to the information in the first register
Second information or third information can determine the fit state of the first device.
Further, above-mentioned first device is any one following device: camera, display screen.By judging camera
It perhaps include that the second information or third information can determine camera or display screen in the register information in display screen
Fit state.
In one possible implementation, above-mentioned apparatus further includes circuit probe unit, for determining the platelet of equipment
And/or the circuit communication between the mainboard of the equipment.It, can be with when the platelet of equipment and/or flexible circuit board are equipped to be completed
It realizes circuit communication between the platelet and/or flexible circuit board and the mainboard of equipment of equipment, obtains first from mainboard to realize
The register information of device.
The third aspect, the application provide a kind of network equipment, comprising:
Memory, for storing program instruction;
Processor executes aforementioned first according to the program of acquisition for calling the program instruction stored in the memory
Method described in any embodiment in aspect or first aspect.
Fourth aspect, the application provide a kind of computer readable storage medium, the computer-readable recording medium storage
There are computer executable instructions, the computer executable instructions are for making computer execute aforementioned first aspect or first aspect
Method described in middle any embodiment.
Specific embodiment
In order to keep the purposes, technical schemes and advantages of the application clearer, below in conjunction with attached drawing to the application make into
One step it is described in detail.Concrete operation method in embodiment of the method also can be applied to Installation practice or system embodiment
In.Wherein, in the description of the present application, unless otherwise indicated, the meaning of " plurality " is two or more.
As shown in Figure 1, being a kind of possible system architecture schematic diagram provided by the present application.The system architecture includes equipment
101 and detection device 102.Wherein, equipment 101 can have the electronic equipment of mainboard for mobile phone, tablet computer etc..Detection device
102 can be for computer or be the computer etc. with specific software.Equipment 101 and detection device 102 pass through wired or wireless
Mode is attached.
Based on system architecture shown in FIG. 1, Fig. 2 illustratively shows a kind of equipment detection method provided by the present application
Flow chart.The equipment detection method can be executed by the detection device 102 in Fig. 1.Method includes the following steps:
Step 201, the register information of the first device is obtained from the mainboard of equipment.
Wherein, the register information of the first device is used to indicate the fit state of first device.
Step 202, according to the register information of the first device, the fit state of the first device is determined.
The fit state of first device includes that the equipped completion of the first device and the first device are equipped unfinished.Wherein,
The equipped completion of one device refers to that the first device has been completed to be equipped with can execute corresponding function in a device.First device is matched
Dress, which does not complete, refers to that the first device can not execute corresponding function in a device, including the first device is equipped with positional fault, the
Situations such as one device contacts are bad, the first device failure.
It, in one possible implementation, can be by sending a register letter to equipment for above-mentioned steps 201
Acquisition instruction is ceased to realize, which is sent to the mainboard of equipment, the register information acquisition instruction packet
One or more device identifications are included, for example register information acquisition instruction includes a camera device identification, is deposited for another example
The instruction of device acquisition of information includes camera device identification and display screen device identification.Device identification is used to indicate mainboard for device
The register information for identifying corresponding device is sent to detection device.
And the register information the application for how getting each device for mainboard in above-mentioned steps 201 does not do specific limit
System.It can be after receiving register information acquisition instruction, according to register information acquisition instruction posting from corresponding device
It obtains, is also possible to when equipment starts, mainboard is arrived in storage after communication acquisition is carried out between mainboard and each device in storage
Memory in.
Above-mentioned steps 202 are illustrated below, for above-mentioned steps 202, at least possible realization side of following two
Formula, it should be noted that the possible implementation of following two is only example provided by the present application, and specific implementation can press
Actual needs is adjusted.
Mode one
The above-mentioned register information according to the first device, determines the fit state of the first device, comprising: if the first device
Register information includes the first information, it is determined that the fit state of the first device is equipped completes.Alternatively, if the first device is posted
Storage information does not include the first information, it is determined that the fit state of the first device is equipped do not complete.
Wherein, the first information is that the first device is equipped with the information just appeared in the first device register when completing.Than
If the first device is camera, the first information is the sensor information of camera.For another example, the first device be display screen, first
Information is the starting information of display screen.When the first device is equipped to be completed, the first information just appears in the deposit of the first device
In device, then obtained by mainboard.By whether including the first information out of the first device that mainboard obtains register information, i.e.,
It can determine whether out whether the first device is equipped to complete.For example, when including in the register information from the camera that mainboard obtains
The sensor information of camera, it is determined that camera is equipped to be completed, if in the register information of camera not including sensor letter
Breath, it is determined that camera is not equipped to be completed.Likewise, when including display screen from the register information for the display screen that mainboard obtains
Starting information, it is determined that display screen is equipped to be completed, if in the register information of display screen not including the starting information of display screen,
It then determines that display screen is equipped not completing.
Aforesaid way one is suitable for some devices that can be given birth to new information in equipped complete and be stored in register, below
Another implementation provided by the present application is introduced.
Mode two
The above-mentioned register information according to first device, determines the fit state of first device, comprising: if the
The register information of one device includes the second information, it is determined that the fit state of the first device is equipped completes.Alternatively, if first
The register information of device includes third information, it is determined that the fit state of the first device is equipped do not complete.
Wherein, the second information and third information are different information, for example, one in the register information of device A
Field A device A is equipped complete when, field A=1, device A is equipped do not complete when field A=0.Then the second information is
Field A=1, third information are field A=0.It is from the register information of the device A read in mainboard according to including
Two information or third information, can determine the fit state of device A.
Above-mentioned device A can be any one following device: camera, display screen.It certainly according to actual needs can also be with
For it is other in equipped complete with it is unfinished when register in the different device of some information.It should be noted that the application
Camera, the display screen device enumerated can determine that fit state is also determined in the manner described above two in the manner described above one
Fit state can also realize that specific implementation can be according to camera, model specification of display screen etc. using other modes
Factor is adjusted.
In one possible implementation, before above-mentioned steps 201, can also comprise determining that equipment platelet and/
Or circuit communication between flexible circuit board and the mainboard of equipment.Wherein, the platelet and/or flexible circuit board of equipment are for connecting
The device of the mainboard of detection device and equipment.Specifically, an electric current letter can be sent to the mainboard of equipment by detection device
Number, and circuit communication between the platelet and/or flexible circuit board and the mainboard of equipment of equipment is determined according to the feedback signal of mainboard,
If it is determined that circuit communication between the platelet and/or flexible circuit board of equipment and the mainboard of equipment, then illustrate equipment platelet and/or
Flexible circuit board is equipped to be completed.
Based on above scheme, due to only needing to read out the register information of device, the equipped of device can have both been determined
State is detected without the functionality to device, therefore can more quickly be detected to device fit state, and
And the present processes are also more accurate compared to naked eyes judgement.
Based on the same inventive concept, Fig. 3 illustratively shows a kind of assembly detection apparatus provided by the present application, the device
The process of equipment detection method can be executed.As shown in figure 3, the device includes:
Acquiring unit 301, for obtaining the register information of the first device from the mainboard of equipment.
The register information of first device is used to indicate the fit state of first device.
Detection unit 302 determines the fit state of first device for the register information according to the first device.
In one possible implementation, above-mentioned detection unit 302 is specifically used for the register if it is determined that the first device
Information includes the first information, it is determined that the fit state of the first device is equipped completes.Or, however, it is determined that the deposit of the first device
Device information does not include the first information, it is determined that the fit state of the first device is equipped do not complete.
Further, above-mentioned first device can be camera, then the first information can be the sensor information of camera.
Or above-mentioned first device can be display screen, then the first information can be the starting information of display screen.
In another possible implementation, above-mentioned detection unit specific 302 can be used for: if it is determined that the first device
Register information includes the second information, it is determined that the fit state of the first device is equipped completes;Or, however, it is determined that the first device
Register information include third information, it is determined that the fit state of the first device is equipped do not complete.
Further, above-mentioned first device is any one following device: camera, display screen.By judging camera
It perhaps include that the second information or third information can determine camera or display screen in the register information in display screen
Fit state.
In one possible implementation, above-mentioned apparatus further includes circuit probe unit 303, for determining the small of equipment
Plate and/or the circuit communication between the mainboard of the equipment.It, can when the platelet of equipment and/or flexible circuit board, which are equipped with, to be completed
Circuit communication between platelet and/or flexible circuit board and the mainboard of equipment to realize equipment obtains from mainboard the to realize
The register information of one device.
Concept relevant to technical solution provided by the present application involved in above-mentioned apparatus is explained and is described in detail and is other
Step refers to the description as described in these contents in aforementioned device detection method or other embodiments, is not repeated herein.
Based on design same as the previously described embodiments, the application also provides a kind of network equipment.
Fig. 4 is a kind of structural schematic diagram of the network equipment provided by the present application.As shown in figure 4, the network equipment 400 wraps
It includes:
Memory 401, for storing program instruction;
Processor 402 executes aforementioned according to the program of acquisition for calling the program instruction stored in the memory
One equipment detection method as described in the examples.
Based on design same as the previously described embodiments, the application also provides a kind of computer storage medium, the computer
Readable storage medium storing program for executing is stored with computer executable instructions, and the computer executable instructions are for making computer execute aforementioned
One equipment detection method as described in the examples.
It should be noted that be schematical, only a kind of logical function partition to the division of unit in the application, it is real
There may be another division manner when border is realized.Each functional unit in this application can integrate in one processing unit,
It is also possible to each unit to physically exist alone, can also be integrated in two or more units in a module.Above-mentioned collection
At unit both can take the form of hardware realization, can also realize in the form of software functional units.
In the above-described embodiments, can come wholly or partly by software, hardware, firmware or any combination thereof real
It is existing.When implemented in software, it can entirely or partly realize in the form of a computer program product.Computer program product
Including one or more computer instructions.When loading on computers and executing computer program instructions, all or part of real estate
Raw process or function according to the application.Computer can be general purpose computer, special purpose computer, computer network or its
His programmable device.Computer instruction may be stored in a computer readable storage medium, or computer-readable deposit from one
Storage media is transmitted to another computer readable storage medium, for example, computer instruction can be from a web-site, calculating
Machine, server or data center are (such as red by wired (such as coaxial cable, optical fiber, Digital Subscriber Line (DSL)) or wireless
Outside, wirelessly, microwave etc.) mode transmitted to another web-site, computer, server or data center.Computer can
Reading storage medium can be any usable medium or include that one or more usable mediums are integrated that computer can access
The data storage devices such as server, data center.Usable medium can be magnetic medium, (for example, floppy disk, hard disk, tape),
Optical medium (for example, DVD) or semiconductor medium (such as solid state hard disk Solid State Disk (SSD)) etc..
It should be understood by those skilled in the art that, the application can provide as method, system or computer program product.Cause
This, the shape of complete hardware embodiment, complete software embodiment or embodiment combining software and hardware aspects can be used in the application
Formula.Moreover, the application, which can be used, can use storage in the computer that one or more wherein includes computer usable program code
The form for the computer program product implemented on medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.).
The application be referring to according to the present processes, equipment (system) and computer program product flow chart and/or
Block diagram describes.It should be understood that each process that can be realized by computer program instructions in flowchart and/or the block diagram and/or
The combination of process and/or box in box and flowchart and/or the block diagram.It can provide these computer program instructions to arrive
General purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices processor to generate one
Machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for realizing flowing
The device for the function of being specified in journey figure one process or multiple processes and/or block diagrams one box or multiple boxes.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates,
Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or
The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting
Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or
The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one
The step of function of being specified in a box or multiple boxes.
Obviously, those skilled in the art can carry out various modification and variations without departing from the essence of the application to the application
Mind and range.In this way, if these modifications and variations of the application belong to the range of the claim of this application and its equivalent technologies
Within, then the application is also intended to include these modifications and variations.