CN109561415B - NFC function detection method and device, storage medium and mobile terminal - Google Patents

NFC function detection method and device, storage medium and mobile terminal Download PDF

Info

Publication number
CN109561415B
CN109561415B CN201811574404.6A CN201811574404A CN109561415B CN 109561415 B CN109561415 B CN 109561415B CN 201811574404 A CN201811574404 A CN 201811574404A CN 109561415 B CN109561415 B CN 109561415B
Authority
CN
China
Prior art keywords
electrode plate
mobile terminal
distance
nfc function
nfc
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.)
Active
Application number
CN201811574404.6A
Other languages
Chinese (zh)
Other versions
CN109561415A (en
Inventor
俞斌
杨维琴
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Huaxi Investment Co ltd
Original Assignee
Huizhou TCL Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huizhou TCL Mobile Communication Co Ltd filed Critical Huizhou TCL Mobile Communication Co Ltd
Priority to CN201811574404.6A priority Critical patent/CN109561415B/en
Publication of CN109561415A publication Critical patent/CN109561415A/en
Application granted granted Critical
Publication of CN109561415B publication Critical patent/CN109561415B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/24Arrangements for testing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/08Testing, supervising or monitoring using real traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information
    • H04W4/021Services related to particular areas, e.g. point of interest [POI] services, venue services or geofences

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the application discloses a method and a device for detecting an NFC function, a storage medium and a mobile terminal; the NFC function detection method comprises the following steps: acquiring a distance between a first detection point arranged on the NFC antenna and a second detection point arranged on a mobile terminal main board; determining whether the distance is smaller than a preset threshold value; if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state; and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. This scheme can be after mobile terminal changes the back lid, and whether the NFC antenna in this back lid matches with this mobile terminal of accurate judgement, avoids appearing the unusual problem of NFC function.

Description

NFC function detection method and device, storage medium and mobile terminal
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for detecting an NFC function, a storage medium, and a mobile terminal.
Background
With the rapid development of Communication technology, more and more mobile terminals use Near Field Communication (NFC) technology.
One of the key points of the NFC technology is that the NFC antenna is generally disposed in a rear cover of the mobile terminal due to a large area, so that the sensing distance of the NFC antenna can be effectively maintained. Then the lid is as mobile terminal's surface device, easily takes place to fall, the condition such as collide in the use to lead to the NFC antenna impaired, consequently need change the lid after can normally use the NFC function. Because the back covers of various types of mobile terminals may be the same, but the NFC antennas of the mobile terminals are different, when the back covers of the mobile terminals are replaced, the NFC function is easy to be abnormal.
Disclosure of Invention
The embodiment of the application provides an NFC function detection method and device, a storage medium and a mobile terminal, and after a rear cover of the mobile terminal is replaced, whether an NFC antenna in the rear cover is matched with the mobile terminal can be accurately judged, so that the problem of abnormal NFC function is avoided.
In a first aspect, an embodiment of the present application provides an NFC function detection method, including:
acquiring a distance between a first detection point arranged on the NFC antenna and a second detection point arranged on a mobile terminal main board;
determining whether the distance is smaller than a preset threshold value;
if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state;
and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
In a second aspect, an embodiment of the present application provides an NFC function detection apparatus, including:
the distance acquisition unit is used for acquiring the distance between a first detection point arranged on the NFC antenna and a second detection point arranged on the mobile terminal main board;
the distance judging unit is used for determining whether the distance is smaller than a preset threshold value or not;
a state determining unit, configured to determine that an NFC function of the mobile terminal is in a normal state when the distance is smaller than the preset threshold value; and when the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
In a third aspect, an embodiment of the present application provides a storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the NFC functionality detection method described above.
In a fourth aspect, an embodiment of the present application provides a mobile terminal, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the NFC function detection method when executing the program.
The method comprises the steps of obtaining the distance between a first detection point arranged on an NFC antenna and a second detection point arranged on a mobile terminal main board; determining whether the distance is smaller than a preset threshold value; if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state; and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. According to the scheme, the distance between the first detection point and the second detection point is compared with the preset threshold value, and whether the NFC function is in a normal state or not is determined according to the comparison result; therefore, after the rear cover of the mobile terminal is replaced, whether the NFC antenna in the rear cover is matched with the mobile terminal or not can be accurately judged, and the situation that the NFC function is abnormal after the rear cover of the mobile terminal is replaced is avoided.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic flowchart of an NFC function detection method provided in an embodiment of the present application.
Fig. 2 is another schematic flowchart of an NFC functionality detection method according to an embodiment of the present application.
Fig. 3 is a schematic structural diagram of an NFC functionality detection apparatus according to an embodiment of the present application.
Fig. 4 is another schematic structural diagram of an NFC functionality detection apparatus according to an embodiment of the present application.
Fig. 5 is a schematic structural diagram of a mobile terminal according to an embodiment of the present application.
Fig. 6 is another schematic structural diagram of a mobile terminal according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It is to be understood that the embodiments described are only a few embodiments of the present application and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the NFC antenna is generally disposed on the rear cover of the mobile terminal due to its large area, so that the sensing distance of the NFC antenna can be effectively maintained. Then the lid is as mobile terminal's surface device, easily takes place to fall, the condition such as collide in the use to lead to the NFC antenna impaired, consequently need change the lid after can normally use the NFC function. Because the back covers of various types of mobile terminals may be the same, but the NFC antennas of the mobile terminals are different, when the back covers of the mobile terminals are replaced, the NFC function is easy to be abnormal.
In this regard, an embodiment of the present application provides an NFC function detection method, an apparatus, a storage medium, and a mobile terminal, where an execution main body of the NFC function detection method may be the NFC function detection apparatus provided in the embodiment of the present application, and the NFC function detection apparatus may be implemented in a hardware or software manner. In a specific embodiment, the NFC functionality detection apparatus may be integrated in a mobile terminal, for example, a terminal device such as a smart phone or a tablet computer.
The details will be described below separately.
Referring to fig. 1, fig. 1 is a schematic flowchart of an NFC function detection method provided in the embodiment of the present application, and a specific flowchart may be as follows:
101. and acquiring the distance between a first detection point arranged on the NFC antenna and a second detection point arranged on the main board of the mobile terminal.
In some embodiments, a trigger mechanism, such as an icon, a key, etc., may be provided in the mobile terminal, and after the mobile terminal changes the rear cover, a user may send a distance obtaining instruction through the trigger mechanism to obtain the distance between the first electrode plate and the second electrode plate. In some embodiments, a timer may be further disposed in the mobile terminal, and the distance between the first electrode plate and the second electrode plate is obtained at intervals of a preset time period, where the preset time period may be set according to an actual situation.
In some embodiments, the first detection point may be disposed on a Flexible Printed Circuit (FPC) of the NFC antenna, and the second detection point may be disposed on a main board of the mobile terminal. The first detecting point may be a first electrode plate, and the second detecting point may be a second electrode plate. In some embodiments, the first electrode plate and the second electrode plate are equal in area.
It should be noted that, after the FPC of the NFC antenna is enabled, the first electrode plate and the second electrode plate are just opposite to each other, and a capacitor may be formed. It can be understood that the distance between the first detection point and the second detection point is the distance between the first electrode plate and the second electrode plate.
It should be noted that, there are various ways to obtain the distance between the first electrode plate and the second electrode plate, for example, a distance sensor may be disposed in the mobile terminal, and the distance between the two electrode plates is obtained by the distance sensor; for another example, the distance between the first electrode plate and the second electrode plate can be obtained by obtaining a capacitance value between the first electrode plate and the second electrode plate.
Wherein, can predetermine the capacitance value between two electrode boards to be C, the distance is D, the dielectric constant is epsilon, the area of two electrode boards is S, then can be by the capacitance value formula between two electrode boards: and C is equal to epsilon S/D, and the distance D between the two electrode plates is equal to epsilon S/C, wherein epsilon and S are both known quantities. That is, the step of "acquiring the distance between the first detection point disposed on the NFC antenna and the second detection point disposed on the main board of the mobile terminal" may include:
acquiring a capacitance value between the first electrode plate and the second electrode plate;
and acquiring the distance between the first electrode plate and the second electrode plate according to the capacitance value.
The capacitance value between the first electrode plate and the second electrode plate is unknown and needs to be obtained through other methods. For example, it may be preset that the voltage difference between the first electrode plate and the second electrode plate is U, the electric quantity value is Q, the capacitance value is C, and the capacitance value is Q/U.
In some embodiments, the capacitor formed by the first electrode plate and the second electrode plate may be charged, and when the charging is completed, the voltage difference U between the first electrode plate and the second electrode plate may be directly obtained. That is, the step of "obtaining a capacitance value between the first electrode plate and the second electrode plate" may include:
charging the first electrode plate and the second electrode plate;
when charging is completed, acquiring a voltage difference value between the first electrode plate and the second electrode plate;
and acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value.
It should be noted that, during the charging process, the voltage difference between the first electrode plate and the second electrode plate may be changed continuously, and when the voltage difference does not change any more for a period of time, the charging process may be considered to be completed. In some embodiments, the voltage difference between the first electrode plate and the second electrode plate may be continuously detected during the charging process; and when the voltage difference value is detected not to change for the preset time, determining that the charging is finished. The preset time may be set according to actual conditions, for example, 1 second, 2 seconds, or 3 seconds.
The step of obtaining the capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value may include:
acquiring an electric quantity value between the first electrode plate and the second electrode plate;
and acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value and the electric quantity value.
In some embodiments, an electric quantity obtaining module may be disposed in the mobile terminal, and the first electrode plate and the second electrode plate are connected through a resistor R. In the implementation, a timer for a preset time period t may be set, and the electric quantity Q may be set to zero. After waiting for a preset time period t, acquiring voltage values at two ends of the resistor R, and if the voltage values at two ends of the resistor R are zero, determining that the electric quantity Q is completely acquired; if the voltage values at the two ends of the resistor R are not zero, the voltage values at the two ends of the resistor R can be acquired after waiting for a preset time period. The preset time period t is a very small time interval, for example, 5 microseconds, 10 microseconds, or the like.
The electric quantity value Q is obtained by a basic formula Q ═ It calculated based on the electric quantity value. Because I is the current flowing through the resistor R during the discharge process; as the discharge progresses, the voltage at the two ends of the resistor R is continuously reduced, so that I is also continuously reduced; therefore, it can be considered that the current flowing through the resistor R is constant in a very small time interval (e.g., 10 microseconds); therefore, the step is repeatedly executed until the voltage at the two ends of the resistor R is zero, namely the capacitor finishes discharging; the formula Q ═ It can be adopted for each minimum time interval, and then the electric quantity calculated in each minimum time interval can be accumulated, and the total electric quantity after accumulation is the required electric quantity Q.
It should be noted that the terms "first", "second" and "third" in the description of the present application are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, features defined as "first", "second", "third" may explicitly or implicitly include one or more of the described features.
102. And determining whether the distance is smaller than a preset threshold value.
The preset threshold is a maximum threshold that the NFC function can normally use, and the preset thresholds of mobile terminals of different models are generally different.
103. And if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state.
When the distance between the first electrode plate and the second electrode plate is smaller than or equal to a preset threshold value, the NFC antenna is matched with the mobile terminal, and PFC of the NFC antenna is enabled. The first electrode plate on the FPC of the NFC antenna can be connected with the second electrode plate on the mobile terminal mainboard through an FPC internal lead of the NFC antenna. At this time, the NFC function of the mobile terminal is in a normal state and can be used normally.
In some embodiments, when it is detected that the NFC function of the mobile terminal is normal, a prompt message may be sent by the mobile terminal to prompt the user that the NFC function is normal. For example, the user may set a corresponding prompting ring in the mobile terminal in advance, and when detecting that the NFC function is normal, the mobile terminal may send the prompting ring to prompt the user. It is understood that the prompting message may also be prompted in other forms, such as one or more of vibration, flashing screen, message or ring, and the like, which are not described in detail herein.
104. And if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
When the distance between the first electrode plate and the second electrode plate is larger than a preset threshold value, the NFC antenna is not matched with the mobile terminal, and PFC of the NFC antenna is disabled. The first electrode plate on the FPC of the NFC antenna cannot be connected with the second electrode plate on the mobile terminal mainboard through the FPC internal lead of the NFC antenna. At this time, the NFC function of the mobile terminal is in an abnormal state and cannot be used normally.
In some embodiments, when detecting that the NFC function of the mobile terminal is abnormal, a prompt message may be sent by the mobile terminal to prompt the user that the NFC function is abnormal. For example, the user may set a corresponding prompting ring in the mobile terminal in advance, and when detecting that the NFC function is abnormal, the mobile terminal may send the prompting ring to prompt the user. It is understood that the prompting message may also be prompted in other forms, such as one or more of vibration, flashing screen, message or ring, and the like, which are not described in detail herein. It should be noted that the prompt information indicating that the NFC function is abnormal is different from the prompt information indicating that the NFC function is normal.
The embodiment adopts the steps of obtaining the distance between a first detection point arranged on the NFC antenna and a second detection point arranged on the mobile terminal main board; determining whether the distance is smaller than a preset threshold value; if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state; and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. According to the scheme, the distance between the first detection point and the second detection point is compared with the preset threshold value, and whether the NFC function is in a normal state or not is determined according to the comparison result; therefore, after the rear cover of the mobile terminal is replaced, whether the NFC antenna in the rear cover is matched with the mobile terminal or not can be accurately judged, and the situation that the NFC function is abnormal after the rear cover of the mobile terminal is replaced is avoided.
The methods described in the above examples are further illustrated in detail by way of example. As shown in fig. 2, a specific flow of the NFC function detection method of this embodiment may be as follows:
201. and acquiring a voltage difference value and an electric quantity value between the first electrode plate and the second electrode plate.
In some embodiments, the first detection point may be disposed on a Flexible Printed Circuit (FPC) of the NFC antenna, and the second detection point may be disposed on a main board of the mobile terminal. The first detecting point may be a first electrode plate, and the second detecting point may be a second electrode plate. In some embodiments, the first electrode plate and the second electrode plate are equal in area.
It should be noted that, after the FPC of the NFC antenna is enabled, the first electrode plate and the second electrode plate are just opposite to each other, and a capacitor may be formed.
Wherein, can predetermine the capacitance value between two electrode boards to be C, the distance is D, the dielectric constant is epsilon, the area of two electrode boards is S, then can be by the capacitance value formula between two electrode boards: and C is equal to epsilon S/D, and the distance D between the two electrode plates is equal to epsilon S/C, wherein epsilon and S are both known quantities.
The capacitance value between the first electrode plate and the second electrode plate is unknown and needs to be obtained through other methods. For example, it may be preset that the voltage difference between the first electrode plate and the second electrode plate is U, the electric quantity value is Q, the capacitance value is C, and the capacitance value is Q/U.
In some embodiments, the capacitor formed by the first electrode plate and the second electrode plate may be charged, and when the charging is completed, the voltage difference U between the first electrode plate and the second electrode plate may be directly obtained.
It should be noted that, during the charging process, the voltage difference between the first electrode plate and the second electrode plate may be changed continuously, and when the voltage difference does not change any more for a period of time, the charging process may be considered to be completed. In some embodiments, the voltage difference between the first electrode plate and the second electrode plate may be continuously detected during the charging process; and when the voltage difference value is detected not to change for the preset time, determining that the charging is finished. The preset time may be set according to actual conditions, for example, 1 second, 2 seconds, or 3 seconds.
In some embodiments, an electric quantity obtaining module may be disposed in the mobile terminal, and the first electrode plate and the second electrode plate are connected through a resistor R. In the implementation, a timer for a preset time period t may be set, and the electric quantity Q may be set to zero. After waiting for a preset time period t, acquiring voltage values at two ends of the resistor R, and if the voltage values at two ends of the resistor R are zero, determining that the electric quantity Q is completely acquired; if the voltage values at the two ends of the resistor R are not zero, the voltage values at the two ends of the resistor R can be acquired after waiting for a preset time period. The preset time period t is a very small time interval, for example, 5 microseconds, 10 microseconds, or the like.
The electric quantity value Q is obtained by a basic formula Q ═ It calculated based on the electric quantity value. Because I is the current flowing through the resistor R during the discharge process; as the discharge progresses, the voltage at the two ends of the resistor R is continuously reduced, so that I is also continuously reduced; therefore, it can be considered that the current flowing through the resistor R is constant in a very small time interval (e.g., 10 microseconds); therefore, the step is repeatedly executed until the voltage at the two ends of the resistor R is zero, namely the capacitor finishes discharging; the formula Q ═ It can be adopted for each minimum time interval, and then the electric quantity calculated in each minimum time interval can be accumulated, and the total electric quantity after accumulation is the required electric quantity Q.
202. And acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value and the electric quantity value.
It is understood that the step 201 can obtain the voltage difference value and the electric quantity value. According to the formula C ═ Q/U, the capacitance value between the first electrode plate and the second electrode plate can be calculated.
203. And acquiring the distance between the first electrode plate and the second electrode plate according to the capacitance value.
It is understood that, the above step 202 may obtain a capacitance value between the first electrode plate and the second electrode plate, and the distance between the first electrode plate and the second electrode plate may be calculated according to the formula D ═ S/C.
204. And determining whether the distance is smaller than a preset threshold value.
The preset threshold is a maximum threshold that the NFC function can normally use, and the preset thresholds of mobile terminals of different models are generally different.
205. And if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state.
When the distance between the first electrode plate and the second electrode plate is smaller than or equal to a preset threshold value, the NFC antenna is matched with the mobile terminal, and PFC of the NFC antenna is enabled. The first electrode plate on the FPC of the NFC antenna can be connected with the second electrode plate on the mobile terminal mainboard through an FPC internal lead of the NFC antenna. At this time, the NFC function of the mobile terminal is in a normal state and can be used normally.
In some embodiments, when it is detected that the NFC function of the mobile terminal is normal, a prompt message may be sent by the mobile terminal to prompt the user that the NFC function is normal. For example, the user may set a corresponding prompting ring in the mobile terminal in advance, and when detecting that the NFC function is normal, the mobile terminal may send the prompting ring to prompt the user. It is understood that the prompting message may also be prompted in other forms, such as one or more of vibration, flashing screen, message or ring, and the like, which are not described in detail herein.
206. And if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
When the distance between the first electrode plate and the second electrode plate is larger than a preset threshold value, the NFC antenna is not matched with the mobile terminal, and PFC of the NFC antenna is disabled. The first electrode plate on the FPC of the NFC antenna cannot be connected with the second electrode plate on the mobile terminal mainboard through the FPC internal lead of the NFC antenna. At this time, the NFC function of the mobile terminal is in an abnormal state and cannot be used normally.
In some embodiments, when detecting that the NFC function of the mobile terminal is abnormal, a prompt message may be sent by the mobile terminal to prompt the user that the NFC function is abnormal. For example, the user may set a corresponding prompting ring in the mobile terminal in advance, and when detecting that the NFC function is abnormal, the mobile terminal may send the prompting ring to prompt the user. It is understood that the prompting message may also be prompted in other forms, such as one or more of vibration, flashing screen, message or ring, and the like, which are not described in detail herein. It should be noted that the prompt information indicating that the NFC function is abnormal is different from the prompt information indicating that the NFC function is normal.
The method comprises the steps of obtaining a voltage difference value and an electric quantity value between a first electrode plate and a second electrode plate; acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value and the electric quantity value; acquiring the distance between the first electrode plate and the second electrode plate according to the capacitance value; determining whether the distance is smaller than a preset threshold value; if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state; and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. According to the scheme, the distance between the first electrode plate and the second electrode plate is compared with a preset threshold value, and whether the NFC function is in a normal state or not is determined according to the comparison result; therefore, after the rear cover of the mobile terminal is replaced, whether the NFC antenna in the rear cover is matched with the mobile terminal or not can be accurately judged, and the situation that the NFC function is abnormal after the rear cover of the mobile terminal is replaced is avoided.
In order to better implement the NFC function detection method provided in the embodiments of the present application, an embodiment of the present application further provides a device based on the NFC function detection method. The meaning of the noun is the same as that in the NFC function detection method, and specific implementation details may refer to the description in the method embodiment.
Referring to fig. 3, fig. 3 is a schematic structural diagram of an NFC functionality detection device according to an embodiment of the present application, where the NFC functionality detection device may include: a distance acquisition unit 301, a distance judgment unit 302, and a state determination unit 303. Wherein:
a distance acquiring unit 301, configured to acquire a distance between a first detection point disposed on the NFC antenna and a second detection point disposed on the mobile terminal main board;
a distance determining unit 302, configured to determine whether the distance is smaller than a preset threshold;
a state determining unit 303, configured to determine that an NFC function of the mobile terminal is in a normal state when the distance is smaller than the preset threshold; and when the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
In some embodiments, the first detection point is a first electrode plate, the second detection point is a second electrode plate, and the area of the first electrode plate is equal to the area of the second electrode plate; referring to fig. 4, the distance obtaining unit 301 may further include:
a capacitance obtaining subunit 3011, configured to obtain a capacitance value between the first electrode plate and the second electrode plate;
a distance obtaining subunit 3012, configured to obtain a distance between the first electrode plate and the second electrode plate according to the capacitance value.
It should be noted that, when the NFC function detection apparatus provided in the foregoing embodiment performs NFC function detection, only the division of the above functional modules is used for illustration, and in practical application, the function distribution may be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules, so as to complete all or part of the functions described above. In addition, the NFC function detection apparatus and the NFC function detection method provided in the foregoing embodiments belong to the same concept, and specific implementation processes thereof are detailed in the method embodiments and are not described herein again.
The NFC function detection apparatus provided in this embodiment acquires, by using the distance acquisition unit 301, a distance between a first detection point disposed on the NFC antenna and a second detection point disposed on the main board of the mobile terminal; determining whether the distance is smaller than a preset threshold value by a distance determination unit 302; determining, by the state determining unit 303, that the NFC function of the mobile terminal is in a normal state when the distance is smaller than the preset threshold value; and when the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. According to the scheme, the distance between the first detection point and the second detection point is compared with the preset threshold value, and whether the NFC function is in a normal state or not is determined according to the comparison result; therefore, after the rear cover of the mobile terminal is replaced, whether the NFC antenna in the rear cover is matched with the mobile terminal or not can be accurately judged, and the situation that the NFC function is abnormal after the rear cover of the mobile terminal is replaced is avoided.
The application also provides a mobile terminal, which comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor executes the program to implement the NFC function detection method provided by the embodiment of the method.
In another embodiment of the present application, a mobile terminal is further provided, where the terminal may be a terminal such as a smart phone or a tablet computer. As shown in fig. 6, the mobile terminal 400 may include a processor 401 and a memory 402, wherein the processor 401 and the memory 402 are electrically connected.
The processor 401 is a control center of the mobile terminal 400, connects various parts of the entire mobile terminal using various interfaces and lines, and performs various functions of the mobile terminal and processes data by running or loading an application program stored in the memory 402 and calling data stored in the memory 402, thereby integrally monitoring the mobile terminal.
In this embodiment, the processor 401 in the mobile terminal 400 loads instructions corresponding to processes of one or more application programs into the memory 402 according to the following steps, and the processor 401 runs the application programs stored in the memory 402, thereby implementing various functions:
acquiring a distance between a first detection point arranged on the NFC antenna and a second detection point arranged on a mobile terminal main board;
determining whether the distance is smaller than a preset threshold value;
if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state;
and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state.
In some embodiments, the first detection point is a first electrode plate, the second detection point is a second electrode plate, and the area of the first electrode plate is equal to the area of the second electrode plate.
In some embodiments, in acquiring the distance between the first detection point disposed on the NFC antenna and the second detection point disposed on the main board of the mobile terminal, the processor 401 may be configured to perform:
acquiring a capacitance value between the first electrode plate and the second electrode plate;
and acquiring the distance between the first electrode plate and the second electrode plate according to the capacitance value.
In some embodiments, in obtaining the capacitance value between the first electrode plate and the second electrode plate, the processor 401 may be configured to:
charging the first electrode plate and the second electrode plate;
when charging is completed, acquiring a voltage difference value between the first electrode plate and the second electrode plate;
and acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value.
In some embodiments, after the charging the first electrode plate and the second electrode plate, the processor 401 may be configured to perform:
detecting a voltage difference value between the first electrode plate and the second electrode plate in a charging process;
and when the voltage difference value is detected not to change for the preset time, determining that the charging is finished.
In some embodiments, when obtaining the capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value, the processor 401 may be configured to:
acquiring an electric quantity value between the first electrode plate and the second electrode plate;
and acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value and the electric quantity value.
As can be seen from the above, the mobile terminal 400 provided in this embodiment obtains the distance between the first detection point disposed on the NFC antenna and the second detection point disposed on the main board of the mobile terminal; determining whether the distance is smaller than a preset threshold value; if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state; and if the distance is greater than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state. According to the scheme, the distance between the first detection point and the second detection point is compared with the preset threshold value, and whether the NFC function is in a normal state or not is determined according to the comparison result; therefore, after the rear cover of the mobile terminal is replaced, whether the NFC antenna in the rear cover is matched with the mobile terminal or not can be accurately judged, and the situation that the NFC function is abnormal after the rear cover of the mobile terminal is replaced is avoided.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a mobile terminal according to an embodiment of the present application. The mobile terminal 500 may include Radio Frequency (RF) circuitry 501, memory 502 including one or more computer-readable storage media, input unit 503, display unit 504, sensor 504, audio circuitry 506, Wireless Fidelity (WiFi) module 507, processor 508 including one or more processing cores, and power supply 509. Those skilled in the art will appreciate that the mobile terminal architecture shown in fig. 6 is not intended to be limiting of mobile terminals and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The rf circuit 501 may be used for receiving and transmitting information, or receiving and transmitting signals during a call, and in particular, receives downlink information of a base station and then sends the received downlink information to one or more processors 508 for processing; in addition, data relating to uplink is transmitted to the base station. In general, radio frequency circuit 501 includes, but is not limited to, an antenna, at least one Amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, the radio frequency circuit 501 may also communicate with a network and other devices through wireless communication. The wireless communication may use any communication standard or protocol, including but not limited to Global System for Mobile communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), email, Short Message Service (SMS), and the like.
The memory 502 may be used to store applications and data. Memory 502 stores applications containing executable code. The application programs may constitute various functional modules. The processor 508 executes various functional applications and data processing by executing application programs stored in the memory 502. The memory 502 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the mobile terminal, and the like. Further, the memory 502 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 502 may also include a memory controller to provide the processor 508 and the input unit 503 access to the memory 502.
The input unit 503 may be used to receive input numbers, character information, or user characteristic information (such as a fingerprint), and generate a keyboard, mouse, joystick, optical, or trackball signal input related to user setting and function control. In particular, in one particular embodiment, the input unit 503 may include a touch-sensitive surface as well as other input devices. The touch-sensitive surface, also referred to as a touch display screen or a touch pad, may collect touch operations by a user (e.g., operations by a user on or near the touch-sensitive surface using a finger, a stylus, or any other suitable object or attachment) thereon or nearby, and drive the corresponding connection device according to a predetermined program. Alternatively, the touch sensitive surface may comprise two parts, a touch detection means and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 508, and can receive and execute commands sent by the processor 508.
The display unit 504 may be used to display information input by or provided to the user and various graphical user interfaces of the mobile terminal, which may be made up of graphics, text, icons, video, and any combination thereof. The display unit 504 may include a display panel. Alternatively, the Display panel may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. Further, the touch-sensitive surface may overlay the display panel, and when a touch operation is detected on or near the touch-sensitive surface, the touch operation is transmitted to the processor 508 to determine the type of touch event, and then the processor 508 provides a corresponding visual output on the display panel according to the type of touch event. Although in FIG. 6 the touch-sensitive surface and the display panel are two separate components to implement input and output functions, in some embodiments the touch-sensitive surface may be integrated with the display panel to implement input and output functions.
The mobile terminal may also include at least one sensor 505, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that may adjust the brightness of the display panel according to the brightness of ambient light, and a proximity sensor that may turn off the display panel and/or the backlight when the mobile terminal is moved to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when the mobile phone is stationary, and can be used for applications of recognizing the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured on the mobile terminal, further description is omitted here.
The audio circuit 506 may provide an audio interface between the user and the mobile terminal through a speaker, microphone. The audio circuit 506 can convert the received audio data into an electrical signal, transmit the electrical signal to a speaker, and convert the electrical signal into a sound signal to output; on the other hand, the microphone converts the collected sound signal into an electrical signal, which is received by the audio circuit 506 and converted into audio data, which is then processed by the audio data output processor 508 and then sent to, for example, another mobile terminal via the rf circuit 501, or the audio data is output to the memory 502 for further processing. The audio circuit 506 may also include an earbud jack to provide communication of a peripheral headset with the mobile terminal.
Wireless fidelity (WiFi) belongs to short-distance wireless transmission technology, and the mobile terminal can help the user to receive and send e-mail, browse web pages, access streaming media and the like through the wireless fidelity module 507, and provides wireless broadband internet access for the user. Although fig. 6 shows the wireless fidelity module 507, it is understood that it does not belong to the essential constitution of the mobile terminal, and may be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 508 is a control center of the mobile terminal, connects various parts of the entire mobile terminal using various interfaces and lines, and performs various functions of the mobile terminal and processes data by running or executing an application program stored in the memory 502 and calling data stored in the memory 502, thereby integrally monitoring the mobile terminal. Optionally, processor 508 may include one or more processing cores; preferably, the processor 508 may integrate an application processor, which primarily handles operating systems, user interfaces, application programs, etc., and a modem processor, which primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 508.
The mobile terminal also includes a power supply 509 (such as a battery) for powering the various components. Preferably, the power source may be logically connected to the processor 508 through a power management system, so that the power management system may manage charging, discharging, and power consumption management functions. The power supply 509 may also include any component such as one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
Although not shown in fig. 6, the mobile terminal may further include a camera, a bluetooth module, and the like, which are not described in detail herein.
In specific implementation, the above modules may be implemented as independent entities, or may be combined arbitrarily to be implemented as the same or several entities, and specific implementation of the above modules may refer to the foregoing method embodiments, which are not described herein again.
It should be noted that, as one of ordinary skill in the art would understand, all or part of the steps in the various methods of the foregoing embodiments may be implemented by relevant hardware instructed by a program, where the program may be stored in a computer-readable storage medium, such as a memory of a terminal, and executed by at least one processor in the terminal, and during the execution, the flow of the embodiments of the NFC functionality detection method may be included. Among others, the storage medium may include: read Only Memory (ROM), Random Access Memory (RAM), magnetic or optical disks, and the like.
The NFC function detection method, the NFC function detection device, the storage medium, and the mobile terminal provided in the embodiments of the present application are described in detail above, and each functional module may be integrated in one processing chip, or each module may exist alone physically, or two or more modules are integrated in one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The principle and the implementation of the present application are explained herein by applying specific examples, and the above description of the embodiments is only used to help understand the method and the core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (6)

1. An NFC function detection method, comprising:
when the rear cover of the mobile terminal is replaced, acquiring the distance between a first detection point arranged on the NFC antenna and a second detection point arranged on a main board of the mobile terminal;
determining whether the distance is smaller than a preset threshold value;
if the distance is smaller than or equal to the preset threshold value, determining that the NFC function of the mobile terminal is in a normal state;
if the distance is larger than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state;
the first detection point is a first electrode plate, the second detection point is a second electrode plate, and the distance between the first detection point arranged on the NFC antenna and the second detection point arranged on the mobile terminal main board is acquired, and the method comprises the following steps:
acquiring a capacitance value between the first electrode plate and the second electrode plate;
acquiring the distance between the first electrode plate and the second electrode plate according to the capacitance value;
the obtaining a capacitance value between the first electrode plate and the second electrode plate includes:
charging the first electrode plate and the second electrode plate;
when charging is completed, acquiring a voltage difference value between the first electrode plate and the second electrode plate;
acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value;
after the charging the first electrode plate and the second electrode plate, further comprising:
detecting a voltage difference value between the first electrode plate and the second electrode plate in a charging process;
and when the voltage difference value is detected not to change for the preset time, determining that the charging is finished.
2. The NFC function detection method according to claim 1, wherein an area of the first electrode pad and an area of the second electrode pad are equal.
3. The NFC function detection method according to claim 2, wherein the obtaining of the capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value includes:
acquiring an electric quantity value between the first electrode plate and the second electrode plate;
and acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value and the electric quantity value.
4. An NFC function detection apparatus, comprising:
the distance acquisition unit is used for acquiring the distance between a first detection point arranged on the NFC antenna and a second detection point arranged on a main board of the mobile terminal after the mobile terminal is replaced by a rear cover, wherein the first detection point is a first electrode plate, and the second detection point is a second electrode plate;
the distance judging unit is used for determining whether the distance is smaller than a preset threshold value or not;
a state determining unit, configured to determine that an NFC function of the mobile terminal is in a normal state when the distance is smaller than the preset threshold value; when the distance is larger than the preset threshold value, determining that the NFC function of the mobile terminal is in an abnormal state;
the distance acquisition unit includes:
a capacitance obtaining subunit, configured to obtain a capacitance value between the first electrode plate and the second electrode plate;
a distance obtaining subunit, configured to obtain a distance between the first electrode plate and the second electrode plate according to the capacitance value;
the capacitance obtaining subunit is configured to charge the first electrode plate and the second electrode plate; when charging is completed, acquiring a voltage difference value between the first electrode plate and the second electrode plate; acquiring a capacitance value between the first electrode plate and the second electrode plate according to the voltage difference value; detecting a voltage difference value between the first electrode plate and the second electrode plate in a charging process; and when the voltage difference value is detected not to change for the preset time, determining that the charging is finished.
5. A storage medium for storing a plurality of instructions adapted to be loaded by a processor and to perform the steps of the method according to any of claims 1-3.
6. A mobile terminal, characterized in that it comprises a memory, a processor and a computer program stored on the memory and executable on the processor, which when executing the program performs the steps of the method according to any of claims 1-3.
CN201811574404.6A 2018-12-21 2018-12-21 NFC function detection method and device, storage medium and mobile terminal Active CN109561415B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811574404.6A CN109561415B (en) 2018-12-21 2018-12-21 NFC function detection method and device, storage medium and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811574404.6A CN109561415B (en) 2018-12-21 2018-12-21 NFC function detection method and device, storage medium and mobile terminal

