CN108628713A - Equipment detection method, device, storage medium and electronic equipment - Google Patents
Equipment detection method, device, storage medium and electronic equipment Download PDFInfo
- Publication number
- CN108628713A CN108628713A CN201810475646.3A CN201810475646A CN108628713A CN 108628713 A CN108628713 A CN 108628713A CN 201810475646 A CN201810475646 A CN 201810475646A CN 108628713 A CN108628713 A CN 108628713A
- Authority
- CN
- China
- Prior art keywords
- type
- equipment
- interfaces
- external
- voltage
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2205—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
- G06F11/2221—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested to test input/output devices or peripheral units
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2273—Test methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2284—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing by power-on test, e.g. power-on self test [POST]
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Power Sources (AREA)
Abstract
The embodiment of the present application discloses a kind of equipment detection method, device, storage medium and electronic equipment, wherein the embodiment of the present application whether there is external object by detecting in Type C interface;When Type C interface memory is in external object, default detection voltage is provided for the configurating channel pin of Type C interface;Obtain the voltage change of configurating channel pin;According to voltage change, judge whether external object is external Type C equipment.In the program, the configurating channel pin powered for being continuously Type C interface is not needed to, but detecting Type C interface, there are external objects, when that is to say that Type C interface may access external Type C equipment, just default detection voltage is provided to configurating channel pin, realize that the access to external Type C equipment detects, thus, it only needs to be configurating channel pin powered in a relatively short period of time, realize that external Type C equipment access detection to the corrosion caused by Type C interface, achievees the purpose that improve Type C interface service lifes to reduce.
Description
Technical field
This application involves technical field of electronic equipment, and in particular to a kind of equipment detection method, device, storage medium and electricity
Sub- equipment.
Background technology
Currently, Type-C interfaces have become the standard configuration interface of the electronic equipments such as tablet computer, mobile phone.Electronic equipment can be with
It is attached by Type-C interfaces and outside Type-C equipment, realizes the interaction of equipment room.For this purpose, outside will be carried out first
The access of Type-C equipment detects.Electronic equipment can continue in the access detection for realizing external Type-C equipment to Type-C
The configurating channel pin of interface provides detection voltage.However, in order to facilitate the use of the user, the Type-C interfaces of electronic equipment are usual
It is exposed setting, this allows for Type-C interfaces and readily accesses corrosive liquid (such as sweat), and configurating channel draws
It is to continue electrification on foot, the corrosion of Type-C interfaces will be accelerated, to influence the service life of Type-C interfaces.
Invention content
The embodiment of the present application provides a kind of equipment detection method, device, storage medium and electronic equipment, can improve
The service life of Type-C interfaces.
In a first aspect, a kind of equipment detection method that the embodiment of the present application provides, including:
It detects and whether there is external object in Type-C interfaces;
There are when the external object in the Type-C interfaces, carried for the configurating channel pin of the Type-C interfaces
For default detection voltage;
Obtain the voltage change of the configurating channel pin;
According to the voltage change, judge whether the external object is external Type-C equipment.
Second aspect, a kind of assembly detection apparatus that the embodiment of the present application provides, including:
Object detection module whether there is external object for detecting in Type-C interfaces;
Voltage provides module, for, there are when the external object, being connect for the Type-C in the Type-C interfaces
The configurating channel pin of mouth provides default detection voltage;
Voltage acquisition module, the voltage change for obtaining the configurating channel pin;
Equipment identification module, for according to the voltage change, judging whether the external object is external Type-C
Equipment.
The third aspect, storage medium provided by the embodiments of the present application, is stored thereon with computer program, when the computer
When program is run on computers so that the computer executes the equipment detection method provided such as the application any embodiment.
Fourth aspect, electronic equipment provided by the embodiments of the present application, including processor and memory, the memory have meter
Calculation machine program, the processor is by calling the computer program, for executing as what the application any embodiment provided sets
Standby detection method.
The embodiment of the present application, which detects, whether there is external object in Type-C interfaces;In Type-C interfaces memory in external object
When part, default detection voltage is provided for the configurating channel pin of Type-C interfaces;Obtain the voltage change of configurating channel pin;
According to voltage change, judge whether external object is external Type-C equipment.In the program, do not need to be continuously Type-C
The configurating channel pin powered of interface, but detecting that Type-C interfaces there are external object, that is to say that Type-C interfaces can
When can access external Type-C equipment, default detection voltage just is provided to configurating channel pin, is realized to external Type-C equipment
Access detection, thus, it is only necessary to be in a relatively short period of time configurating channel pin powered, external Type-C is realized to reduce
Equipment access detection achievees the purpose that improve Type-C interface service lifes to the corrosion caused by Type-C interfaces.
Description of the drawings
In order to more clearly explain the technical solutions in the embodiments of the present application, make required in being described below to embodiment
Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some embodiments of the present application, for
For those skilled in the art, without creative efforts, it can also be obtained according to these attached drawings other attached
Figure.
Fig. 1 is the application scenarios schematic diagram of equipment detection method provided by the embodiments of the present application.
Fig. 2 is a flow diagram of equipment detection method provided by the embodiments of the present application.
Fig. 3 is the structural schematic diagram of the Type-C interfaces provided in the embodiment of the present application.
Fig. 4 is that the exemplary plot of range sensor is arranged in Type-C interfaces in the embodiment of the present application.
Fig. 5 is the structural schematic diagram of the detection circuit provided in the embodiment of the present application.
Fig. 6 is that the exemplary plot of temperature sensor is arranged in Type-C interfaces in the embodiment of the present application.
Fig. 7 is the schematic diagram that information input window is shown in the embodiment of the present application.
Fig. 8 is another flow diagram of equipment detection method provided by the embodiments of the present application.
Fig. 9 is a structural schematic diagram of assembly detection apparatus provided by the embodiments of the present application.
Figure 10 is a structural schematic diagram of electronic equipment provided by the embodiments of the present application.
Figure 11 is another structural schematic diagram of electronic equipment provided by the embodiments of the present application.
Specific implementation mode
Diagram is please referred to, wherein identical component symbol represents identical component, the principle of the application is to implement one
It is illustrated in computing environment appropriate.The following description be based on illustrated by the application specific embodiment, should not be by
It is considered as limitation the application other specific embodiments not detailed herein.
In the following description, the specific embodiment of the application will be with reference to by the step performed by one or multi-section computer
And symbol illustrates, unless otherwise stating clearly.Therefore, these steps and operation will have to mention for several times is executed by computer, this paper institutes
The computer execution of finger includes by representing with the computer processing unit of the electronic signal of the data in a structuring pattern
Operation.This operation is converted at the data or the position being maintained in the memory system of the computer, reconfigurable
Or in addition change the running of the computer in a manner of known to the tester of this field.The data structure that the data are maintained
For the provider location of the memory, there is the specific feature defined in the data format.But the application principle is with above-mentioned text
Word illustrates that be not represented as a kind of limitation, this field tester will appreciate that plurality of step as described below and behaviour
Also it may be implemented in hardware.
Term as used herein " module " can regard the software object to be executed in the arithmetic system as.It is as described herein
Different components, module, engine and service can be regarded as the objective for implementation in the arithmetic system.And device as described herein and side
Method can be implemented in the form of software, can also be implemented on hardware certainly, within the application protection domain.
Term " first ", " second " and " third " in the application etc. is for distinguishing different objects, rather than for retouching
State particular order.In addition, term " comprising " and " having " and their any deformations, it is intended that cover and non-exclusive include.
Such as contain the step of process, method, system, product or the equipment of series of steps or module is not limited to list or
Module, but some embodiments further include the steps that do not list or module or some embodiments further include for these processes,
Method, product or equipment intrinsic other steps or module.
Referenced herein " embodiment " is it is meant that a particular feature, structure, or characteristic described can wrap in conjunction with the embodiments
It is contained at least one embodiment of the application.Each position in the description occur the phrase might not each mean it is identical
Embodiment, nor the independent or alternative embodiment with other embodiments mutual exclusion.Those skilled in the art explicitly and
Implicitly understand, embodiment described herein can be combined with other embodiments.
The embodiment of the present application provides a kind of equipment detection method, and the executive agent of the equipment detection method can be the application
The assembly detection apparatus that embodiment provides, or it is integrated with the electronic equipment of the assembly detection apparatus, wherein equipment detection fills
It sets and the mode of hardware or software may be used realizes.Wherein, electronic equipment can be smart mobile phone, tablet computer, palm electricity
The computer equipments such as brain, laptop or desktop computer.
Fig. 1 is please referred to, Fig. 1 is the application scenarios schematic diagram of equipment detection method provided by the embodiments of the present application, with equipment
For detection device integrates in the electronic device, electronic equipment can detect in Type-C interfaces with the presence or absence of external object (ratio
Such as, when the Type-C interfaces of external Type-C equipment shown in FIG. 1 being inserted into the Type-C interfaces of electronic equipment, electronic equipment will
Detect its Type-C interface memory in external object);It is Type-C when detecting Type-C interfaces memory in external object
The configurating channel pin of interface provides default detection voltage;Obtain the voltage change of configurating channel pin;According to voltage change
Value, judges whether external object is external Type-C equipment, and it is external Type-C equipment or external object to obtain external object
It is not the result of external Type-C equipment.
Fig. 2 is please referred to, Fig. 2 is the flow diagram of equipment detection method provided by the embodiments of the present application.The application is implemented
The detailed process for the equipment detection method that example provides can be as follows:
In a step 101, it whether there is external object in detection Type-C interfaces.
Fig. 3 is please referred to, the Type-C interfaces of electronic equipment include interface section and casing part, and casing part encirclement connects
Oral area point, as shown in figure 3, casing part, which surrounds interface section, forms an accommodating space, the accommodating space is for outside
The Type-C interfaces of Type-C equipment access, so that electronic equipment and outside Type-C equipment are established electrical connection.Its
In, external Type-C equipment can be connect using the earphone of Type-C interfaces, using the USB flash disk of Type-C interfaces, using Type-C
Mobile phone, the tablet computer using Type-C interfaces, the laptop using Type-C interfaces and the use Type-C of mouth connect
Other electronic equipments such as the desktop computer of mouth.
It in the embodiment of the present application, whether there is external object in detection Type-C interfaces, that is to say detection Type-C interfaces
Interface section and casing part formed accommodating space in, if there are external objects.
For example, user by the Type-C interfaces of external Type-C equipment be linked into electronic equipment Type-C interfaces it
Afterwards, electronic equipment will detect its Type-C interface memory in external object.
In a step 102, it when Type-C interfaces memory is in external object, is carried for the configurating channel pin of Type-C interfaces
For default detection voltage.
It should be noted that there are three types of roles for Type-C interfaces, it is that downstream interface, upstream Interface and double roles connect respectively
Mouthful, wherein when the Type-C interfaces of electronic equipment are as downstream interface, electronic equipment can be access as main equipment
External Type-C equipment power supply reads data etc. to external Type-C equipment transmission data from external Type-C equipment;In electronics
When the Type-C interfaces of equipment are as upstream Interface, electronic equipment is used as from equipment, can be from the external Type-C equipment of access
Electricity is removed, data etc. are provided for external Type-C equipment;When the Type-C interfaces of electronic equipment are as double role's interfaces, electronics is set
It is standby can be in main equipment and from switching at runtime between equipment.
In addition, the maximum feature of Type-C interfaces is that tow sides is supported to can be inserted into " positive anti-plug " function, to realize
The tow sides of " positive anti-plug " function, interface section are both provided with 12 pins, and pin is defined as follows shown in table 1:
GND | TX1+ | TX1- | VBUS | CC1 | D+ | D- | SBU1 | VBUS | RX2- | RX2+ | GND |
GND | RX1+ | RX1- | VBUS | SBU2 | D- | D+ | CC2 | VBUS | TX2- | TX2+ | GND |
Table 1
TX1+, TX1-, RX1+, RX1-, TX2+, TX2- and RX2+, RX2- are four pairs of differential signal pins, and D+, D- are
Differential signal pin for being compatible with USB2,0 standard, VBUS are power pins, and CC1, CC2 are configurating channel pin, SBU1,
SBU2 is bus pin.
Wherein, by configurating channel pin, the access detection of external Type-C equipment, role zone may be implemented in electronic equipment
Point and positive and negative identification etc..
In the embodiment of the present application, when detecting Type-C interfaces memory in external object, that is, illustrate currently have outer
Portion's Type-C equipment access, at this point, default detection voltage can be provided for the configurating channel pin of Type-C interfaces, to be based on this
Configurating channel pin realizes the access detection of external Type-C equipment.
Wherein, which can be a pwm voltage, and voltage value range can be for 2.4V extremely
3.4V, period value range can be 50ms to 100ms, and duty ratio value range can be 30% to 70%.
For example, electronic equipment matches confidence when detecting Type-C interfaces memory in external object, for Type-C interfaces
Road pin provide voltage value be 3.4V, the default detection voltage that period 50ms, duty ratio are 70%.
In step 103, the voltage change of configurating channel pin is obtained.
In the embodiment of the present application, after default detection voltage is provided for Type-C interfaces, configurating channel pin is carried out
Voltage detecting gets the current voltage of configurating channel pin, and calculates the voltage difference of default detection voltage and the current voltage
Value, using the voltage difference being calculated as the voltage change of configurating channel.
At step 104, according to voltage change, judge whether external object is external Type-C equipment.
In the embodiment of the present application, the Type-C interfaces of electronic equipment are configured as downstream interface, that is to say that electronic equipment is made
For main equipment.It is configured as upstream Interface in the Type-C interfaces of external Type-C equipment, that is to say that external Type-C equipment is made
For from equipment when, the configurating channel pins of Type-C interfaces be connected with pull down resistor (pull down resistor can be one individually
Resistance, can also be the series connection of multiple resistance and/or compose in parallel).
It is easily understood that the Type-C interfaces in external Type-C equipment are linked into the Type-C interfaces of electronic equipment
When, the configurating channel pin of electronic equipment will be connect with the configurating channel pin of external Type-C equipment so that electronic equipment
Configurating channel pin is connect with the pull down resistor of outside Type-C equipment, drags down the voltage on electronic equipment configurating channel pin.
Electronic equipment can be by the voltage change of its configurating channel pin, to judge in its Type-C interface as a result,
Whether existing external object is external Type-C equipment (being specially the Type-C interfaces of external Type-C equipment).
It should be noted that for different function external Type-C equipment (such as using Type-C interfaces earphone and U
Disk etc.), the resistance value for the pull down resistor that configurating channel pin is connected is different, correspondingly, in the outside of different function
When Type-C equipment accesses electronic equipment, the voltage pull-down degree of the configurating channel pin of electronic equipment is different.Therefore,
One predeterminated voltage section can be set, come reflect different function external Type-C equipment voltage pull-down degree, for example, should
Predeterminated voltage section could be provided as [Vmin, Vmax], when Vmin is that external Type-C equipment accesses electronic equipment, drag down electronics
The minimum amount of voltage that of the configurating channel pin of equipment drags down electronics and sets when Vmax is that external Type-C equipment accesses electronic equipment
The maximum voltage value of standby configurating channel pin.Wherein, the value of Vmin and Vmax can be determined by experiment in advance, for example, determining
Vmin be 1.5V, determining Vmax be 3V, then can obtain predeterminated voltage section [1.5V, 3V].
In the embodiment of the present application, according to voltage change, when judging whether external object is external Type-C equipment, electricity
Sub- equipment may determine that whether the voltage change got is located within predeterminated voltage section;Wherein, if voltage change position
Within the predeterminated voltage section, then electronic equipment determines that external object is external Type-C equipment;If voltage change is located at
Except the predeterminated voltage section, then it is external Type-C equipment that electronic equipment, which determines external object not,.
For example, when predeterminated voltage section is [1.5V, 3V], if electronic equipment gets the voltage of its configurating channel pin
Changing value is 2V, then can determine that the external object in its Type-C interface is external Type-C equipment;If electronic equipment obtains
Voltage change to its configurating channel pin is 0.2V, then it is outside that can determine the external object in its Type-C interface not
Type-C equipment.
From the foregoing, it will be observed that whether there is external object in the embodiment of the present application detection Type-C interfaces;In Type-C interfaces
There are when external object, default detection voltage is provided for the configurating channel pin of Type-C interfaces;Obtain configurating channel pin
Voltage change;According to voltage change, judge whether external object is external Type-C equipment.In the program, do not need to
It is continuously the configurating channel pin powered of Type-C interfaces, but there are external objects detecting Type-C interfaces, that is to say
When Type-C interfaces may access external Type-C equipment, default detection voltage just is provided to configurating channel pin, is realized external
The access of portion's Type-C equipment detects, thus, it is only necessary to be in a relatively short period of time configurating channel pin powered, to reduce reality
Existing external Type-C equipment access detection reaches to the corrosion caused by Type-C interfaces and improves Type-C interface service lifes
Purpose.
In one embodiment, Fig. 4 is please referred to, it, can be in Type- for the detection for realizing to Type-C interfaces inside and outside object
Range sensor is arranged in the casing part of C interface, and the test side of the range sensor is arranged towards the interface of Type-C interfaces
Part, and detect and whether there is external object in Type-C interfaces, including:
Obtain the distance value that range sensor detects;
Judge whether the distance value got is located within pre-determined distance section, wherein if the distance value got is located at
Within pre-determined distance section, then Type-C interfaces memory is in external object.
It should be noted that for using which kind of range sensor, being not particularly limited in the embodiment of the present application, it can be by this
Field technology personnel select according to actual needs, can select laser distance sensor, infrared distance sensor and surpass
Any one of different types range sensor such as sound wave range sensor, for example, the embodiment of the present application is in Type-C interfaces
Infrared distance sensor is arranged in casing part, and the test side of the infrared distance sensor is towards interface section.
As shown in figure 4, when not having external object in Type-C interfaces, the range sensor being arranged in casing part will be examined
Its own distance value to interface section is measured, and has external object in Type-C interfaces, for example external Type-C equipment connects
Fashionable, what range sensor detected will be its own distance value to the Type-C interfaces of external Type-C equipment.
It is easily understood that when external object being not present in the Type-C interfaces of electronic equipment, it is clear that be impossible have
External Type-C equipment access, and when the Type-C interfaces memory of electronic equipment is in external object, it has been likely to outside
Type-C equipment accesses, therefore, in the embodiment of the present application, the distance that electronic equipment can be detected according to range sensor
Value is accessed to judge to whether there is external object in its Type-C interface with tentatively judging whether there is external Type-C equipment.
In the embodiment of the present application, when detecting in Type-C interfaces with the presence or absence of external object, electronic equipment obtains first
The distance value that range sensor detects, then judges whether the distance value got is located within pre-determined distance section,
When the distance value got is located within pre-determined distance section, determine that its Type-C interfaces memory in external object, is being got
Distance value when being located at except pre-determined distance section, determine and external object be not present in its Type-C interface.
Wherein it is possible to set [0, Lmax] pre-determined distance section to, Lmax indicates external Type-C equipment access electricity
When the Type-C interfaces of sub- equipment, maximum range value that range sensor can be detected be (different external Type-C equipment
Type-C interfaces thickness is different, when leading to the Type-C interfaces of different external Type-C equipment access electronic equipments, Distance-sensing
Distance value detected by device is different), specifically experiment can be first passed through in advance obtain.
For example, pre-determined distance section is arranged to [0,0.5mm], if the distance value got is (such as no outsides 1mm
When Type-C equipment accesses the Type-C interfaces of electronic equipment), electronic equipment will detect that there is no outer in its Type-C interface
Portion's object;
If the distance value got, which is 0.2mm, (accesses the Type-C interfaces of electronic equipment if any external Type-C equipment
When), electronic equipment will detect its Type-C interface memory in external object.
In one embodiment, it is the detection for realizing to Type-C interfaces inside and outside object, it can be in the outer of Type-C interfaces
Shell parts are arranged the first luminance sensor, and the test side of the first luminance sensor is towards interface section, Type-C interfaces it
The second luminance sensor is arranged in outer position, and the test side of the second luminance sensor is directed away from the direction of electronic equipment, and
It detects and whether there is external object in Type-C interfaces, including:
Obtain the first brightness value that the first luminance sensor detects;
Obtain the second brightness value that the second luminance sensor detects;
The luminance difference of the first brightness value and the second brightness value is obtained, and judges whether the luminance difference reaches predetermined luminance
Difference, wherein when the luminance difference reaches predetermined luminance difference, determine Type-C interface memories in external object.
It is easily understood that when external object is not present in the Type-C interfaces of electronic equipment, setting connects in Type-C
The first luminance sensor in mouthful, (the two is each with the luminance difference for the second luminance sensor being arranged except Type-C interfaces
The difference for the brightness value that self-test measures) it is smaller, and when the Type-C interfaces memory of electronic equipment is (such as external in external object
Type-C equipment accesses the Type-C interfaces of electronic equipment) when, external object will block the light of the first luminance sensor of directive,
So that the luminance difference of the first luminance sensor and the second luminance sensor is larger.Electronic equipment can be bright according to first as a result,
The luminance difference of degree sensor and the second luminance sensor whether there is external object to determine in Type-C interfaces.
It should be noted that for the specific value of predetermined luminance difference, the embodiment of the present application is not particularly limited, can be by
Those skilled in the art are configured according to actual needs.
In one embodiment, Fig. 5 is please referred to, for the detection for realizing to Type-C interfaces inside and outside object, electronic equipment packet
Detection circuit is included, which includes metal contact piece, and detection voltage provides module and detection resistance, wherein metal contact piece
One end pass through a through-hole of casing part setting, fixed with the center of electronic equipment, the other end of metal contact piece passes through shell
Part setting another through-hole, extend to electronic equipment internal, for when generating deformation connect detection voltage provide module with
Detection resistance, and detect and whether there is external object in Type-C interfaces, including:
Obtain the input voltage value of detection resistance;
If the input voltage value got is identical as the detection voltage offer output voltage values of module, in Type-C interfaces
There are external objects.
Wherein, detection resistance can be an individual resistance, can also be that multiple resistance are connected and/or composed in parallel,
Selection for its resistance value can be taken desired value, the embodiment of the present application not to do this according to actual needs by those skilled in the art
Concrete restriction, for example, could be provided as 1.2K Ω.
For example, please referring to Fig. 5, the output voltage values that detection voltage provides module are 3.7V, are set when not having external Type-C
When standby access, metal contact piece not will produce deformation, and the input voltage value that electronic equipment gets detection resistance at this time will be zero;When
When having external Type-C equipment to access, the Type-C interfaces of external Type-C equipment will squeeze metal contact piece, be allowed to generate deformation,
There is provided module and detection resistance to connect detection voltage, at this time electronic equipment get the input voltage value of detection resistance will be with
The output voltage values for detecting voltage offer module are identical, are 3.7V, detect its Type-C interface memory in external object.
In one embodiment, after providing default detection voltage for the configurating channel pin of Type-C interfaces, further include:
Detecting that there is no when external object, stop providing default detection electricity for configurating channel pin in Type-C interfaces
Pressure.
Wherein, the step of whether there is external object in detection Type-C interfaces carries out in real time, at a time, if
Type-C interfaces memory is detected in external object, then default detection voltage is provided for Type-C interfaces, to realize to outside
The access of Type-C equipment detects.
After default detection voltage is provided for the configurating channel pin of Type-C interfaces, it that is to say as Type-C interfaces
During configurating channel pin provides default detection voltage, electronic equipment still detects its Type-C interface and whether there is external object in real time
Part, wherein whether there is external object in Type-C interfaces for how to detect, specifically can refer to related description provided above, herein
It repeats no more.
External object is not present in Type-C interfaces (for example, external Type-C equipment is accessed electronics by user when detecting
After the Type-C interfaces of equipment, and external Type-C equipment is extracted from the Type-C interfaces of electronic equipment) when, electronic equipment
Stop stopping power supply for the configurating channel pin of its Type-C interface so that configurating channel pin is not charged.
In brief, in the embodiment of the present application, electronic equipment and only in its Type-C interface memory in external object
Period provides default detection voltage for the configurating channel pin of Type-C interfaces, realizes that the access to external Type-C equipment is examined
It is not configurating channel pin powered so that configurating channel pin is not when surveying, and external object being not present in its Type-C interface
Electrification.
In one embodiment, it according to voltage change, after judging whether external object is external Type-C equipment, also wraps
It includes:
If the external object in Type-C interfaces is external Type-C equipment, pass through Type-C interfaces and outside Type-C
Equipment establishes electrical connection;
According to the voltage change of configurating channel pin, correspondence is provided to external Type-C equipment by the electrical connection of foundation
Supply voltage, for external Type-C equipment power.
In the embodiment of the present application, electronic equipment is as main equipment, and outside Type-C equipment is used as from equipment and accesses electronics
Equipment establishes therebetween electrical connection.
It is retouched based on the correlation above with respect to " according to voltage change, judging whether external object is external Type-C equipment "
It states, it is known that when the external Type-C equipment of different function accesses electronic equipment, detected its of electronic equipment matches confidence
Voltage change on road pin is different.In addition, those skilled in the art can learn, the external Type-C of different function
Supply voltage needed for equipment is different, for example, using the supply voltage needed for the earphone of Type-C interfaces for 3.3V, and uses
Supply voltage needed for the USB flash disk of Type-C interfaces is 4.5V.
Therefore, in the embodiment of the present application, it is previously provided with the correspondence of voltage change and supply voltage.Correspondingly,
Electronic equipment is detecting its Type-C interfaces memory in external object, and determines that the external object is external Type-C equipment
When, it is closed according to the voltage change of the configurating channel pin got and aforesaid voltage changing value are corresponding with supply voltage
System determines the supply voltage corresponding to the voltage change got, is carried by the external Type-C equipment that electrically connects as of foundation
For determining supply voltage.
Thus, it is possible to by the voltage change on configurating channel pin, the work(of external Type-C equipment is further identified
Energy type, and provide corresponding supply voltage for it.
It is easily understood that if the temperature of Type-C interfaces is excessively high, it would be possible to burn Type-C interfaces, or even damage whole
A electronic equipment.And when it is that external Type-C equipment is powered that electronic equipment is by Type-C interfaces, its Type-C will be made to connect
The temperature of mouth increases rapidly.To avoid causing the power supply of external Type-C equipment the damage of electronic equipment, in one embodiment,
It is further comprising the steps of:
During providing supply voltage to external Type-C equipment, the temperature value of Type-C interfaces is obtained;
When getting temperature value and being located within preset temperature section, disconnects and to be electrically connected with outside Type-C equipment.
Wherein, Fig. 6 is please referred to, can also temperature sensor be set in the casing part of Type-C interfaces, for Type-
The temperature of C interface is detected.
In the embodiment of the present application, electronic equipment to external Type-C equipment during providing supply voltage, in real time from setting
The temperature value of Type-C interfaces is obtained at the temperature sensor of Type-C interfaces, and in the temperature value for getting Type-C interfaces
Later, judge whether the temperature value is located within preset temperature section, wherein be located within preset temperature section in the temperature value
When, illustrate that the temperature of Type-C is excessively high, disconnection at this time is electrically connected with outside Type-C equipment, to stop connecing to external Type-C
Confession electricity, avoids the temperature of Type-C interfaces from continuing to increase.
Wherein it is possible to set preset temperature section to [Tmin ,+∞), Tmin expressions may cause electronic equipment to damage
Lowest temperature angle value, specifically can first pass through experiment in advance and obtain.
For example, preset temperature section be arranged to [60 DEG C ,+∞), if get Type-C interfaces temperature value be 37 DEG C,
Then electronic equipment continues as external Type-C equipment power supply;If the temperature value for getting Type-C interfaces is 67 DEG C, electronics is set
Standby disconnection is electrically connected with outside Type-C equipment, stops powering for external Type-C equipment.
In one embodiment, it when the temperature value got is located within preset temperature section, disconnects and outside Type-C
The electrical connection of equipment, including:
When the temperature value got is located within preset temperature section, information input window is shown;
When the information input window based on display receives the confirmation message of input, disconnect and outside Type-C equipment
Electrical connection.
In the embodiment of the present application, determines whether to disconnect by user and be electrically connected with outside Type-C equipment.For example, please referring to
Fig. 7, electronic equipment are getting the temperature value of Type-C interfaces, and when judging that the temperature value is located within preset temperature section,
Show that information input window, the information input window include "Yes" control and "No" control and prompt user in on-screen display (osd) area
Whether disconnect with the prompt message of outside Type-C equipment " Current Temperatures are excessively high, if disconnect peripheral hardware ", user can pass through click
"Yes" control is clicked the input of "No" control and is denied information with input validation information.Wherein, if electronic equipment receives user's input
Confirmation message, then disconnect and being electrically connected with outside Type-C equipment;If receive it is input by user deny information, do not grasp
Make, continues as external Type-C equipment power supply.
Below by the basis of the method that above-described embodiment describes, further Jie is done to the equipment detection method of the application
It continues.Specifically, please referring to Fig. 4, the Type-C interfaces of electronic equipment include interface section and casing part, and casing part is surrounded
Interface section is arranged range sensor in the casing part of Type-C interfaces, and the test side direction of the range sensor is arranged
The interface section of Type-C interfaces, please refers to Fig. 8, and the detailed process of the equipment detection method is as follows:
In step 201, the distance value that range sensor detects is obtained, and judges whether the distance value got is located at
Within pre-determined distance section.
It should be noted that for using which kind of range sensor, being not particularly limited in the embodiment of the present application, it can be by this
Field technology personnel select according to actual needs, can select laser distance sensor, infrared distance sensor and surpass
Any one of different types range sensor such as sound wave range sensor, for example, the embodiment of the present application is in Type-C interfaces
Infrared distance sensor is arranged in casing part, and the test side of the infrared distance sensor is towards interface section.
As shown in figure 4, when not having external object in Type-C interfaces, the range sensor being arranged in casing part will be examined
Its own distance value to interface section is measured, and has external object in Type-C interfaces, for example external Type-C equipment connects
Fashionable, what range sensor detected will be its own distance value to the Type-C interfaces of external Type-C equipment.
It is easily understood that when external object being not present in the Type-C interfaces of electronic equipment, it is clear that be impossible have
External Type-C equipment access, and when the Type-C interfaces memory of electronic equipment is in external object, it has been likely to outside
Type-C equipment accesses, therefore, in the embodiment of the present application, the distance that electronic equipment can be detected according to range sensor
Value is accessed to judge to whether there is external object in its Type-C interface with tentatively judging whether there is external Type-C equipment.
Wherein, when detecting in Type-C interfaces with the presence or absence of external object, electronic equipment obtains range sensor first
The distance value detected, then judges whether the distance value got is located within pre-determined distance section, and is tied according to judgement
Fruit, which determines, whether there is external object in Type-C interfaces.
In step 202, if the distance value got is located within pre-determined distance section, it is determined that Type-C interface memories
Default detection voltage is provided in external object, and for the configurating channel pin of Type-C interfaces.
Wherein, if the distance value got is located within pre-determined distance section, electronic equipment determines its Type-C interface
Memory is in external object, if the distance value got is located at except pre-determined distance section, electronic equipment determines that its Type-C connects
External object is not present in mouthful.
Wherein it is possible to set [0, Lmax] pre-determined distance section to, Lmax indicates external Type-C equipment access electricity
When the Type-C interfaces of sub- equipment, maximum range value that range sensor can be detected be (different external Type-C equipment
Type-C interfaces thickness is different, when leading to the Type-C interfaces of different external Type-C equipment access electronic equipments, Distance-sensing
Distance value detected by device is different), specifically experiment can be first passed through in advance obtain.
For example, pre-determined distance section is arranged to [0,0.5mm], if the distance value got is (such as no outsides 1mm
When Type-C equipment accesses the Type-C interfaces of electronic equipment), electronic equipment will detect that there is no outer in its Type-C interface
Portion's object;
If the distance value got, which is 0.2mm, (accesses the Type-C interfaces of electronic equipment if any external Type-C equipment
When), electronic equipment will detect its Type-C interface memory in external object.
In the embodiment of the present application, when detecting Type-C interfaces memory in external object, that is, illustrate currently have outer
Portion's Type-C equipment access, at this point, default detection voltage can be provided for the configurating channel pin of Type-C interfaces, to be based on this
Configurating channel pin realizes the access detection of external Type-C equipment.
Wherein, which can be a pwm voltage, and voltage value range can be for 2.4V extremely
3.4V, period value range can be 50ms to 100ms, and duty ratio value range can be 30% to 70%.
For example, electronic equipment matches confidence when detecting Type-C interfaces memory in external object, for Type-C interfaces
Road pin provide voltage value be 3.4V, the default detection voltage that period 50ms, duty ratio are 70%.
In step 203, the voltage change of configurating channel pin is obtained, and whether judges the voltage change got
Within predeterminated voltage section.
In the embodiment of the present application, after default detection voltage is provided for Type-C interfaces, configurating channel pin is carried out
Voltage detecting gets the current voltage of configurating channel pin, and calculates the voltage difference of default detection voltage and the current voltage
Value, using the voltage difference being calculated as the voltage change of configurating channel.
In the embodiment of the present application, the Type-C interfaces of electronic equipment are configured as downstream interface, that is to say that electronic equipment is made
For main equipment.It is configured as upstream Interface in the Type-C interfaces of external Type-C equipment, that is to say that external Type-C equipment is made
For from equipment when, the configurating channel pins of Type-C interfaces be connected with pull down resistor (pull down resistor can be one individually
Resistance, can also be the series connection of multiple resistance and/or compose in parallel).
It is easily understood that the Type-C interfaces in external Type-C equipment are linked into the Type-C interfaces of electronic equipment
When, the configurating channel pin of electronic equipment will be connect with the configurating channel pin of external Type-C equipment so that electronic equipment
Configurating channel pin is connect with the pull down resistor of outside Type-C equipment, drags down the voltage on electronic equipment configurating channel pin.
Electronic equipment can be by the voltage change of its configurating channel pin, to judge in its Type-C interface as a result,
Whether existing external object is external Type-C equipment (being specially the Type-C interfaces of external Type-C equipment).
It should be noted that for different function external Type-C equipment (such as using Type-C interfaces earphone and U
Disk etc.), the resistance value for the pull down resistor that configurating channel pin is connected is different, correspondingly, in the outside of different function
When Type-C equipment accesses electronic equipment, the voltage pull-down degree of the configurating channel pin of electronic equipment is different.Therefore,
One predeterminated voltage section can be set, come reflect different function external Type-C equipment voltage pull-down degree, for example, should
Predeterminated voltage section could be provided as [Vmin, Vmax], when Vmin is that external Type-C equipment accesses electronic equipment, drag down electronics
The minimum amount of voltage that of the configurating channel pin of equipment drags down electronics and sets when Vmax is that external Type-C equipment accesses electronic equipment
The maximum voltage value of standby configurating channel pin.Wherein, the value of Vmin and Vmax can be determined by experiment in advance, for example, determining
Vmin be 1.5V, determining Vmax be 3V, then can obtain predeterminated voltage section [1.5V, 3V].
In the embodiment of the present application, according to voltage change, when judging whether external object is external Type-C equipment, electricity
Sub- equipment may determine that whether the voltage change got is located within predeterminated voltage section, and be determined according to judging result
Whether the external object in Type-C interfaces is external Type-C equipment.
In step 204, when the voltage change got is located within predeterminated voltage section, Type-C interfaces are determined
Interior external object is external Type-C equipment.
Wherein, if voltage change is located within the predeterminated voltage section, electronic equipment determines that external object is outside
Type-C equipment;If voltage change is located at except the predeterminated voltage section, it is outside that electronic equipment, which determines external object not,
Type-C equipment.
For example, when predeterminated voltage section is [1.5V, 3V], if electronic equipment gets the voltage of its configurating channel pin
Changing value is 2V, then can determine that the external object in its Type-C interface is external Type-C equipment;If electronic equipment obtains
Voltage change to its configurating channel pin is 0.2V, then it is outside that can determine the external object in its Type-C interface not
Type-C equipment.
In step 205, it is electrically connected with the foundation of outside Type-C equipment by Type-C interfaces.
In the embodiment of the present application, when it is external Type-C equipment to determine the external object in Type-C interfaces, electronics is set
Standby established by Type-C interfaces and outside Type-C equipment is electrically connected, wherein electronic equipment is and external as main equipment
Type-C equipment is used as from equipment.
In step 206, it according to aforesaid voltage changing value, is provided pair to external Type-C equipment by the electrical connection of foundation
The supply voltage answered is powered for external Type-C equipment.
It is retouched based on the correlation above with respect to " according to voltage change, judging whether external object is external Type-C equipment "
It states, it is known that when the external Type-C equipment of different function accesses electronic equipment, detected its of electronic equipment matches confidence
Voltage change on road pin is different.In addition, those skilled in the art can learn, the external Type-C of different function
Supply voltage needed for equipment is different, for example, using the supply voltage needed for the earphone of Type-C interfaces for 3.3V;For another example,
Use the supply voltage needed for the USB flash disk of Type-C interfaces for 4.5V.
Therefore, in the embodiment of the present application, it is previously provided with the correspondence of voltage change and supply voltage.Correspondingly,
Electronic equipment is detecting its Type-C interfaces memory in external object, and determines that the external object is external Type-C equipment
When, it is closed according to the voltage change of the configurating channel pin got and aforesaid voltage changing value are corresponding with supply voltage
System determines the supply voltage corresponding to the voltage change got, is carried by the external Type-C equipment that electrically connects as of foundation
For determining supply voltage.
Thus, it is possible to by the voltage change on configurating channel pin, the work(of external Type-C equipment is further identified
Energy type, and provide corresponding supply voltage for it.
A kind of assembly detection apparatus is additionally provided in one embodiment.Fig. 9 is please referred to, Fig. 9 provides for the embodiment of the present application
Assembly detection apparatus structural schematic diagram.Wherein the assembly detection apparatus is applied to electronic equipment, the assembly detection apparatus packet
Object detection module 401, voltage offer module 402, voltage acquisition module 403 and equipment identification module 404 are provided, it is as follows:
Object detection module 401 whether there is external object for detecting in Type-C interfaces;
Voltage provides module 402, for when Type-C interfaces memory is in external object, matching confidence for Type-C interfaces
Road pin provides default detection voltage;
Voltage acquisition module 403, the voltage change for obtaining configurating channel pin;
Equipment identification module 404, for according to voltage change, judging whether external object is external Type-C equipment.
In one embodiment, Type-C interfaces include casing part and interface section, which is provided with distance and passes
Sensor, and the test side of range sensor, towards interface section, object detection module 401 is specifically used for:
Obtain the distance value that range sensor detects;
Judge the distance value whether be located at pre-determined distance section within, wherein if distance value be located at pre-determined distance section it
Interior, then Type-C interfaces memory is in external object.
Equipment identification module 404 is specifically used in one embodiment:
Judge whether voltage change is located within predeterminated voltage section, wherein if voltage change is located at predeterminated voltage
In section, then external object is external Type-C equipment.
In one embodiment, voltage provides module 402 and is additionally operable to:
Detecting that there is no when external object, stop providing default detection electricity for configurating channel pin in Type-C interfaces
Pressure.
In one embodiment, assembly detection apparatus further includes connection establishment module, is used for:
If external object is external Type-C equipment, it is electrically connected by Type-C interfaces and the foundation of outside Type-C equipment
It connects;
Voltage provides module 402 and is additionally operable to according to voltage change, by the electrical connection of foundation to external Type-C equipment
Corresponding supply voltage is provided, is powered for external Type-C equipment.
In one embodiment, connection establishment module is additionally operable to:
Module 402 is provided to during external Type-C equipment offer supply voltage in voltage, obtains the temperature of Type-C interfaces
Angle value;
When the temperature value of Type-C interfaces is located within preset temperature section, the electrical connection of foundation is disconnected.
In one embodiment, connection establishment module is specifically used for:
When the temperature value of Type-C interfaces is located within preset temperature section, information input window is shown;
When receiving the confirmation message of input based on information input window, the electrical connection of foundation is disconnected.
When it is implemented, the above modules can be used as independent entity to realize, arbitrary combination can also be carried out, as
Same or several entities realize that the specific implementation of above each unit can be found in the embodiment of front, and details are not described herein.
From the foregoing, it will be observed that the present embodiment assembly detection apparatus 400 can be detected by object detection module 401 in Type-C interfaces
With the presence or absence of external object;Module 402 is provided when Type-C interfaces memory is in external object by voltage, is Type-C interfaces
Configurating channel pin provides default detection voltage;The voltage change of configurating channel pin is obtained by voltage acquisition module 403;By
Equipment identification module 404 judges whether external object is external Type-C equipment according to voltage change.In the program, not
It needs the configurating channel pin powered for being continuously Type-C interfaces, but is detecting Type-C interfaces there are external object,
When to be Type-C interfaces may access external Type-C equipment, default detection voltage just is provided to configurating channel pin, is realized
Access detection to external Type-C equipment, thus, it is only necessary to be in a relatively short period of time configurating channel pin powered, to drop
Type-C equipment access detection reaches raising Type-C interfaces and uses the longevity to the corrosion caused by Type-C interfaces outside low realization
The purpose of life.
The embodiment of the present application also provides a kind of electronic equipment.Please refer to Figure 10, electronic equipment 500 include processor 501 with
And memory 502.Wherein, processor 501 is electrically connected with memory 502.
The processor 500 is the control centre of electronic equipment 500, is set using various interfaces and the entire electronics of connection
Standby various pieces by the computer program of operation or load store in memory 502, and are called and are stored in memory
Data in 502 execute the various functions of electronic equipment 500 and handle data.
The memory 502 can be used for storing software program and module, and processor 501 is stored in memory by operation
502 computer program and module, to perform various functions application and data processing.Memory 502 can include mainly
Storing program area and storage data field, wherein storing program area can storage program area, the computer needed at least one function
Program (such as sound-playing function, image player function etc.) etc.;Storage data field can be stored uses institute according to electronic equipment
The data etc. of establishment.In addition, memory 502 may include high-speed random access memory, can also include non-volatile memories
Device, for example, at least a disk memory, flush memory device or other volatile solid-state parts.Correspondingly, memory
502 can also include Memory Controller, to provide access of the processor 501 to memory 502.
In the embodiment of the present application, the processor 501 in electronic equipment 500 can be according to following step, by one or one
The corresponding instruction of process of a above computer program is loaded into memory 502, and is stored in by the operation of processor 501
Computer program in reservoir 502, it is as follows to realize various functions:
It detects and whether there is external object in Type-C interfaces;
When Type-C interfaces memory is in external object, default detection electricity is provided for the configurating channel pin of Type-C interfaces
Pressure;
Obtain the voltage change of configurating channel pin;
According to voltage change, judge whether external object is external Type-C equipment.
Please with reference to Figure 11, in some embodiments, electronic equipment 500 can also include:Display 503, radio frequency
Circuit 504, voicefrequency circuit 505 and power supply 506.Wherein, wherein display 503, radio circuit 504, voicefrequency circuit 505 with
And power supply 506 is electrically connected with processor 501 respectively.
The display 503 is displayed for information input by user or is supplied to the information of user and various figures
Shape user interface, these graphical user interface can be made of figure, text, icon, video and its arbitrary combination.Display
503 may include display panel, in some embodiments, liquid crystal display (Liquid Crystal may be used
Display, LCD) or the forms such as Organic Light Emitting Diode (Organic Light-Emitting Diode, OLED) match
Set display panel.
The radio circuit 504 can be used for transceiving radio frequency signal, with by radio communication with the network equipment or other electricity
Sub- equipment establishes wireless telecommunications, the receiving and transmitting signal between the network equipment or other electronic equipments.
The voicefrequency circuit 505 can be used for providing the audio between user and electronic equipment by loud speaker, microphone
Interface.
The power supply 506 is used to all parts power supply of electronic equipment 500.In some embodiments, power supply 506
Can be logically contiguous by power-supply management system and processor 501, to realize management charging by power-supply management system, put
The functions such as electricity and power managed.
Although being not shown in Figure 11, electronic equipment 500 can also include camera, bluetooth module etc., and details are not described herein.
In some embodiments, Type-C interfaces include casing part and interface section, the casing part be provided with away from
From sensor, and the test side of range sensor whether there is external object towards interface section in detection Type-C interfaces
When, processor 501 can specifically execute following steps:
Obtain the distance value that range sensor detects;
Judge the distance value whether be located at pre-determined distance section within, wherein if distance value be located at pre-determined distance section it
Interior, then Type-C interfaces memory is in external object.
In some embodiments, according to voltage change, when judging whether external object is external Type-C equipment,
Processor 501 can specifically execute following steps:
Judge whether voltage change is located within predeterminated voltage section, wherein if voltage change is located at predeterminated voltage
In section, then external object is external Type-C equipment.
In some embodiments, after default detection voltage is provided for the configurating channel pin of Type-C interfaces, place
Reason device 501 can specifically execute following steps:
Detecting that there is no when external object, stop providing default detection electricity for configurating channel pin in Type-C interfaces
Pressure.
In some embodiments, according to voltage change, judge external object whether be external Type-C equipment it
Afterwards, following steps can also be performed in processor 501:
If external object is external Type-C equipment, it is electrically connected by Type-C interfaces and the foundation of outside Type-C equipment
It connects;
Voltage provides module 402 and is additionally operable to according to voltage change, by the electrical connection of foundation to external Type-C equipment
Corresponding supply voltage is provided, is powered for external Type-C equipment.
In some embodiments, following steps can also be performed in processor 501:
During providing supply voltage to external Type-C equipment, the temperature value of Type-C interfaces is obtained;
When the temperature value of Type-C interfaces is located within preset temperature section, the electrical connection of foundation is disconnected.
In some embodiments, when disconnecting the electrical connection established, following steps can also be performed in processor 501:
When the temperature value of Type-C interfaces is located within preset temperature section, information input window is shown;
When receiving the confirmation message of input based on information input window, the electrical connection of foundation is disconnected.
The embodiment of the present application also provides a kind of storage medium, and the storage medium is stored with computer program, when the meter
When calculation machine program is run on computers so that the computer executes the equipment detection method in any of the above-described embodiment, than
Such as:It detects and whether there is external object in Type-C interfaces;It is Type-C interfaces when Type-C interfaces memory is in external object
Configurating channel pin default detection voltage is provided;Obtain the voltage change of configurating channel pin;According to voltage change, sentence
Whether disconnected external object is external Type-C equipment.
In the embodiment of the present application, storage medium can be magnetic disc, CD, read-only memory (Read Only Memory,
ROM) or random access memory (Random Access Memory, RAM) etc..
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, there is no the portion being described in detail in some embodiment
Point, it may refer to the associated description of other embodiment.
It should be noted that for the equipment detection method of the embodiment of the present application, those of ordinary skill in the art can be with
The all or part of flow for understanding the equipment detection method for realizing the embodiment of the present application, is that can be controlled by computer program
Relevant hardware is completed, and the computer program can be stored in a computer read/write memory medium, be such as stored in electronics
It in the memory of equipment, and is executed, may include in the process of implementation such as equipment by least one processor in the electronic equipment
The flow of the embodiment of detection method.Wherein, the storage medium can be magnetic disc, CD, read-only memory, arbitrary access note
Recall body etc..
For the assembly detection apparatus of the embodiment of the present application, each function module can be integrated in a processing chip
In, can also be that modules physically exist alone, can also two or more modules be integrated in a module.It is above-mentioned
The form that hardware had both may be used in integrated module is realized, can also be realized in the form of software function module.It is described integrated
If module realized in the form of software function module and when sold or used as an independent product, one can also be stored in
In a computer read/write memory medium, the storage medium is for example read-only memory, disk or CD etc..
A kind of equipment detection method, device, storage medium and the electronic equipment that the embodiment of the present application is provided above into
It has gone and has been discussed in detail, specific examples are used herein to illustrate the principle and implementation manner of the present application, the above implementation
The explanation of example is merely used to help understand the present processes and its core concept;Meanwhile for those skilled in the art, according to
According to the thought of the application, there will be changes in the specific implementation manner and application range, in conclusion the content of the present specification
It should not be construed as the limitation to the application.
Claims (10)
1. a kind of equipment detection method, which is characterized in that including:
It detects and whether there is external object in Type-C interfaces;
There are when the external object in the Type-C interfaces, for the Type-C interfaces configurating channel pin provide it is pre-
If detecting voltage;
Obtain the voltage change of the configurating channel pin;
According to the voltage change, judge whether the external object is external Type-C equipment.
2. equipment detection method as described in claim 1, which is characterized in that the Type-C interfaces include casing part and connect
Oral area point, the casing part are provided with range sensor, and the test side of the range sensor is towards the interface section,
It detects and whether there is external object in Type-C interfaces, including:
Obtain the distance value that the range sensor detects;
Judge whether the distance value is located within pre-determined distance section, wherein if the distance value is located at the pre-determined distance
Within section, then the Type-C interfaces memory is in external object.
3. equipment detection method as described in claim 1, which is characterized in that according to the voltage change, judge described outer
Whether portion's object is external Type-C equipment, including:
Judge whether the voltage change is located within predeterminated voltage section, wherein if the voltage change is positioned at described
In predeterminated voltage section, then the external object is external Type-C equipment.
4. equipment detection method as described in claim 1, which is characterized in that be the configurating channel pin of the Type-C interfaces
After default detection voltage is provided, further include:
It is detecting in the Type-C interfaces there is no when the external object, is stopping providing for the configurating channel pin pre-
If detecting voltage.
5. equipment detection method according to any one of claims 1-4, which is characterized in that according to the voltage change, sentence
After whether the external object of breaking is external Type-C equipment, further include:
If the external object is external Type-C equipment, built by the Type-C interfaces and the external Type-C equipment
Vertical electrical connection;
According to the voltage change, corresponding supply voltage is provided by described be electrically connected to the external Type-C equipment,
For the external Type-C equipment power supply.
6. equipment detection method as claimed in claim 5, which is characterized in that further include:
During providing the supply voltage to the external Type-C equipment, the temperature value of the Type-C interfaces is obtained;
When the temperature value is located within preset temperature section, the electrical connection is disconnected.
7. equipment detection method as claimed in claim 6, which is characterized in that the temperature value be located at preset temperature section it
When interior, the electrical connection is disconnected, including:
When the temperature value is located within preset temperature section, information input window is shown;
When receiving the confirmation message of input based on described information input window, the electrical connection is disconnected.
8. a kind of assembly detection apparatus, which is characterized in that including:
Object detection module whether there is external object for detecting in Type-C interfaces;
Voltage provides module, for there are when the external object, be the Type-C interfaces in the Type-C interfaces
Configurating channel pin provides default detection voltage;
Voltage acquisition module, the voltage change for obtaining the configurating channel pin;
Equipment identification module, for according to the voltage change, judging whether the external object is external Type-C equipment.
9. a kind of storage medium, is stored thereon with computer program, which is characterized in that when the computer program on computers
When operation so that the computer executes equipment detection method as described in any one of claim 1 to 7.
10. a kind of electronic equipment, including processor and memory, the memory storage have computer program, which is characterized in that
The processor is by calling the computer program, for executing equipment detection side as described in any one of claim 1 to 7
Method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810475646.3A CN108628713B (en) | 2018-05-17 | 2018-05-17 | Device detection method and device, storage medium and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810475646.3A CN108628713B (en) | 2018-05-17 | 2018-05-17 | Device detection method and device, storage medium and electronic device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108628713A true CN108628713A (en) | 2018-10-09 |
CN108628713B CN108628713B (en) | 2021-06-01 |
Family
ID=63693691
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810475646.3A Active CN108628713B (en) | 2018-05-17 | 2018-05-17 | Device detection method and device, storage medium and electronic device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108628713B (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110112620A (en) * | 2019-05-30 | 2019-08-09 | 维沃移动通信有限公司 | A kind of terminal device and control method |
CN112333327A (en) * | 2020-11-20 | 2021-02-05 | Oppo广东移动通信有限公司 | Equipment detection method, device, storage medium, electronic equipment, external equipment and system |
CN112397948A (en) * | 2019-08-13 | 2021-02-23 | 北京小米移动软件有限公司 | Female seat of Type-C, Type-C plug system and electronic system |
CN112510345A (en) * | 2019-09-16 | 2021-03-16 | 北京小米移动软件有限公司 | External antenna device, control method and device thereof, and storage medium |
CN112510361A (en) * | 2019-09-16 | 2021-03-16 | 北京小米移动软件有限公司 | Passive antenna and antenna system |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105975039A (en) * | 2016-04-29 | 2016-09-28 | 乐视控股(北京)有限公司 | Method and device for controlling power supply of Type-C interface, and electronic equipment |
CN107451079A (en) * | 2017-08-09 | 2017-12-08 | 合肥联宝信息技术有限公司 | The identification of lines method and device of a kind of electronic equipment |
US10539999B2 (en) * | 2016-08-25 | 2020-01-21 | Samsung Electronics Co., Ltd. | Semiconductor device and method of operating the same |
-
2018
- 2018-05-17 CN CN201810475646.3A patent/CN108628713B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105975039A (en) * | 2016-04-29 | 2016-09-28 | 乐视控股(北京)有限公司 | Method and device for controlling power supply of Type-C interface, and electronic equipment |
US10539999B2 (en) * | 2016-08-25 | 2020-01-21 | Samsung Electronics Co., Ltd. | Semiconductor device and method of operating the same |
CN107451079A (en) * | 2017-08-09 | 2017-12-08 | 合肥联宝信息技术有限公司 | The identification of lines method and device of a kind of electronic equipment |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110112620A (en) * | 2019-05-30 | 2019-08-09 | 维沃移动通信有限公司 | A kind of terminal device and control method |
CN110112620B (en) * | 2019-05-30 | 2020-09-22 | 维沃移动通信有限公司 | Terminal equipment and control method |
CN112397948A (en) * | 2019-08-13 | 2021-02-23 | 北京小米移动软件有限公司 | Female seat of Type-C, Type-C plug system and electronic system |
CN112510345A (en) * | 2019-09-16 | 2021-03-16 | 北京小米移动软件有限公司 | External antenna device, control method and device thereof, and storage medium |
CN112510361A (en) * | 2019-09-16 | 2021-03-16 | 北京小米移动软件有限公司 | Passive antenna and antenna system |
CN112333327A (en) * | 2020-11-20 | 2021-02-05 | Oppo广东移动通信有限公司 | Equipment detection method, device, storage medium, electronic equipment, external equipment and system |
CN112333327B (en) * | 2020-11-20 | 2022-01-07 | Oppo广东移动通信有限公司 | Equipment detection method, device, storage medium, electronic equipment, external equipment and system |
Also Published As
Publication number | Publication date |
---|---|
CN108628713B (en) | 2021-06-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108628713A (en) | Equipment detection method, device, storage medium and electronic equipment | |
CN108681514A (en) | Equipment detection method, device, storage medium and electronic equipment | |
US10042801B2 (en) | System for detecting universal serial bus (USB) device and method thereof | |
WO2017185686A1 (en) | Charging power adjusting method and apparatus, and electronic device | |
EP2774017B1 (en) | Device charging over usb using a plurality of handshakes | |
US9860659B2 (en) | Method and apparatus for identifying foreign substances in connectors | |
US9723408B2 (en) | Electronic device and method of preventing erroneous recognizing inserting connector into earphone jack | |
TWI451703B (en) | Mobile terminal aware of external device and control method for the same | |
US10177590B2 (en) | Electronic device having auxiliary battery embedded therein and method of charging auxiliary battery | |
AU2015312625A1 (en) | Electronic device, method of controlling charging by electronic device, and method of supplying power by power supply device | |
CN111239617B (en) | Control method and device for charge and discharge test, storage medium and system | |
KR20200070630A (en) | Electronic device and method for adjusting charge cycle or discharge cycle of battery | |
CN106786960A (en) | Charge control method, device and terminal | |
CN108614655A (en) | Multi-screen display method, device, storage medium and electronic equipment | |
CN109378877A (en) | Charging circuit, charging method, electronic equipment and storage medium | |
CN108988513A (en) | Wireless charging alignment methods, device, storage medium and electronic equipment | |
US8740456B2 (en) | Adjusting delivery of current in a connection based on temperature | |
CN106331376A (en) | Power saving method and mobile terminal | |
WO2018218686A1 (en) | Method for detecting swelling of rechargeable battery, and portable electronic device | |
TW202030579A (en) | Indicator for ac power adapter | |
CN108664430B (en) | Equipment identification method and device, storage medium and electronic equipment | |
US8780514B2 (en) | Data cable and electronic device using same | |
CN112378331B (en) | Electronic device, battery deformation detection method, and readable storage medium | |
CN110994052B (en) | Method and device for prolonging battery endurance, storage medium and terminal equipment | |
US10289290B2 (en) | Apparatus and method for displaying a portion of a plurality of background applications |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |