NFC card swiping control method and device, NFC card reading control method and device and electronic equipment
By receiving the polling signal of the NFC radio frequency device and judging the device type identification, the problem of error pop-up on the NFC card page without interaction is solved, achieving the effect of reducing interference.
Patent Information
- Application Number
- CN202411541135.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-02-28
AI Technical Summary
In scenarios where data interaction with NFC radio frequency devices is not required, the error pop-up of the NFC card page interferes with the user's use of electronic devices.
By receiving the anti-fault-touch data frame in the polling signal sent by the NFC radio frequency device, it is determined whether the device type identification matches the device type identification corresponding to the activated card type in the electronic device. If it does not match, the NFC card interface is prohibited from popping up.
It effectively avoids the error pop-up of the NFC card interface, reduces the pop-up of NFC card pages of electronic devices without interaction, and reduces interference to user use.
Smart Images

Figure CN119543995A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of communication technology, and specifically relates to an NFC card swiping control method, an NFC card reading control method and a device thereof, and an electronic device. Background Art
[0002] With the development of smart life, Near Field Communication (NFC) technology has become one of the important technical configurations of electronic devices, and its working modes may include read-write mode and card simulation mode. In card simulation mode, electronic devices can be used as different types of "NFC cards". At this time, once the electronic device is close to the NFC radio frequency device, it may be mobilized by the radio frequency field signal of the NFC radio frequency device to display the NFC card page. However, in some scenarios where data interaction with the NFC radio frequency device is not required, the pop-up of the NFC card page will interfere with the user's use of the electronic device. Summary of the invention
[0003] The purpose of the embodiments of the present application is to provide an NFC card swiping control method, an NFC card reading control method and its device, and an electronic device, which can effectively avoid the NFC card interface from being accidentally popped up, and avoid the pop-up of the NFC card page disturbing the user when the electronic device does not need to interact with the NFC radio frequency device for data.
[0004] In a first aspect, an embodiment of the present application provides an NFC card swiping control method, which is executed by an electronic device, and the method includes:
[0005] Receive a polling signal sent by a near field communication (NFC) radio frequency device, where the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards;
[0006] If the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is prohibited from popping up.
[0007] In a second aspect, an embodiment of the present application provides an NFC card swiping control method, which is executed by an NFC radio frequency device, and the method includes:
[0008] Sending a polling signal to the electronic device, wherein the polling signal includes an anti-mistouch data frame;
[0009] The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
[0010] In a third aspect, an embodiment of the present application provides an NFC card swiping control device, comprising:
[0011] A receiving module, used to receive a polling signal sent by a near field communication NFC radio frequency device, wherein the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards;
[0012] The processing module is used to prohibit the pop-up of the NFC card interface when the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device.
[0013] In a fourth aspect, an embodiment of the present application provides an NFC card swiping control device, including:
[0014] A sending module, used for sending a polling signal to an electronic device, wherein the polling signal includes an anti-mistouch data frame;
[0015] The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
[0016] In a fifth aspect, an embodiment of the present application provides an electronic device, comprising a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps of the method described in the first aspect or the second aspect are implemented.
[0017] In a sixth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the method described in the first aspect or the second aspect are implemented.
[0018] In the seventh aspect, an embodiment of the present application provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect or the second aspect.
[0019] In an eighth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect or the second aspect.
[0020] In an embodiment of the present application, the electronic device can receive a polling signal sent by a near field communication NFC radio frequency device, and determine whether the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device based on the device type identifier of the anti-mistouch data frame of the polling signal. If there is no match, it means that the card type that can interact with the NFC radio frequency device for data is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when using the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 It is a flowchart of an NFC card swiping control method provided by some embodiments of the present application;
[0022] Figure 2 is a schematic diagram of a polling signal in an NFC card swiping control method provided in some embodiments of the present application;
[0023] Figure 3 is a schematic diagram of an NFC card interface in an NFC card swiping control method provided in some embodiments of the present application;
[0024] Figure 4 It is a flowchart of a specific scenario embodiment of the NFC card swiping control method provided by some embodiments of the present application;
[0025] Figure 5 is a flowchart of an NFC card reading control method provided by some embodiments of the present application;
[0026] Figure 6 It is a flowchart of a specific scenario embodiment of the NFC card reading control method provided by some embodiments of the present application;
[0027] Figure 7 is a schematic diagram of the structure of an NFC card swiping control device provided in some embodiments of the present application;
[0028] Figure 8 is a schematic diagram of the structure of an NFC card reading control device provided in some embodiments of the present application;
[0029] Fig. 9 is a schematic diagram of the structure of an electronic device provided by some embodiments of the present application;
[0030] Fig.10 It is a schematic diagram of the hardware structure of an electronic device provided in some embodiments of the present application. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0032] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the terms used in this way are interchangeable where appropriate, so that the embodiments of the present application can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0033] NFC: Near Field Communication is a short-range high-frequency wireless communication technology that allows contactless point-to-point data transmission and exchange between electronic devices. NFC technology is an integration of contactless radio frequency identification and interconnection technology, and can be used for mobile payment, electronic ticketing, access control, mobile identity recognition, anti-counterfeiting and other applications through mobile terminals.
[0034] NFC radio frequency device: A card reader that supports NFC. NFC radio frequency devices can read the information of NFC cards. Some NFC radio frequency devices (such as UnionPay POS machines, public transportation POS machines, access control POS machines, security gate machines, etc.) can also perform corresponding operations based on the read information and according to preset rules, such as opening doors, deducting money, etc.
[0035] POS: Point of Sale, which means sales terminal, can refer to an electronic payment system that allows users to use cards (such as bank cards, transportation cards, access cards, etc.) to swipe cards. A POS machine is a device that can read card information and authorize transactions with the corresponding system through a communication network.
[0036] Card emulation mode: A working mode of NFC technology, in which an electronic device can simulate an NFC card (such as a transportation card, access card or bank card, etc.). In card emulation mode, the electronic device contains an NFC controller and an NFC antenna. When the electronic device is close to the NFC radio device, it sends and receives radio frequency signals through the antenna. These signals contain the NFC card information simulated by the electronic device, such as card number, balance, etc.
[0037] It should be noted that the NFC card swiping method provided in the embodiments of the present application can be executed by electronic devices such as mobile phones, tablet computers, laptops, PDAs, and vehicle-mounted electronic devices. In some embodiments of the present application, the NFC card swiping method provided in the embodiments of the present application is described by taking the electronic device as the execution subject to execute the NFC card swiping method as an example.
[0038] The NFC card swiping control method provided in the embodiment of the present application can be applied to the scenario where an electronic device mistakenly touches an NFC radio frequency device corresponding to a card type that is not activated by the electronic device. Among them, one specific application scenario is that when a certain card type is not activated by the electronic device, the electronic device mistakenly touches the NFC radio frequency device corresponding to the card type, for example, the electronic device has not activated a transportation card, but mistakenly touches a public transportation POS machine, or the electronic device has not activated an access control card, but mistakenly touches an access control POS machine, or the electronic device has not activated a bank card, but mistakenly touches a UnionPay POS machine. Another specific application scenario is that the electronic device mistakenly touches other electronic devices that support the NFC function, for example, the electronic device mistakenly touches the NFC sensing area of a mobile phone or laptop. It can be understood that the above-mentioned specific application scenarios are only examples, and the application scenarios of the NFC card swiping control method of the embodiment of the present application may include but are not limited to the above-mentioned specific application scenarios.
[0039] The NFC card swiping control method provided by the embodiment of the present application is described in detail below through specific embodiments and application scenarios in conjunction with the accompanying drawings.
[0040] Figure 1 : is a flow chart of an NFC card swiping control method provided in an embodiment of the present application. The NFC card swiping control method can be applied to electronic devices, and the NFC card swiping control method may include:
[0041] Step 101, receiving a polling signal sent by a near field communication NFC radio frequency device, wherein the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards.
[0042] In step 101, the NFC radio frequency device can emit a radio frequency field, in which a polling signal is modulated, and these polling signals can be used to detect whether an NFC card device is approaching. When the distance between the electronic device and the NFC radio frequency device is less than or equal to the preset distance, the electronic device can receive the polling signal in the radio frequency field emitted by the NFC radio frequency device. It can be understood that the preset distance can be set according to the radiation range of the radio frequency field of the NFC radio frequency device, which is not specifically limited here.
[0043] like Figure 2As shown, the polling signal 200 may include an anti-mistaken touch data frame 201, and the anti-mistaken touch data frame 201 may include a device type identifier, and different device type identifiers indicate the function of data interaction with different types of cards. Among them, the anti-mistaken touch data frame may also include information such as a data frame header, a total number of bytes, a data frame version, a device identity identifier, a default value, and a cyclic redundancy check code. The protocol format of the anti-mistaken touch data frame may be as shown in Table 1:
[0044] Table 1
[0045]
[0046] The anti-mistaken-touch data frame 201 can cover the device types of all NFC radio frequency devices. The device type identifier represents different types of NFC radio frequency devices through different values. When each type of NFC radio frequency device leaves the factory, its polling signal needs to carry an anti-mistaken-touch data frame with a device type identifier corresponding to the value of the device type.
[0047] For example, for a public transportation POS terminal, the anti-mistaken touch data frame of its polling signal may include a device type identifier with a value of "0001". For another example, for a laptop computer, the anti-mistaken touch data frame of its polling signal may include a device type identifier with a value of "02FF".
[0048] Step 102: If the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, prohibiting the NFC card interface from popping up.
[0049] In step 102, after receiving a data frame in the polling signal, the electronic device can first determine whether it is an anti-mistaken touch data frame. If it is not an anti-mistaken touch data frame, it can continue to receive data frames in the polling signal until the anti-mistaken touch data frame is received. When the anti-mistaken touch data frame is received, the anti-mistaken touch data frame can be parsed to obtain the corresponding device type identification. For example, if the device type identification is "0001", it can be considered that the NFC radio frequency device is a public transportation POS machine. If the device type identification is "0002", it can be considered that the NFC radio frequency device is an access control POS machine. If the device type identification is "0003", it can be considered that the NFC radio frequency device is a UnionPay POS machine. If the device type identification is "02FF", it can be considered that the NFC radio frequency device is a laptop computer...
[0050] The device type identifier can be compared with the device type identifier corresponding to the card type that has been activated in the electronic device. It can be understood that the device type identifier corresponding to the activated card type is usually stored in the electronic device, that is, when the electronic device can simulate a certain NFC card, the device type identifier of the NFC radio frequency device that interacts with the NFC card can be stored by the electronic device. For example, if the electronic device has activated a transportation card, "00 01" is the device type identifier corresponding to the card type that has been activated in the electronic device. If the electronic device has activated an access card, "00 02" is the device type identifier corresponding to the card type that has been activated in the electronic device. If the electronic device has activated a bank card, "00 03" is the device type identifier corresponding to the card type that has been activated in the electronic device.
[0051] If the device type identifier is any of the device type identifiers corresponding to the card type activated in the electronic device, it can be considered a match; if the device type identifier corresponding to the card type activated in the electronic device does not include the device type identifier, it can be considered a mismatch.
[0052] When the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface may be prohibited from popping up.
[0053] For example, in an application scenario, the electronic device has activated access cards and bank cards, but has not activated other cards including transportation cards. At this time, the device type identifiers corresponding to the card types that have been activated by the electronic device are "00 02" and "0003". If the electronic device accidentally touches a public transportation POS machine, the device type identifier in the anti-mistouch data frame of the polling signal received is "00 01", which does not match the device type identifiers "00 02" and "00 03" corresponding to the card types that have been activated by the electronic device. At this time, the electronic device is prohibited from popping up the NFC card interface. If the electronic device accidentally touches the NFC sensing area of a laptop computer, the device type identifier in the anti-mistouch data frame of the polling signal received is "02FF", which does not match the device type identifiers "00 02" and "00 03" corresponding to the card types that have been activated by the electronic device. At this time, the electronic device is also prohibited from popping up the NFC card interface.
[0054] In an embodiment of the present application, the electronic device can receive a polling signal sent by a near field communication NFC radio frequency device, and determine whether the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device based on the device type identifier of the anti-mistouch data frame of the polling signal. If there is no match, it means that the card type that can interact with the NFC radio frequency device for data is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when using the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0055] In some embodiments, after receiving the polling signal sent by the near field communication NFC radio frequency device, the NFC card swiping control method may further include:
[0056] When the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is displayed.
[0057] In this embodiment, if the device type identifier matches the device type identifier corresponding to the card type that has been enabled in the electronic device, it can be considered that the user wants to use the electronic device as an NFC card to be read by the NFC radio frequency device, so the card emulation mode of the electronic device can be turned on, such as Figure 3 As shown, the electronic device can now display the NFC card interface 301. It is understandable that before the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device, the card emulation mode of the electronic device can remain closed.
[0058] For example, in an application scenario, the electronic device has access control cards and bank cards enabled, but other cards including transportation cards are not enabled. At this time, the device type identifiers corresponding to the card types enabled by the electronic device are "00 02" and "0003". If the electronic device contacts the access control POS machine, the device type identifier in the anti-mistaken touch data frame of the received polling signal is "00 02", which matches the device type identifier "00 02" corresponding to the card type enabled by the electronic device. At this time, the card simulation mode of the electronic device can be turned on, the electronic device is simulated as an access control card, and the NFC card interface is displayed. If the electronic device contacts the UnionPay POS machine, the device type identifier in the anti-mistaken touch data frame of the received polling signal is "00 03", which matches the device type identifier "00 03" corresponding to the card type enabled by the electronic device. At this time, the electronic device can also turn on the card simulation mode of the electronic device, simulate the electronic device as a bank card, and display the NFC card interface.
[0059] In this way, the NFC card interface will only be displayed when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the risk of interference to the user caused by the pop-up NFC card interface of the electronic device due to accidental touching of the NFC radio frequency device.
[0060] In some embodiments, the polling signal may further include at least one protocol communication request data frame; after displaying the NFC card interface, the NFC card swiping control method may further include:
[0061] When any one of the at least one protocol communication request data frames is received, a feedback signal is sent to the NFC radio frequency device, where the feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
[0062] In this embodiment, if Figure 2 As shown, the polling signal 200 may also include at least one protocol communication request data frame 202. Take the case where the number of at least one protocol communication request data frame 202 is two, including a first protocol communication request data frame 2021 and a second protocol communication request data frame 2022 as an example. The communication protocols corresponding to the first protocol communication request data frame 2021 and the second protocol communication request data frame 2022 are different. For example, the first protocol communication request data frame 2021 may be a data frame requesting communication in the ISO14443-3-A protocol, and the second protocol communication request data frame 2022 may be a data frame requesting communication in the ISO14443-3-B protocol. It can be understood that the structure and composition of the anti-mistouch data frame 201 and at least one protocol communication request data frame 202 in the polling signal 200 can be set according to actual needs, and are not specifically limited here.
[0063] The electronic device can receive any protocol communication request data frame in at least one protocol communication request data frame. For example, if the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device, it can be considered that the user wants to use the electronic device as an NFC card to be read by the NFC radio frequency device, so the card simulation mode of the electronic device can be turned on to display the NFC card interface 301. And in the card simulation mode, the electronic device can also receive the protocol communication request data frame corresponding to the communication protocol supported by the electronic device from at least one protocol communication request data frame according to the communication protocol configured by itself. It can be understood that if the electronic device is configured with multiple communication protocols corresponding to at least one protocol communication request data frame, the protocol communication request data frame first received by the electronic device can be used as the basis.
[0064] The electronic device can generate a feedback signal according to the received protocol communication request data frame and send the feedback signal to the NFC radio frequency device. The feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
[0065] For example, the first protocol communication request data frame 2021 can be a data frame REQA requesting communication in the ISO14443-3-A protocol, and the second protocol communication request data frame 2022 can be a data frame REQB requesting communication in the ISO14443-3-B protocol. If the electronic device receives REQA, it can send a feedback signal ATQA to the NFC radio frequency device. If the electronic device receives REQB, it sends a feedback signal ATQB to the NFC radio frequency device. After receiving the feedback signal, the NFC radio frequency device can perform data interaction processing with the card corresponding to the device type identifier in the electronic device, that is, the NFC radio frequency device can complete subsequent instruction interaction with the electronic device when receiving the feedback signal.
[0066] For example, the NFC radio frequency device can send relevant instructions to the electronic device according to its own communication protocol logic, and the relevant instructions are used to instruct the reading of card information or the change of card information. The NFC radio frequency device can also receive the card information fed back by the electronic device in response to these instructions, as well as the execution of these instructions, until the card reading process is completed. For example, after receiving the feedback signal from the electronic device, the public transportation POS machine can send an instruction to read the transportation card ID and balance to the electronic device, and the electronic device can respond to the instruction to feedback the ID, balance and other data of the activated transportation card to the public transportation POS machine. After deducting part of the fee based on the itinerary, the public transportation POS machine sends an instruction to change the balance to the electronic device, and the electronic device can respond to the instruction to change the balance of the transportation card to the balance after the deduction.
[0067] In an embodiment of the present application, when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device, the NFC card interface can be displayed and a feedback signal can be sent to the NFC radio frequency device, so that the NFC radio frequency device can execute data interaction processing with the card corresponding to the device type identifier in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to accidental touching of the NFC radio frequency device, thereby reducing the risk of wasting resources.
[0068] In some embodiments, the device type identifier includes a primary device category identifier and a secondary device category identifier; wherein the primary device category identifier is used to indicate that the NFC radio frequency device is a card swiping device or a card reading device, the card swiping device is a device corresponding to the card swiping function, and different secondary device category identifiers indicate the function of interacting with different types of cards for data; the card reading device is a device that only reads data.
[0069] In this embodiment, the device type identifier may include a primary device category identifier and a secondary device category identifier. The primary device category identifier may classify the NFC radio frequency device into a card swiping device or a card reading device, wherein the card swiping device is a device corresponding to the card swiping function, and the card reading device is a device that only reads data.
[0070] The secondary device category identifier can indicate a specific card swiping function or a specific device type. For example, if the NFC radio frequency device is a card swiping device, different secondary device category identifiers indicate the function of data interaction with different types of cards. If the NFC radio frequency device is a card reader device, each secondary device category identifier is used to indicate the device type of the card reader device, such as a laptop, mobile phone, or security gate.
[0071] Taking the device category identifier "00 01" as an example, "00" can be the first-level device category identifier, and "01" can be the second-level device category identifier, where "00" is used to indicate a card swiping device, and "01" is used to indicate a transportation card POS machine. Taking the device category identifier "01FF" as an example, "FF" can be the first-level device category identifier, and "01" can be the second-level device category identifier, where "FF" is used to indicate a card reader device, and "01" is used for a security gate machine.
[0072] It is understandable that the electronic device only needs to display the NFC card interface when the card needs to be swiped. Therefore, it is possible to first determine whether the electronic device has the need to interact with the NFC radio frequency device and whether the NFC card interface needs to be displayed based on the first-level device category identification. In this way, the determination process of whether to prohibit the pop-up of the NFC card interface is further simplified, saving computing resources.
[0073] In some embodiments, after receiving the polling signal sent by the near field communication NFC radio frequency device, the NFC card swiping control method may further include:
[0074] When the primary device category identifier indicates that the NFC radio frequency device is a card reader device, the NFC card interface is prohibited from popping up.
[0075] In this embodiment, the first-level device category identifier indicates that the NFC radio frequency device is not a card swiping device, but a card reading device. For example, when the electronic device touches the NFC sensing area of the laptop computer, the device category identifier is "FF", indicating that it is a card reading device. That is, the NFC radio frequency device only reads data at this time, and the electronic device does not need to swipe the card as an NFC card. The electronic device can directly prohibit the pop-up of the NFC card interface.
[0076] In this way, when the first-level device category identifier indicates that the NFC radio frequency device is a card reader device, it can be directly determined that the electronic device does not need to interact with the NFC radio frequency device for data. At this time, the electronic device can directly prohibit the pop-up of the NFC card interface, saving computing resources.
[0077] In some embodiments, when the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, prohibiting the NFC card interface from popping up includes:
[0078] When the primary device category identifier indicates that the NFC radio frequency device is a card swiping device, the secondary device category identifier is matched with the device type identifier corresponding to the card type activated in the electronic device;
[0079] When the secondary device category identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is prohibited from popping up.
[0080] In this embodiment, when the primary device category identifier indicates that the NFC radio frequency device is a card swiping device, for example, the electronic device touches the public transportation POS machine, the primary device category identifier is "00" to indicate the device corresponding to the card swiping function, that is, it can be considered that the electronic device may have the need to interact with the NFC radio frequency device for data. The secondary device category identifier can be matched with the device type identifier corresponding to the card type that has been activated in the electronic device.
[0081] When the secondary device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface may be prohibited from popping up.
[0082] For example, in an application scenario, the electronic device has activated access cards and bank cards, but has not activated other cards including transportation cards. At this time, the device type identifiers corresponding to the card types that have been activated by the electronic device are "00 02" and "0003". If the electronic device accidentally touches a public transportation POS machine, the secondary device type identifier in the anti-mistouch data frame of the received polling signal is "01", and the secondary device type identifiers in the device type identifier corresponding to the card types that have been activated by the electronic device are "02" and "03", respectively, which do not match the secondary device type identifier "01". At this time, the electronic device is prohibited from popping up the NFC card interface.
[0083] In this way, it is possible to first determine whether the electronic device has a need to interact with the NFC radio frequency device based on the first-level device category identifier. When the first-level device category identifier indicates that the NFC radio frequency device is a card swiping device, the second-level device category identifier is then matched with the device type identifier corresponding to the card type that has been activated in the electronic device. If there is a mismatch, it means that the card type that can interact with the NFC radio frequency device is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when the electronic device does not need to interact with the NFC radio frequency device.
[0084] In order to facilitate understanding of the NFC card swiping control method provided in the above embodiment, the above NFC card swiping control method is described below using a specific scenario embodiment. Figure 4 A flowchart of a scenario implementation of the NFC card swiping control method provided in an embodiment of the present application.
[0085] This scenario embodiment may specifically include the following steps:
[0086] Step 401: The electronic device receives a polling signal from an NFC radio frequency device.
[0087] Step 402, prohibiting the pop-up of the NFC card interface.
[0088] Step 403, whether the anti-mistouch data frame is received, if so, execute step 404, if not, return to step 402.
[0089] Step 404 , determining whether the device type identifier in the anti-mistouch data frame matches the device type identifier corresponding to the card type activated in the electronic device, if so, executing step 405 , if not, returning to step 402 .
[0090] Step 405: display the NFC card interface.
[0091] Step 406: start the card emulation mode, and send a feedback signal to the NFC radio frequency device when any one of the at least one protocol communication request data frame is received.
[0092] Step 407: completing the card swiping instruction interaction with the NFC radio frequency device.
[0093] Step 408: Card swiping is successful.
[0094] Step 409: The electronic device leaves the radio frequency field range of the NFC radio frequency device and turns off the card emulation mode.
[0095] Figure 5 The following is a flow chart of some NFC card reading control methods provided in the embodiments of the present application. The NFC card swiping control method can be executed by NFC radio frequency devices such as public transportation POS machines, access control POS machines, UnionPay POS machines, laptop computers, mobile phones, etc. The NFC card swiping control method may include:
[0096] Step 501, sending a polling signal to an electronic device, where the polling signal includes an anti-mistouch data frame;
[0097] The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
[0098] In step 501, the NFC radio frequency device can emit a radio frequency field, in which a polling signal is modulated. These polling signals can be used to detect whether an NFC card device is approaching. Figure 2 As shown, the polling signal 200 may include an anti-false touch data frame 201, and the anti-false touch data frame may be Ignore.
[0099] The anti-mistaken-touch data frame may include a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards. The protocol format of the anti-mistaken-touch data frame may be as described above, and will not be described in detail here.
[0100] In an embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identifier of the NFC radio frequency device from the anti-false touch data frame, and thus match it with the device type identifier corresponding to the card type that has been activated in the electronic device, and the electronic device can prohibit the pop-up of the NFC card interface when there is a mismatch, which can effectively avoid the accidental pop-up of the NFC card interface, and avoid the pop-up of the NFC card page disturbing the user when the electronic device uses the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0101] In some embodiments, the polling signal may further include at least one protocol communication request data frame; after sending the polling signal to the electronic device, the NFC card swiping control method may further include:
[0102] When a feedback signal sent by the electronic device is received and the feedback signal indicates to execute a process of data interaction with a card corresponding to the device type identifier in the electronic device, execute a process of data interaction with the card corresponding to the device type identifier in the electronic device;
[0103] The feedback signal is a control signal sent by the electronic device when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device and any protocol communication request data frame in at least one protocol communication request data frame is received.
[0104] In this embodiment, if Figure 2 As shown, the polling signal 200 may also include at least one protocol communication request data frame 202. Take the case where the number of at least one protocol communication request data frame 202 is two, including a first protocol communication request data frame 2021 and a second protocol communication request data frame 2022. The communication protocols corresponding to the first protocol communication request data frame 2021 and the second protocol communication request data frame 2022 are different. For example, the first protocol communication request data frame 2021 may be a data frame REQA requesting communication in the ISO14443-3-A protocol, and the second protocol communication request data frame 2022 may be a data frame REQB requesting communication in the ISO14443-3-B protocol. The NFC radio frequency device may cyclically send data frames REQA-Ignore-REQB to the electronic device. It is understandable that the structure and composition of the anti-mistouch data frame 201 and at least one protocol communication request data frame 202 in the polling signal 200 may be set according to actual needs. The above is only an example and is not a specific limitation.
[0105] After receiving a data frame in the polling signal, the electronic device can first determine whether it is an anti-false touch data frame. If it is not an anti-false touch data frame, it can continue to receive data frames in the polling signal until it receives an anti-false touch data frame. The anti-false touch data frame can be parsed to obtain a device type identifier. When the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device, any protocol communication request data frame in at least one protocol communication request data frame can be received, and a control signal is generated according to the protocol communication request data frame, that is, a feedback signal is sent to the NFC radio frequency device.
[0106] The NFC radio frequency device can receive a feedback signal sent by the electronic device, and the feedback signal can be used to indicate the execution of data interaction processing with the card corresponding to the device type identifier in the electronic device. If the protocol communication request data frame received by the electronic device is REQA, the NFC radio frequency device can receive the feedback signal ATQA. If the protocol communication request data frame received by the electronic device is REQB, the NFC radio frequency device can receive the feedback signal ATQB.
[0107] After receiving the feedback signal, the NFC radio frequency device can perform data interaction processing with the card corresponding to the device type identifier in the electronic device. For example, the NFC radio frequency device can send relevant instructions to the electronic device according to its own communication protocol logic, and the relevant instructions are used to instruct the reading of card information or the change of card information. The NFC radio frequency device can also receive the card information fed back by the electronic device in response to these instructions, as well as the execution of these instructions, until the card reading process is completed. For example, after receiving the feedback signal from the electronic device, the public transportation POS machine can send an instruction to read the transportation card ID and balance to the electronic device, and the electronic device can respond to the instruction to feedback the ID and balance of the activated transportation card to the public transportation POS machine. After deducting part of the fee based on the itinerary, the public transportation POS machine sends an instruction to change the balance to the electronic device, and the electronic device can respond to the instruction to change the balance of the transportation card to the balance after the deduction.
[0108] In the embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identification of the NFC radio frequency device from the anti-false touch data frame, and can display the NFC card interface and send a feedback signal to the NFC radio frequency device when the device type identification matches the device type identification corresponding to the card type that has been activated in the electronic device. The NFC radio frequency device can perform data interaction processing with the card corresponding to the device type identification in the electronic device according to the feedback signal, which can ensure the normal use of the NFC function of the electronic device, reduce the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to the accidental touch of the NFC radio frequency device, and reduce the risk of resource waste.
[0109] In order to facilitate understanding of the NFC card reading control method provided in the above embodiment, the above NFC card reading control method is described below using a specific scenario embodiment. Figure 6 A flowchart of a scenario implementation of the NFC card reading control method provided in an embodiment of the present application.
[0110] This scenario embodiment may specifically include the following steps:
[0111] Step 601: The NFC radio frequency device transmits a radio frequency field to the outside. A polling signal is modulated in the radio frequency field. The data frame sequence in the polling signal is REQA-Ignore-REQB.
[0112] Step 602 , whether a feedback signal ATQA or ATQB sent by the electronic device is received, if so, execute step 603 , if not, return to step 601 .
[0113] Step 603, executing the data interaction process with the card corresponding to the device type identifier in the electronic device, that is, completing the card swiping instruction interaction with the electronic device.
[0114] Step 604: Card reading is successful.
[0115] The NFC card swiping control method provided in the embodiment of the present application may be executed by an NFC card swiping control device, and the NFC card reading control method provided in the embodiment of the present application may be executed by an NFC card reading control device. In the embodiment of the present application, an NFC card swiping control device executing the NFC card swiping control method and an NFC card reading control device executing the NFC card reading control method are taken as examples to illustrate the NFC card swiping control device provided in the embodiment of the present application.
[0116] like Figure 7 As shown, the embodiment of the present application provides an NFC card swiping control device 700, and the NFC card swiping control device 700 may include:
[0117] The receiving module 701 is used to receive a polling signal sent by a near field communication NFC radio frequency device, where the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards;
[0118] The processing module 702 is used to prohibit the NFC card interface from popping up when the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device.
[0119] In an embodiment of the present application, the electronic device can receive a polling signal sent by a near field communication NFC radio frequency device, and determine whether the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device based on the device type identifier of the anti-mistouch data frame of the polling signal. If there is no match, it means that the card type that can interact with the NFC radio frequency device for data is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when using the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0120] In some embodiments, the NFC card swiping control device 700 may further include:
[0121] The display module is used to display the NFC card interface when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device.
[0122] In this way, the NFC card interface will only be displayed when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the risk of interference to the user caused by the pop-up NFC card interface of the electronic device due to accidental touching of the NFC radio frequency device.
[0123] In some embodiments, the polling signal further includes at least one protocol communication request data frame, and the NFC card swiping control device 700 may further include:
[0124] The sending module is used to send a feedback signal to the NFC radio frequency device after displaying the NFC card interface and receiving any one of the at least one protocol communication request data frames, wherein the feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
[0125] In an embodiment of the present application, when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device, the NFC card interface can be displayed and a feedback signal can be sent to the NFC radio frequency device, so that the NFC radio frequency device can execute data interaction processing with the card corresponding to the device type identifier in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to accidental touching of the NFC radio frequency device, thereby reducing the risk of wasting resources.
[0126] In some embodiments, the device type identifier includes a primary device category identifier and a secondary device category identifier;
[0127] Among them, the first-level device category identifier is used to indicate that the NFC radio frequency device is a card swiping device or a card reading device. The card swiping device is a device corresponding to the card swiping function, and different second-level device category identifiers indicate the function of data interaction with different types of cards; the card reading device is a device that only reads data.
[0128] In this way, it is possible to first determine whether the electronic device has a need to interact with the NFC radio frequency device and whether the NFC card interface needs to be displayed based on the primary device category identifier. In this way, the determination process of whether to prohibit the pop-up of the NFC card interface is further simplified, saving computing resources.
[0129] In some embodiments, the processing module 702 may also be used to:
[0130] When the primary device category identifier indicates that the NFC radio frequency device is a card reader device, the NFC card interface is prohibited from popping up.
[0131] In this way, when the first-level device category identifier indicates that the NFC radio frequency device is a card reader device, it can be directly determined that the electronic device does not need to interact with the NFC radio frequency device for data. At this time, the electronic device can directly prohibit the pop-up of the NFC card interface, saving computing resources.
[0132] In some embodiments, the processing module 702 may also be used to:
[0133] When the primary device category identifier indicates that the NFC radio frequency device is a card swiping device, the secondary device category identifier is matched with the device type identifier corresponding to the card type activated in the electronic device;
[0134] When the secondary device category identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is prohibited from popping up.
[0135] In this way, it is possible to first determine whether the electronic device has a need to interact with the NFC radio frequency device based on the first-level device category identifier. When the first-level device category identifier indicates that the NFC radio frequency device is a card swiping device, the second-level device category identifier is then matched with the device type identifier corresponding to the card type that has been activated in the electronic device. If there is a mismatch, it means that the card type that can interact with the NFC radio frequency device is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when the electronic device does not need to interact with the NFC radio frequency device.
[0136] like Figure 8 As shown, the embodiment of the present application further provides an NFC card reading control device 800, and the NFC card reading control device 800 may include:
[0137] The sending module 801 is used to send a polling signal to the electronic device, where the polling signal includes an anti-mistouch data frame;
[0138] The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
[0139] In an embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identifier of the NFC radio frequency device from the anti-false touch data frame, and thus match it with the device type identifier corresponding to the card type that has been activated in the electronic device, and the electronic device can prohibit the pop-up of the NFC card interface when there is a mismatch, which can effectively avoid the accidental pop-up of the NFC card interface, and avoid the pop-up of the NFC card page disturbing the user when the electronic device uses the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0140] In some embodiments, the polling signal further includes at least one protocol communication request data frame, and the NFC card reading control device 800 may further include:
[0141] A processing module, configured to, after sending a polling signal to the electronic device, execute a process of interacting with the card corresponding to the device type identifier in the electronic device when a feedback signal sent by the electronic device is received and the feedback signal indicates to execute a process of interacting with the card corresponding to the device type identifier in the electronic device;
[0142] The feedback signal is a control signal sent by the electronic device when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device and any protocol communication request data frame in at least one protocol communication request data frame is received.
[0143] In the embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identification of the NFC radio frequency device from the anti-false touch data frame, and can display the NFC card interface and send a feedback signal to the NFC radio frequency device when the device type identification matches the device type identification corresponding to the card type that has been activated in the electronic device. The NFC radio frequency device can perform data interaction processing with the card corresponding to the device type identification in the electronic device according to the feedback signal, which can ensure the normal use of the NFC function of the electronic device, reduce the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to the accidental touch of the NFC radio frequency device, and reduce the risk of resource waste.
[0144] The NFC card swiping control device and the NFC card reading control device in the embodiments of the present application can be a device or a component in the device, such as an integrated circuit or a chip. The device can be a terminal or other devices other than a terminal. Exemplarily, the device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc. It can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiments of the present application.
[0145] The NFC card swiping control device and the NFC card reading control device in the embodiment of the present application may be a device with an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0146] The NFC card swiping control device provided in the embodiment of the present application can achieve Figures 1 to 4 The NFC card reading control device provided in the embodiment of the present application can realize each process of the method embodiment. Figures 5 and 6 To avoid repetition, the various processes implemented by the method embodiment are not described here.
[0147] Alternatively, if Fig. 9 As shown, an embodiment of the present application further provides an electronic device 900, including a processor 901 and a memory 902, wherein the memory 902 stores a program or instruction that can be executed on the processor 901, and when the program or instruction is executed by the processor 901, the above-mentioned NFC card swiping control method embodiment, or each step of the NFC card reading control method is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0148] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
[0149] Fig.10 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.
[0150] The electronic device 1000 includes but is not limited to: a radio frequency unit 1001, a network module 1002, an audio output unit 1003, an input unit 1004, a sensor 1005, a display unit 1006, a user input unit 1007, an interface unit 1008, a memory 1009, and a processor 1010 and other components.
[0151] Those skilled in the art will appreciate that the electronic device 1000 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 1010 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Fig.10 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0152] For one electronic device, the radio frequency unit 1001 may be used for:
[0153] Receive a polling signal sent by a near field communication (NFC) radio frequency device, where the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards;
[0154] The processor 1010 may be configured to:
[0155] If the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is prohibited from popping up.
[0156] In an embodiment of the present application, the electronic device can receive a polling signal sent by a near field communication NFC radio frequency device, and determine whether the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device based on the device type identifier of the anti-mistouch data frame of the polling signal. If there is no match, it means that the card type that can interact with the NFC radio frequency device for data is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when using the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0157] In some embodiments, the display unit 1006 can be used to:
[0158] When the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is displayed.
[0159] In this way, the NFC card interface will only be displayed when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the risk of interference to the user caused by the pop-up NFC card interface of the electronic device due to accidental touching of the NFC radio frequency device.
[0160] In some embodiments, the polling signal further includes at least one protocol communication request data frame, and the radio frequency unit 1001 may also be used to:
[0161] After displaying the NFC card interface, upon receiving any one of at least one protocol communication request data frame, a feedback signal is sent to the NFC radio frequency device, wherein the feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
[0162] In an embodiment of the present application, when the device type identifier matches the device type identifier corresponding to the card type that has been activated in the electronic device, the NFC card interface can be displayed and a feedback signal can be sent to the NFC radio frequency device, so that the NFC radio frequency device can execute data interaction processing with the card corresponding to the device type identifier in the electronic device. This can ensure the normal use of the NFC function of the electronic device while reducing the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to accidental touching of the NFC radio frequency device, thereby reducing the risk of wasting resources.
[0163] In some embodiments, the device type identifier includes a primary device category identifier and a secondary device category identifier;
[0164] Among them, the first-level device category identifier is used to indicate that the NFC radio frequency device is a card swiping device or a card reading device. The card swiping device is a device corresponding to the card swiping function, and different second-level device category identifiers indicate the function of data interaction with different types of cards; the card reading device is a device that only reads data.
[0165] In this way, it is possible to first determine whether the electronic device has a need to interact with the NFC radio frequency device and whether the NFC card interface needs to be displayed based on the primary device category identifier. In this way, the determination process of whether to prohibit the pop-up of the NFC card interface is further simplified, saving computing resources.
[0166] In some embodiments, the processor 1010 may also be configured to:
[0167] When the primary device category identifier indicates that the NFC radio frequency device is a card reader device, the NFC card interface is prohibited from popping up.
[0168] In this way, when the first-level device category identifier indicates that the NFC radio frequency device is a card reader device, it can be directly determined that the electronic device does not need to interact with the NFC radio frequency device for data. At this time, the electronic device can directly prohibit the pop-up of the NFC card interface, saving computing resources.
[0169] In some embodiments, the processor 1010 may also be configured to:
[0170] When the primary device category identifier indicates that the NFC radio frequency device is a card swiping device, the secondary device category identifier is matched with the device type identifier corresponding to the card type activated in the electronic device;
[0171] When the secondary device category identifier does not match the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is prohibited from popping up.
[0172] In this way, it is possible to first determine whether the electronic device has a need to interact with the NFC radio frequency device based on the first-level device category identifier. When the first-level device category identifier indicates that the NFC radio frequency device is a card swiping device, the second-level device category identifier is then matched with the device type identifier corresponding to the card type that has been activated in the electronic device. If there is a mismatch, it means that the card type that can interact with the NFC radio frequency device is not the card type that has been activated in the electronic device. At this time, the NFC card interface is prohibited from popping up, which can effectively avoid the NFC card interface from popping up by mistake, and avoid the pop-up of the NFC card page disturbing the user when the electronic device does not need to interact with the NFC radio frequency device.
[0173] In some embodiments, for one electronic device, the radio frequency unit 1001 may be used for:
[0174] Sending a polling signal to the electronic device, wherein the polling signal includes an anti-mistouch data frame;
[0175] The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
[0176] In an embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identifier of the NFC radio frequency device from the anti-false touch data frame, and thus match it with the device type identifier corresponding to the card type that has been activated in the electronic device, and the electronic device can prohibit the pop-up of the NFC card interface when there is a mismatch, which can effectively avoid the accidental pop-up of the NFC card interface, and avoid the pop-up of the NFC card page disturbing the user when the electronic device uses the electronic device in scenarios where the electronic device does not need to interact with the NFC radio frequency device for data.
[0177] In some embodiments, the polling signal further includes at least one protocol communication request data frame, and the processor 1010 may further be configured to:
[0178] After sending a polling signal to the electronic device, when receiving a feedback signal sent by the electronic device and the feedback signal indicates to perform a process of data interaction with a card corresponding to the device type identifier in the electronic device, perform a process of data interaction with the card corresponding to the device type identifier in the electronic device;
[0179] The feedback signal is a control signal sent by the electronic device when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device and any protocol communication request data frame in at least one protocol communication request data frame is received.
[0180] In the embodiment of the present application, the NFC radio frequency device can send a polling signal with an anti-false touch data frame, so that the electronic device can determine the device type identification of the NFC radio frequency device from the anti-false touch data frame, and can display the NFC card interface and send a feedback signal to the NFC radio frequency device when the device type identification matches the device type identification corresponding to the card type that has been activated in the electronic device. The NFC radio frequency device can perform data interaction processing with the card corresponding to the device type identification in the electronic device according to the feedback signal, which can ensure the normal use of the NFC function of the electronic device, reduce the phenomenon of the electronic device arbitrarily mobilizing the NFC card swiping program due to the accidental touch of the NFC radio frequency device, and reduce the risk of resource waste.
[0181] It should be understood that in the embodiment of the present application, the input unit 1004 may include a graphics processor (Graphics Processing Unit, GPU) 10041 and a microphone 10042, and the graphics processor 10041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 1006 may include a display panel 10061, and the display panel 10061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 1007 includes a touch panel 10071 and at least one of other input devices 10072. The touch panel 10071 is also called a touch screen. The touch panel 10071 may include two parts: a touch detection device and a touch controller. Other input devices 10072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0182] The memory 1009 can be used to store software programs and various data. The memory 1009 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 1009 may include a volatile memory or a non-volatile memory, or the memory 1009 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 1009 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0183] The processor 1010 may include one or more processing units; optionally, the processor 1010 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 1010.
[0184] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned NFC card swiping control method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0185] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0186] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned NFC card swiping control method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0187] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0188] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned NFC card swiping control method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0189] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0190] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0191] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A NFC card swiping control method, executed by an electronic device, characterized in that: The method comprises: Receiving a polling signal sent by a near field communication (NFC) radio frequency device, wherein the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards; In the case where the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device, popping up the NFC card interface is prohibited.
2. The method according to claim 1, characterized in that: After receiving the polling signal sent by the near field communication NFC radio frequency device, the method further includes: When the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device, the NFC card interface is displayed.
3. The method according to claim 2, characterized in that The polling signal also includes at least one protocol communication request data frame; After displaying the NFC card interface, the method further includes: When any one of the at least one protocol communication request data frames is received, a feedback signal is sent to the NFC radio frequency device, wherein the feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
4. The method according to claim 1, characterized in that: The device type identification includes a primary device category identification and a secondary device category identification; Among them, the first-level device category identifier is used to indicate that the NFC radio frequency device is a card swiping device or a card reading device. The card swiping device is a device corresponding to the card swiping function, and different second-level device category identifiers indicate the function of data interaction with different types of cards; the card reading device is a device that only reads data.
5. The method according to claim 4, characterized in that After receiving the polling signal sent by the near field communication NFC radio frequency device, the method further includes: When the primary device category identifier indicates that the NFC radio frequency device is a card reader device, popping up the NFC card interface is prohibited.
6. The method according to claim 4, characterized in that The method of prohibiting the pop-up of the NFC card interface when the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device includes: When the primary device category identifier indicates that the NFC radio frequency device is a card swiping device, matching the secondary device category identifier with a device type identifier corresponding to an activated card type in the electronic device; In the case where the secondary device category identifier does not match the device type identifier corresponding to the card type activated in the electronic device, popping up the NFC card interface is prohibited.
7. An NFC card reading control method, executed by an NFC radio frequency device, characterized in that: The method comprises: Sending a polling signal to an electronic device, wherein the polling signal includes an anti-mistouch data frame; The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
8. The method according to claim 7, characterized in that The polling signal also includes at least one protocol communication request data frame; After sending the polling signal to the electronic device, the method further includes: When receiving a feedback signal sent by the electronic device and the feedback signal indicates to execute a process of data interaction with the card corresponding to the device type identifier in the electronic device, execute a process of data interaction with the card corresponding to the device type identifier in the electronic device; Among them, the feedback signal is a control signal sent by the electronic device when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device and any protocol communication request data frame in the at least one protocol communication request data frame is received.
9. An NFC card swiping control device, characterized in that: The device comprises: A receiving module, used to receive a polling signal sent by a near field communication NFC radio frequency device, wherein the polling signal includes an anti-mistaken touch data frame, wherein the anti-mistaken touch data frame includes a device type identifier, and different device type identifiers indicate a function of data interaction with different types of cards; The processing module is used to prohibit the pop-up of the NFC card interface when the device type identifier does not match the device type identifier corresponding to the card type activated in the electronic device.
10. The device according to claim 9, characterized in that The device also includes: The display module is used to display the NFC card interface when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device.
11. The device according to claim 10, characterized in that The polling signal also includes at least one protocol communication request data frame, and the device also includes: A sending module is used to send a feedback signal to the NFC radio frequency device after displaying the NFC card interface and receiving any one of the at least one protocol communication request data frame, wherein the feedback signal is used to instruct the NFC radio frequency device to perform data interaction processing with the card corresponding to the device type identifier in the electronic device.
12. The device according to claim 9, characterized in that The device type identification includes a primary device category identification and a secondary device category identification; Among them, the first-level device category identifier is used to indicate that the NFC radio frequency device is a card swiping device or a card reading device. The card swiping device is a device corresponding to the card swiping function, and different second-level device category identifiers indicate the function of data interaction with different types of cards; the card reading device is a device that only reads data.
13. The device according to claim 12, characterized in that The processing module is also used for: When the primary device category identifier indicates that the NFC radio frequency device is a card reader device, popping up the NFC card interface is prohibited.
14. The device according to claim 12, characterized in that The processing module is also used for: When the primary device category identifier indicates that the NFC radio frequency device is the card swiping device, matching the secondary device category identifier with a device type identifier corresponding to an activated card type in the electronic device; In the case where the secondary device category identifier does not match the device type identifier corresponding to the card type activated in the electronic device, popping up the NFC card interface is prohibited.
15. An NFC card reading control device, characterized in that: The device comprises: A sending module, used for sending a polling signal to an electronic device, wherein the polling signal includes an anti-mistouch data frame; The anti-mistouch data frame includes a device type identifier, and different device type identifiers indicate functions for data interaction with different types of cards.
16. The device according to claim 15, characterized in that The polling signal also includes at least one protocol communication request data frame, and the device also includes: a processing module, configured to, after sending a polling signal to an electronic device, execute a process of interacting with a card corresponding to the device type identifier in the electronic device when a feedback signal sent by the electronic device is received and the feedback signal indicates to execute a process of interacting with data with a card corresponding to the device type identifier in the electronic device; Among them, the feedback signal is a control signal sent by the electronic device when the device type identifier matches the device type identifier corresponding to the card type activated in the electronic device and any protocol communication request data frame in the at least one protocol communication request data frame is received.
17. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps of the method according to any one of claims 1 to 6 are implemented.
18. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the method according to claim 7 or 8 are implemented.