Nfc communication method, device, system, and storage medium

By embedding a virtual NCI module in the security processor, the functional instructions of the RF chip are parsed and executed, solving the communication problem of RF chips without NCI logic interfaces. This enables communication with the top-level system and functional expansion, reducing the cost of payment smart terminals.

CN115942290BActive Publication Date: 2026-01-13SHENZHEN XINGUODU TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211675211.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-26
Publication Date
2026-01-13
Estimated Expiration
2042-12-26

AI Technical Summary

Technical Problem

In existing payment smart terminals, radio frequency chips without NCI logic interfaces cannot communicate with the top-level Android system, resulting in the inability to implement rich NFC functions and increased costs.

Method used

A virtual NCI module is built into the secure processor. It obtains NCI instructions by parsing NFC protocol data packets and calls the radio frequency chip to execute the corresponding function instructions, thereby realizing the communication of the radio frequency chip.

Benefits of technology

Without increasing costs, communication between an RF chip without an NCI logic interface and the top-level system was achieved, supporting more application functions, reducing hardware dependence on the RF chip, and improving cost-effectiveness.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115942290B_ABST
    Figure CN115942290B_ABST
Patent Text Reader

Abstract

The application discloses an NFC communication method, device, system and storage medium, and relates to the technical field of communication, and comprises the following steps: receiving a starting instruction of an NFC service, and performing NFC initialization according to the starting instruction of the NFC service; receiving an NFC protocol data packet sent by an application processor, and unpacking the NFC protocol data packet to obtain an NCI instruction; the NFC protocol data packet is obtained by packing the NCI instruction received based on the NFC service by the application processor; performing analysis and processing on the NCI instruction through a virtual NCI module, and obtaining an analysis result corresponding to the NCI instruction; and when the analysis result represents that a radio frequency chip without an NCI interface needs to be executed, the radio frequency chip is called to execute a function instruction corresponding to the analysis result. The application can realize communication of the radio frequency chip without the NCI logical interface, and execute the function instruction corresponding to the NCI instruction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, and in particular to an NFC communication method, device, system and storage medium. Background Technology

[0002] In related technologies, payment smart terminals (such as POS terminals) used in the payment industry typically have NFC (Near Field Communication) functionality in their control systems (such as Android systems) to enable NCF services. To achieve this NFC functionality, payment smart terminals usually have an NFC controller (NFCC). An NFC controller can be understood as an NFC chip that implements the NFC function via radio frequency (RF) chips. This NFC chip controls the NFC function, enabling data transmission and reception. However, the NFC chip only handles data transmission and reception. To enable communication between different RF chips, a logical interface for establishing a communication connection needs to be defined. Therefore, the NCI (NFC Controller Interface) has emerged. The NCI defines the logical interface for communication between the NFC chip and the processor. Currently, in payment smart terminals within the payment industry, to implement the NCI logic interface function, an RF chip integrating NCI is typically configured. This increases the cost of payment smart terminals. Therefore, to achieve lower costs and meet related authentication requirements, some payment smart terminals select RF chips that do not integrate the NCI logic interface. This prevents these underlying RF chips from communicating with the top-level Android system via NFC. Therefore, how to implement the NCI logic interface function of such RF chips and interface with the top-level Android system without significantly increasing costs has become an urgent technical problem to be solved. Summary of the Invention

[0003] This application aims to address at least one of the technical problems existing in the prior art. To this end, this application proposes an NFC communication method, device, system, and storage medium, which enables communication with the RF chip and execution of the functional instructions corresponding to the NCI instructions, even when the RF chip does not have an NCI logic interface.

[0004] An NFC communication method according to a first aspect embodiment of this application is applied to a secure processor (SP), the secure processor having a built-in virtual NCI module, the method comprising:

[0005] Receive the NFC service activation command and perform NFC initialization according to the NFC service activation command;

[0006] The application processor (AP) receives NFC protocol data packets and unpacks the NFC protocol data packets to obtain NCI instructions; the NFC protocol data packets are obtained by the application processor after repackaging the NCI instructions received based on the NFC service.

[0007] The NCI instruction is parsed and processed by the virtual NCI module to obtain the parsing result corresponding to the NCI instruction;

[0008] When the parsing result indicates that an RF chip without an NCI interface needs to be executed, the RF chip is invoked to execute the function instruction corresponding to the parsing result.

[0009] According to some embodiments of this application, the step of parsing and processing the NCI instructions through a virtual NCI module includes:

[0010] If the NCI instruction is a standard instruction, then the standard definition of the NCI instruction is determined, and the NCI instruction is parsed and processed according to the standard definition through the virtual NCI module;

[0011] If the NCI instruction is a custom instruction, then the definition document of the custom instruction is called, and the virtual NCI module parses and processes the NCI instruction according to the definition document.

[0012] According to some embodiments of this application, the method further includes:

[0013] Obtain the processing result of executing the function instruction, and encapsulate the processing result to obtain a result data packet;

[0014] The result data packet is sent to the application processor.

[0015] According to some embodiments of this application, the method further includes:

[0016] When the parsing result indicates that the virtual NCI module needs to be executed, the virtual NCI module executes the function instruction corresponding to the parsing result.

[0017] An NFC communication method according to a second aspect embodiment of this application, applied to an application processor (AP), the method comprising:

[0018] Receive the NFC service activation command and perform NFC initialization according to the NFC service activation command;

[0019] The application processor writes NCI instructions to the NFCC device node and encapsulates the NCI instructions to obtain NFC protocol data packets.

[0020] The NFC protocol data packet is forwarded to the SP device node of the application processor, and the NFC protocol data packet is sent to the security processor (SP) through the SP device node.

[0021] According to some embodiments of this application, the encapsulation of the NCI instruction includes:

[0022] The NCI command is packaged using the pre-defined read / write function of the NFCC device node.

[0023] According to some embodiments of this application, sending the NFC protocol data packet to the security processor (SP) via the SP device node includes:

[0024] The NFC protocol data packet is transparently transmitted to the security processor through the SP device node.

[0025] An NFC communication device according to a third aspect embodiment of this application includes an application processor and a security processor, wherein the application processor and the security processor respectively receive an NFC service activation instruction and perform NFC initialization according to the NFC service activation instruction;

[0026] The application processor writes an NCI instruction through its NFCC device node, encapsulates the NCI instruction to obtain an NFC protocol data packet, forwards the NFC protocol data packet to the application processor's SP device node, and sends the NFC protocol data packet to the security processor through the SP device node.

[0027] The security processor receives NFC protocol data packets sent by the application processor and unpacks the NFC protocol data packets to obtain NCI instructions; it then parses the NCI instructions through a virtual NCI module to obtain the parsing result corresponding to the NCI instructions; when the parsing result indicates that an RF chip without an NCI interface needs to execute, it calls the RF chip to execute the function instruction corresponding to the parsing result.

[0028] An NFC communication system according to a fourth aspect of this application includes:

[0029] At least one memory;

[0030] At least one processor;

[0031] At least one program;

[0032] The program is stored in the memory, and the processor executes at least one of the programs to implement the method as described in the first aspect embodiment and the second aspect embodiment.

[0033] According to a fifth aspect embodiment of the present application, a computer-readable storage medium stores computer-executable instructions for causing a computer to perform the methods described in the first and second aspect embodiments.

[0034] The NFC communication method according to the embodiments of this application has the following beneficial effects: First, the secure processor receives the NFC service startup command and performs NFC initialization according to the NFC service startup command; second, the secure processor receives the NFC protocol data packet sent by the application processor and unpacks the NFC protocol data packet to obtain the NCI command; the NFC protocol data packet is obtained by the application processor after encapsulating the NCI command received based on the NFC service; then, the NCI command is parsed through the virtual NCI module to obtain the parsing result corresponding to the NCI command; when the parsing result indicates that an RF chip without an NCI interface needs to be executed, the secure processor calls the RF chip to execute the function command corresponding to the parsing result. The NFC communication method of this application utilizes the NFCC device node of the application processor to write NCI instructions and the SP device node of the application processor to send NFC protocol data packets to the security processor. The security processor receives the NFC protocol data packets, unpacks them to obtain the NCI instructions, and further parses the NCI instructions to obtain function instructions. The security processor can then call the RF chip to execute the corresponding function instructions based on the function instructions. Therefore, the security processor can send NFC protocol data packets through the SP device node of the application processor even when the RF chip does not have an NCI logic interface. Furthermore, the security processor has a built-in NFC protocol data packet receiving function and a virtual NCI module. The virtual NCI module can call the RF chip to perform relevant processing based on the parsing results, enabling communication with RF chips that lack an NCI logic interface. Therefore, the NFC communication method of this application can achieve communication with the RF chip and execute the function instructions corresponding to the NCI instructions even when the RF chip does not have an NCI logic interface.

[0035] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description

[0036] The present application will be further described below with reference to the accompanying drawings and embodiments, wherein:

[0037] Figure 1 This is a communication diagram of an application processor and a radio frequency chip provided in one embodiment of this application;

[0038] Figure 2 A communication diagram of an application processor and a radio frequency chip provided in another embodiment of this application;

[0039] Figure 3 This is a flowchart illustrating an embodiment of the NFC communication method provided in this application;

[0040] Figure 4 This is a flowchart illustrating an NFC communication method provided in another embodiment of this application;

[0041] Figure 5 A communication diagram of the application processor, security processor, and radio frequency chip provided in another embodiment of this application;

[0042] Figure 6 This is a schematic diagram of the structure of an NFC communication device provided in one embodiment of this application.

[0043] Figure 7 This is a schematic diagram of the structure of an NFC communication system provided in one embodiment of this application.

[0044] Figure label:

[0045] Application processor 100, security processor 110, virtual NCI module 120, memory 200, processor 300. Detailed Implementation

[0046] The embodiments of this application are described in detail below. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain this application, and should not be construed as limiting this application.

[0047] It should be noted that although functional modules are divided in the system diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the system or the order in the flowchart. The terminology in the specification, claims, and the foregoing figures is used to distinguish similar objects and is not necessarily used to describe a specific order or sequence.

[0048] In the description of this application, "several" means one or more, "multiple" means two or more, "greater than," "less than," and "exceeding" are understood to exclude the stated number, while "above," "below," and "within" are understood to include the stated number. The use of "first" and "second" in the description is merely for distinguishing technical features and should not be construed as indicating or implying relative importance, or implicitly indicating the number of indicated technical features, or implicitly indicating the order of the indicated technical features.

[0049] In the description of this application, unless otherwise expressly defined, terms such as "setup," "installation," and "connection" should be interpreted broadly, and those skilled in the art can reasonably determine the specific meaning of the above terms in this application in conjunction with the specific content of the technical solution.

[0050] In the description of this application, the terms "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0051] The following are explanations of some of the terms:

[0052] Near Field Communication (NFC) is a communication technology that allows devices (such as mobile phones) to exchange data when they are close to each other. It evolved from contactless radio frequency identification (RFID) and interconnection technologies. By integrating inductive card readers, inductive cards, and point-to-point communication functions on a single chip, it enables applications such as mobile payment, electronic ticketing, access control, mobile identity recognition, and anti-counterfeiting using mobile terminals.

[0053] NFC chip: A chip with communication and computing capabilities. NFC-enabled mobile phones have built-in NFC chips, which add two-way data transmission capabilities compared to RFID, which was originally only used as a tag. This advancement makes it more suitable for electronic money payments; in particular, mutual authentication, dynamic encryption, and one-time keys (OTPs) can be achieved on NFC, which RFID cannot. NFC technology supports a variety of applications, including mobile payments and transactions, peer-to-peer communication, and mobile information access. With an NFC-enabled mobile phone, people can connect with their desired entertainment services and transactions anytime, anywhere, through any device, to complete payments, obtain poster information, etc. NFC devices can be used as contactless smart cards, smart card reader terminals, and device-to-device data transmission links. Its applications can be mainly divided into the following four basic types: for payment and ticketing, for electronic tickets, for smart media, and for exchanging and transmitting data.

[0054] NFC Controller: The English name is NFC Controller, abbreviated as NFCC. The use of NFC enables data to be transmitted wirelessly over relatively short distances. In many applications, such as mobile phones, the NFC controller acts as a proxy server for communication between the host processor, secure element, and contactless front end.

[0055] NFC-enabled mobile devices typically contain a host processor and an NFC controller operatively coupled to the host processor. The NFC controller is configured to control near-field communication between the NFC device and external devices such as NFC readers. NFC-enabled mobile devices can operate in so-called card mode, meaning they can emulate smart cards. In some applications, stable and reliable communication between the NFC reader and the NFC-enabled mobile device is crucial.

[0056] NCI (NFC Controller Interface): This is a specification developed by the NFC Forum in 2012. Its main focus is on how the DH (Device Host) controls and interacts with the NFCC. NCI is a specification based on NFC that defines a set of interaction interfaces that allow the host device (Device Host; in a mobile phone, for example, if the NFC chip is integrated into a mobile phone, then the mobile phone is the Device Host, or DH for short) to use these interfaces to interact with the NFC chip. In other words, NCI defines the interaction interface between the NFCC and the DH.

[0057] In related technologies, NCI defines the interface between NFCC and DH. NFCC refers to the entity that implements NFC data transmission and reception and runs the NFC protocol stack. DH is responsible for the management of NFCC, such as initialization, configuration, and power management. Taking a mobile phone with NFC functionality as an example, NFCC refers to the NFC chip in the phone that implements NFC functionality, and DH is the phone's processor. NCI defines the logical interface for communication between the mobile phone's NFC chip and the processor.

[0058] Currently, to support the NFC functionality of payment smart terminals, RF chip manufacturers typically embed the NCI (Non-Contactless Interchange) function into the firmware of contactless chips (i.e., RF chips), providing them as RF chips with NCI functionality. In non-payment industries, the NFC function of smart terminals is generally achieved by connecting an external RF chip with an NCI interface, such as... Figure 1 As shown, the application processor (AP) in the smart terminal is equipped with an NFCC device node, which is used to communicate with an RF chip with an NCI function interface.

[0059] In the payment industry, due to the need for EMV L1 certification (which requires payment devices to meet protocol and electrical testing requirements), and to reduce costs and increase flexibility in certification debugging, almost all devices choose RF chips without NCI functionality, such as... Figure 2 As shown, in a payment smart terminal, the application processor is equipped with a dedicated SP device node that communicates with the security processor (SP). However, only basic functions can be implemented through this SP device node and the RF chip. This means that the logic interface corresponding to the mature standard NFC function in the control system (such as the Android system) of the payment smart terminal cannot be connected to the RF chip, and the mature standard NFC function and its corresponding logic interface cannot be used to execute richer function instructions.

[0060] Based on this, embodiments of this application provide an NFC communication method, device, system, and storage medium, which can realize communication with the RF chip and execute the functional instructions corresponding to the NCI instructions even when the RF chip does not have a logic interface.

[0061] The following reference Figure 3-5 This application describes an NFC communication method according to an embodiment.

[0062] Understandably, referring to Figure 3 and Figure 5 An NFC communication method is provided, applied to a secure processor 110 (SP), which has a built-in virtual NCI module 120. The method includes:

[0063] Step S100: Receive the NFC service startup command and perform NFC initialization according to the NFC service startup command;

[0064] Step S110: Receive the NFC protocol data packet sent by the application processor 100 (AP), and unpack the NFC protocol data packet to obtain the NCI instruction; the NFC protocol data packet is obtained by the application processor 100 after encapsulating the NCI instruction received based on the NFC service.

[0065] Step S120: The virtual NCI module 120 parses and processes the NCI instruction to obtain the parsing result corresponding to the NCI instruction;

[0066] Step S130: When the parsing result indicates that an RF chip without an NCI interface needs to be executed, the RF chip is called to execute the function instruction corresponding to the parsing result.

[0067] It should be noted that the virtual NCI module 120 is the NCI firmware loaded inside the security processor 110, and this NCI firmware can be loaded onto any processor that can be loaded.

[0068] It should be noted that NCI instructions can be understood as instructions used to implement the corresponding functions through the NCI interface.

[0069] It should be noted that the NCI interface can be understood as a programmable interface written inside the radio frequency chip, which enables the distribution and transmission of NFC service instructions.

[0070] It is understandable that the NCI instructions are parsed and processed through the virtual NCI module 120, including:

[0071] If the NCI instruction is a standard instruction, then the standard definition of the NCI instruction is determined, and the NCI instruction is parsed and processed according to the standard definition through the virtual NCI module 120;

[0072] If the NCI instruction is a custom instruction, the definition document of the custom instruction is called, and the virtual NCI module 120 parses and processes the NCI instruction according to the definition document.

[0073] It should be noted that standard documents contain standard function instructions corresponding to standard instructions, while custom documents contain custom function instructions corresponding to custom instructions.

[0074] Understandably, the methods also include:

[0075] Obtain the processing result of the executed function instruction, and encapsulate the processing result to obtain the result data packet;

[0076] Send the result data packet to application processor 100.

[0077] Understandably, the methods also include:

[0078] When the parsing result representation requires execution by the virtual NCI module, the function instructions corresponding to the parsing result are executed through the virtual NCI module.

[0079] Understandably, referring to Figure 3 and Figure 4 An NFC communication method is provided, applied to an application processor 100 (AP), the method comprising:

[0080] Step S200: Receive the NFC service startup command and perform NFC initialization according to the NFC service startup command;

[0081] Step S210: Write NCI instructions through the NFCC device node of the application processor 100 and encapsulate the NCI instructions to obtain NFC protocol data packets;

[0082] In step S220, the NFC protocol data packet is forwarded to the SP device node of the application processor 100, and the NFC protocol data packet is sent to the security processor 110 (SP) through the SP device node.

[0083] According to some embodiments of this application, the NCI instruction is packaged, including:

[0084] The NCI command is packaged using the pre-defined read / write functions of the NFCC device node.

[0085] It should be noted that read / write functions can be understood as functions that write or read NCI commands, and these functions are built into the program.

[0086] It is understandable that sending NFC protocol data packets to the security processor 110 (SP) via the SP device node includes:

[0087] The NFC protocol data packets are transparently transmitted to the security processor 110 via the SP device node.

[0088] First, the security processor 110 receives the NFC service activation command and performs NFC initialization according to the NFC service activation command. Second, the security processor 110 receives the NFC protocol data packet sent by the application processor 100 and unpacks the NFC protocol data packet to obtain the NCI command. The NFC protocol data packet is obtained by the application processor 100 after encapsulating the NCI command received based on the NFC service. Then, the virtual NCI module 120 parses the NCI command to obtain the parsing result corresponding to the NCI command. When the parsing result indicates that an RF chip without an NCI interface needs to be executed, the security processor 110 calls the RF chip to execute the function command corresponding to the parsing result. The NFC communication method of this application involves writing NCI instructions using the NFCC device node of the application processor 100 and sending NFC protocol data packets to the security processor 110 using the SP device node of the application processor 100. The security processor 110 receives the NFC protocol data packets, unpacks them to obtain the NCI instructions, and further parses the NCI instructions to obtain function instructions. The security processor 110 then calls the RF chip according to the function instructions to execute the corresponding function instructions. Therefore, the security processor 110 can send NFC protocol data packets through the SP device node of the application processor 100 even when the RF chip does not have an NCI logic interface. The security processor 110 also has a built-in NFC protocol data packet receiving function and a virtual NCI module 120. The virtual NCI module 120 can call the RF chip for relevant processing based on the parsing results, enabling communication with the RF chip that lacks an NCI logic interface. Therefore, the NFC communication method of this application can achieve communication with the RF chip and execute the function instructions corresponding to the NCI instructions even when the RF chip does not have an NCI logic interface.