Publications (2)

Publication Number Publication Date
CN109561415A CN109561415A (en) 2019-04-02
CN109561415B true CN109561415B (en) 2022-03-01

Family

ID=65870717

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811574404.6A Active CN109561415B (en) 2018-12-21 2018-12-21 NFC function detection method and device, storage medium and mobile terminal

Country Status (1)

Country Link
CN (1) CN109561415B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN202406172U (en) * 2011-10-13 2012-08-29 惠州Tcl移动通信有限公司 Apparatus used for testing mobile phone NFC function
CN104931847A (en) * 2015-07-09 2015-09-23 广东欧珀移动通信有限公司 Terminal of determining whether NFC antenna to be in poor contact state and method thereof
CN106385474A (en) * 2016-10-31 2017-02-08 努比亚技术有限公司 Terminal antenna switching device and terminal antenna switching method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8929809B2 (en) * 2011-03-22 2015-01-06 Radeum, Inc. Techniques for wireless communication of proximity based content

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN202406172U (en) * 2011-10-13 2012-08-29 惠州Tcl移动通信有限公司 Apparatus used for testing mobile phone NFC function
CN104931847A (en) * 2015-07-09 2015-09-23 广东欧珀移动通信有限公司 Terminal of determining whether NFC antenna to be in poor contact state and method thereof
CN106385474A (en) * 2016-10-31 2017-02-08 努比亚技术有限公司 Terminal antenna switching device and terminal antenna switching method