[0089] The following is combined with Figure 5 The NFC communication method of this application will be further elaborated.

[0090] According to the NFC communication method of this application, a virtual NCI module 120 is added between the payment smart terminal and the radio frequency chip that does not have an NCI logic interface. The virtual NCI module 120 implements the NCI logic interface and interface with the Android system at the top, and can interface with different applications (APPs) installed on the Android system of different payment smart terminals at the bottom. At the top level, as long as the developed APP conforms to the Android system framework, it can call the radio frequency chip through the virtual NCI module 120 when starting the FC service, and thus implement the corresponding function instructions. In other words, the NCI logic interface is no longer embedded in the radio frequency chip, but is loaded and provided in software, thus enabling more APPs to be adapted. The APP does not need to make relevant modifications to adapt to the radio frequency chip, because the relevant functions have been implemented through the underlying virtual NCI module 120. The APP only needs to start the NFC service normally.

[0091] The interaction process between the application processor 100, the security processor 110, and the radio frequency chip is described below.

[0092] Step 1: Start the NFC service of the payment smart terminal, and use the NFCC device node of the application processor 100 to perform write and read operations using NCI instructions, that is, read the data corresponding to the NCI instructions or write the data corresponding to the NCI instructions.

[0093] In this step, the original communication method of the NFC service is not changed, and data is written and read from the NFCC device node normally.

[0094] Step 2: Encapsulate and forward the data sent and received by the NFCC device node to the SP device node of the application processor 100.

[0095] In this step, the read and write functions are adjusted to encapsulate the read and write data into the transmission data format of the SP device node and then forward it to the SP device node.

[0096] Step 3: The SP device node transmits the encapsulated NFC protocol data packet to the virtual NCI module 120 in the SP.

[0097] Step 4: The security processor 110 unpacks the received NFC protocol data packets and sends the processing result back in a packet.

[0098] In this step, the security processor 110 passes the unpacked NCI commands to the virtual NCI module 120. The virtual NCI module 120 is stored in the security processor 110 as firmware, which is used for parsing NCI commands. During the parsing process, the virtual NCI module 120 responds to standard NCI commands or custom NCI commands from the NFC service (different manufacturers' NFC services may have special NCI commands): for standard NCI commands, it parses them according to the NCI command definition in the standard document; for custom NCI commands, it parses them according to the manufacturer's custom document. After the virtual NCI module 120 completes its processing, the SP firmware encapsulates and sends back the processing result of the virtual NCI module 120. That is, it routes the data from the SP's device node to the NFCC's device node for transmission. The reason for this transmission is that the data from the current NFCC device node is being routed to the SP device node, not the actual NFCC.

[0099] It should be noted that the virtual NCI module 120 can also be loaded onto the application processor 100 and can also perform the corresponding functions.

[0100] Step 5: The virtual NCI module 120 calls the RF chip without an NCI logic interface, and further calls the RF chip's communication interface to realize the relevant functions of the NCI command.

[0101] It should be noted that the virtual NCI module 120 provides three functions: First, it processes NCI commands issued by the control system in the payment smart terminal to respond to functions not provided by the RF chip, satisfying the NFC service initialization of the control system and ensuring the correct execution of subsequent NCI commands; second, it calls existing interfaces of the RF chip, such as turning the field strength on and off, executing card query, and transparently transmitting APUD commands; third, it executes the automatic card query function. The NCI logic interface is not placed in the fixed RF chip. For the control system, the NFC service implements NFC functionality normally. However, for the hardware selection of the payment smart terminal, it not only allows for the selection of lower-cost RF chips but also provides greater choice, not being limited to a single RF chip manufacturer, giving the payment smart terminal a significant cost advantage.

[0102] It should be noted that if only basic payment services are performed, the application processor 100 can directly control the RF chip without an NCI logic interface.

[0103] The following is combined with Figure 6 This application describes an NFC communication device according to an embodiment.

[0104] It is understandable that, such as Figure 6As shown, an NFC communication device is provided, including an application processor 100 and a security processor 110. The application processor 100 and the security processor 110 respectively receive an NFC service startup instruction and perform NFC initialization according to the NFC service startup instruction.

[0105] Application processor 100 writes NCI instructions through its NFCC device node and encapsulates the NCI instructions to obtain NFC protocol data packets; it then forwards the NFC protocol data packets to its SP device node and sends the NFC protocol data packets to security processor 110 through the SP device node.

[0106] The security processor 110 receives the NFC protocol data packet sent by the application processor 100 and unpacks the NFC protocol data packet to obtain the NCI instruction; it then parses the NCI instruction through the virtual NCI module 120 to obtain the parsing result corresponding to the NCI instruction; if the parsing result indicates that an RF chip without an NCI interface needs to execute, it calls the RF chip to execute the function instruction corresponding to the parsing result.

[0107] The following reference Figure 7 This application describes an NFC communication system according to an embodiment of the present application.

[0108] It is understandable that, such as Figure 7 As shown, the NFC communication system includes:

[0109] At least one memory 200;

[0110] At least one processor 300;

[0111] At least one program;

[0112] The program is stored in memory 200, and processor 300 executes at least one program to implement the NFC communication method described above. Figure 7 Take a processor 300 as an example.

[0113] The processor 300 and the memory 200 can be connected via a bus or other means. Figure 7 Take a bus connection as an example.

[0114] The memory 200, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs, non-transitory computer-executable programs, and signals, such as the program instructions / signals corresponding to the NFC communication system in this embodiment. The processor 300 executes various functional applications and data processing by running the non-transitory software programs, instructions, and signals stored in the memory 200, thereby implementing the NFC communication method of the above-described method embodiment.

[0115] The memory 200 may include a program storage area and a data storage area. The program storage area may store the operating system and applications required for at least one function; the data storage area may store data related to the NFC communication method described above. Furthermore, the memory 200 may include high-speed random access memory and non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, the memory 200 may optionally include memory remotely located relative to the processor 300, and these remote memories can be connected to the NFC communication system via a network. Examples of such networks include, but are not limited to, the Internet of Things (IoT), software-defined networks, sensor networks, the Internet, enterprise intranets, local area networks (LANs), mobile communication networks, and combinations thereof.

[0116] One or more signals are stored in memory 200, and when executed by one or more processors 300, the NFC communication method in any of the above method embodiments is performed. For example, the above-described... Figure 3 and Figure 4 The method in the middle.

[0117] The following reference Figure 7 This application describes a computer-readable storage medium according to embodiments thereof.

[0118] like Figure 7 As shown, a computer-readable storage medium stores computer-executable instructions that are executed by one or more processors 300, for example, by... Figure 7 One or more processors 300 may execute the NFC communication method described in the above method embodiments. For example, the above-described... Figure 3 and Figure 4 The method in the middle.

[0119] The system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0120] Based on the above description of the embodiments, those skilled in the art will understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer storage media and communication media. As is known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital multifunction disk or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and can be accessed by a computer. Furthermore, it is known to those skilled in the art that communication media typically contain computer-readable signals, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and can include any information delivery medium.

[0121] The embodiments of this application have been described in detail above with reference to the accompanying drawings. However, this application is not limited to the above embodiments. Within the scope of knowledge possessed by those skilled in the art, various changes can be made without departing from the spirit of this application. Furthermore, unless otherwise specified, the embodiments and features described in the embodiments of this application can be combined with each other.