Also Published As

Publication number Publication date
CN109561415A (en) 2019-04-02

Similar Documents

Publication Publication Date Title
CN106786962B (en) Charging control method and device and terminal
CN108900231B (en) Dynamic antenna adjustment method and related product
CN107450029B (en) Battery state checking method and device, computer equipment and computer readable storage medium
EP3570404B1 (en) Power supply control method and apparatus, storage medium, and electronic device
CN110768382A (en) Wireless charging method and device, storage medium and electronic equipment
CN109688611B (en) Frequency band parameter configuration method, device, terminal and storage medium
CN111443803A (en) Mode switching method, device, storage medium and mobile terminal
CN108388400B (en) Operation processing method and mobile terminal
CN110851014A (en) Touch identification method and device, storage medium and terminal equipment
CN112312542B (en) Ephemeris information collection method, device, storage medium and mobile terminal
CN109561415B (en) NFC function detection method and device, storage medium and mobile terminal
CN112542867B (en) Mobile terminal power supply control method and device, terminal equipment and storage medium
CN112486350B (en) Detection method and device for touch screen of mobile terminal, storage medium and mobile terminal
CN112286849A (en) Wireless charging base data switching method and system, storage medium and terminal equipment
CN111603154A (en) Heart rhythm detection method and device, storage medium and mobile terminal
CN111988059B (en) Wireless data transmission method, device, storage medium and mobile terminal
CN109617660B (en) Method and device for setting carrier aggregation frequency band, storage medium and mobile terminal
CN105278967B (en) System updating method, device and system of mobile terminal
CN117387655B (en) Step counting method, step counting device, terminal and storage medium
CN112256610B (en) Connection control method, system, storage medium and mobile terminal
CN111984107B (en) Method and device for processing power supply abnormity of terminal equipment
CN111343325B (en) Port detection method and device, mobile terminal and storage medium
CN111651313B (en) Conversion method and system of identification card, storage medium and terminal equipment
CN110891304B (en) gPS power consumption control method for mobile terminal
CN110572516B (en) Call control method, device, storage medium and terminal equipment

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
TR01 Transfer of patent right

Effective date of registration: 20230406

Address after: 518000 Room 201, building A, No. 1, Qian Wan Road, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen, Guangdong (Shenzhen Qianhai business secretary Co., Ltd.)

Patentee after: Shenzhen Huaxi Investment Co.,Ltd.

Address before: 516006 Zhongkai hi tech Zone, Huizhou, Guangdong, 86 Chang seven Road West

Patentee before: HUIZHOU TCL MOBILE COMMUNICATION Co.,Ltd.

TR01 Transfer of patent right