Claims

1. An NFC communication method, characterized in that, Applied to a security processor (SP), which has a built-in virtual NCI module, the method includes: Receive the NFC service activation command and perform NFC initialization according to the NFC service activation command; The system receives NFC protocol data packets sent by the application processor (AP) and unpacks the NFC protocol data packets to obtain NCI instructions. The NFC protocol data packets are obtained by the application processor after encapsulating the NCI instructions received based on the NFC service. The NCI instructions are instructions used to implement corresponding functions through the NCI interface. The NCI interface is used to implement instruction distribution and transmission for the NFC service. The NCI instruction is parsed and processed by the virtual NCI module to obtain the parsing result corresponding to the NCI instruction; When the parsing result indicates that an RF chip without an NCI interface needs to be executed, the RF chip is invoked to execute the function instruction corresponding to the parsing result; When the parsing result indicates that the virtual NCI module needs to be executed, the virtual NCI module executes the function instruction corresponding to the parsing result.

2. The NFC communication method according to claim 1, characterized in that, The process of parsing and processing the NCI instructions through the virtual NCI module includes: If the NCI instruction is a standard instruction, then the standard definition of the NCI instruction is determined, and the NCI instruction is parsed and processed according to the standard definition through the virtual NCI module; If the NCI instruction is a custom instruction, then the definition document of the custom instruction is called, and the virtual NCI module parses and processes the NCI instruction according to the definition document.

3. The NFC communication method according to claim 1, characterized in that, The method further includes: Obtain the processing result of executing the function instruction, and encapsulate the processing result to obtain a result data packet; The result data packet is sent to the application processor.

4. An NFC communication method, characterized in that, Applied to an application processor (AP), the method includes: Receive the NFC service activation command and perform NFC initialization according to the NFC service activation command; The application processor writes NCI instructions to the NFCC device node and encapsulates the NCI instructions to obtain NFC protocol data packets. The NFC protocol data packet is forwarded to the SP device node of the application processor, and the NFC protocol data packet is sent to the security processor (SP) through the SP device node, wherein the security processor performs the method as described in any one of claims 1 to 3.

5. The NFC communication method according to claim 4, characterized in that, The process of encapsulating the NCI command includes: The NCI command is packaged using the pre-defined read / write function of the NFCC device node.

6. The NFC communication method according to claim 4, characterized in that, Sending the NFC protocol data packet to the security processor (SP) via the SP device node includes: The NFC protocol data packet is transparently transmitted to the security processor through the SP device node.

7. An NFC communication device, characterized in that, It includes an application processor and a security processor, wherein the application processor and the security processor respectively receive an NFC service startup instruction and perform NFC initialization according to the NFC service startup instruction; The application processor writes an NCI instruction through its NFCC device node, encapsulates the NCI instruction to obtain an NFC protocol data packet, forwards the NFC protocol data packet to the application processor's SP device node, and sends the NFC protocol data packet to the security processor through the SP device node. The security processor receives NFC protocol data packets sent by the application processor and unpacks the NFC protocol data packets to obtain NCI instructions. NCI instructions are instructions used to implement corresponding functions through the NCI interface. The NCI interface is used to distribute and transmit instructions for the NFC service. The virtual NCI module parses the NCI instructions to obtain the parsing result. When the parsing result indicates that an RF chip without an NCI interface needs to execute, the RF chip is invoked to execute the function instruction corresponding to the parsing result. When the parsing result indicates that the virtual NCI module needs to execute, the virtual NCI module executes the function instruction corresponding to the parsing result.

8. An NFC communication system, characterized in that, include: At least one memory; At least one processor; At least one program; The program is stored in the memory, and the processor executes at least one of the programs to implement the method as claimed in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions for causing a computer to perform the method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Communications techniques for secure near field communication architecture

    CN105379171A

  • Method and device for simulating NFC function, NFC terminal and storage medium

    CN114301506A