A method and system for realizing fast interconnection of devices based on NFC

NFC technology enables rapid interconnection between devices, solving the problem of complexity in traditional device interconnection methods, improving user experience, reducing development costs, and enhancing network scalability.

CN114501406BActive Publication Date: 2025-11-18FUJIAN WISBO DIGITAL TECHNOLOGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210032863.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-12
Publication Date
2025-11-18
Estimated Expiration
2042-01-12

AI Technical Summary

Technical Problem

Existing methods of interconnecting devices are cumbersome, result in poor user experience, high developer costs, and poor network scalability.

Method used

NFC technology is used to enable rapid interconnection of devices. Through the exchange of NFC information between the first terminal and the second terminal, the optimal interconnection channel is automatically selected and a connection is established.

Benefits of technology

It enables rapid and seamless device connectivity, reduces user operation complexity and business development costs, and improves network scalability and interconnection efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114501406B_ABST
    Figure CN114501406B_ABST
Patent Text Reader

Abstract

The application discloses a method and system for realizing fast interconnection of devices based on NFC; a first terminal acquires terminal information of the first terminal, calls a native NFC interface according to an application request, and starts an NFC card reading function; a second terminal calls the native NFC interface, and starts an NFC simulation card function; when the first terminal detects that the second terminal is close, the first terminal sends the terminal information to the second terminal; the second terminal receives the terminal information of the first terminal, selects an interconnection channel according to the terminal information, initiates an interconnection request to the first terminal, and establishes interconnection; the application can realize fast discovery and selection of target devices through NFC when a service is needed, a user does not need to manually select the target device, and the application is more convenient; the application automatically selects an interconnection channel according to data transmitted by NFC, realizes fast and non-inductive connection between devices, a service developer does not need to consider a networking mode and a physical protocol, service cost is reduced, and the application has higher scalability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of mobile communication technology, and in particular to a method and system for achieving rapid interconnection of devices based on NFC. Background Technology

[0002] As the Android system continues to develop, it is used in more and more devices, such as mobile phones, POS machines, and cash registers. Android provides many channels for interconnection between devices, such as Wi-Fi AP, Wi-Fi P2P, Bluetooth, NFC, and LAN; however, these traditional interconnection methods have significant shortcomings in terms of both user convenience and developer convenience.

[0003] Firstly, traditional device discovery is often based on Wi-Fi and Bluetooth. Users need to manually turn on Wi-Fi and Bluetooth, enter the settings app, search for nearby devices, and then select the target device from a list of discovered devices. Connecting devices also requires numerous user operations and interactions. In today's world, where user experience and convenience are increasingly valued, such a cumbersome process often reduces user engagement. Furthermore, interconnectivity via Wi-Fi and Bluetooth is inherently isolated, preventing interoperability. Developers need to adapt to different network protocols and standards across heterogeneous networks, leading to high development costs and poor network scalability. Summary of the Invention

[0004] The technical problem to be solved by this invention is to provide a method and system for achieving rapid device interconnection based on NFC, which can reduce business development costs and improve network scalability while achieving rapid device interconnection.

[0005] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows:

[0006] A method for achieving fast device interconnection based on NFC includes the following steps:

[0007] S1. The first terminal obtains its own terminal information and, according to the application request, calls the native NFC interface to enable the NFC card reading function.

[0008] S2. The second terminal calls the native NFC interface to enable the NFC simulated card function;

[0009] S3. When the first terminal detects that the second terminal is approaching, it sends the terminal information to the second terminal.

[0010] S4. The second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0011] To solve the above-mentioned technical problems, another technical solution adopted by the present invention is as follows:

[0012] A system for rapid device interconnection based on NFC includes a first terminal and a second terminal. The first terminal includes a first processor, a first memory, and a first computer program stored in the first memory and executable on the first processor. The second terminal includes a second processor, a second memory, and a computer program stored in the second memory and executable on the second processor. When the first processor executes the first computer program, it performs the following steps:

[0013] S1. Obtain its own terminal information, and according to the application request, call the native NFC interface to enable the NFC card reading function;

[0014] S3. When the second terminal is detected to be approaching, the terminal information is sent to the second terminal;

[0015] When the second processor executes the second computer program, it performs the following steps:

[0016] S2. Call the native NFC interface to enable the NFC emulation card function;

[0017] S4. Receive the terminal information from the first terminal, select an interconnection channel based on the terminal information, and initiate an interconnection request to the first terminal to establish interconnection.

[0018] The beneficial effects of this invention are as follows: When business needs arise, this invention can quickly discover and select target devices through NFC, eliminating the need for users to manually select target devices, making it more convenient. Furthermore, it automatically selects the interconnection channel based on the data transmitted by NFC, enabling fast and seamless connection between devices. Business developers do not need to consider networking methods and physical protocols, reducing business costs and offering higher scalability. Attached Figure Description

[0019] Figure 1 This is a flowchart illustrating a method for achieving rapid device interconnection based on NFC, according to an embodiment of the present invention.

[0020] Figure 2 This is a structural diagram of a system for achieving rapid device interconnection based on NFC, according to an embodiment of the present invention.

[0021] Figure 3 This is a sequence diagram of a method for achieving fast device interconnection based on NFC according to an embodiment of the present invention;

[0022] Figure 4 This is an architecture diagram of a method for achieving fast device interconnection based on NFC, according to an embodiment of the present invention.

[0023] Label Explanation:

[0024] 1. A system for enabling rapid interconnection of devices based on NFC; 2. A first terminal; 3. A second terminal; 4. A first processor; 5. A first memory; 6. A second processor; 7. A second memory. Detailed Implementation

[0025] To explain in detail the technical content, objectives, and effects of the present invention, the following description is provided in conjunction with the embodiments and accompanying drawings.

[0026] Please refer to Figure 1 as well as Figure 3 A method for achieving fast device interconnection based on NFC, comprising the following steps:

[0027] S1. The first terminal obtains its own terminal information and, according to the application request, calls the native NFC interface to enable the NFC card reading function.

[0028] S2. The second terminal calls the native NFC interface to enable the NFC simulated card function;

[0029] S3. When the first terminal detects that the second terminal is approaching, it sends the terminal information to the second terminal.

[0030] S4. The second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0031] As can be seen from the above description, the beneficial effects of the present invention are as follows: When business needs are required, the present invention can quickly discover and select target devices through NFC, without requiring users to manually select target devices, which is more convenient. Moreover, it automatically selects the interconnection channel based on the data transmitted by NFC, realizing fast and seamless connection between devices. Business developers do not need to consider networking methods and physical protocols, which reduces business costs and has higher scalability.

[0032] Furthermore, both the first terminal and the second terminal are pre-configured with AID;

[0033] Step S3 specifically involves:

[0034] When the first terminal detects that the second terminal is approaching, it obtains the AID of the second terminal and compares it with its own AID. If they match, the first terminal sends the terminal information to the second terminal.

[0035] Step S4 specifically involves:

[0036] The second terminal detects the terminal information sent by the first terminal, obtains the AID of the first terminal and verifies it with its own AID. If they match, the second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0037] As described above, the terminal is pre-configured with AID to ensure the security of terminal interconnection and to prevent the terminal from accidentally connecting to other people's devices.

[0038] Furthermore, the terminal information includes the terminal's current Wi-Fi information, Bluetooth information, USB port information, and NFC information;

[0039] In step S4, selecting the interconnection channel based on the terminal information specifically involves:

[0040] Based on the current Wi-Fi, Bluetooth, USB port, and NFC information of the first terminal, the optimal interconnection channel is selected from the available interconnection channels according to a preset priority sequence.

[0041] As described above, the terminal can obtain all available interconnection channels between current devices and select the optimal interconnection channel for use, thus better meeting the user's preference for interconnection channel usage.

[0042] Furthermore, the priority sequence is as follows:

[0043] USB communication > Bluetooth networking > Wi-Fi P2P networking > Wi-Fi AP networking > NFC networking.

[0044] As described above, by prioritizing interconnection channels that offer more stable and efficient data transmission, the availability of interconnection channels and the data transmission efficiency of the channels are improved.

[0045] Furthermore, the following step is included after step S4:

[0046] S5. The second terminal determines whether the interconnection was successfully established. If the interconnection fails, it re-obtains the terminal information from the first terminal and executes step S4.

[0047] As described above, it is also necessary to determine whether the interconnection was successful. If the interconnection fails, the terminal information of the target terminal needs to be obtained again to confirm whether the connectable interconnection channel has changed. The interconnection channel should then be redefined to improve the efficiency of device interconnection.

[0048] Please refer to Figure 2 A system for rapid device interconnection based on NFC includes a first terminal and a second terminal. The first terminal includes a first processor, a first memory, and a first computer program stored in the first memory and executable on the first processor. The second terminal includes a second processor, a second memory, and a computer program stored in the second memory and executable on the second processor. When the first processor executes the first computer program, it performs the following steps:

[0049] S1. Obtain its own terminal information, and according to the application request, call the native NFC interface to enable the NFC card reading function;

[0050] S3. When the second terminal is detected to be approaching, the terminal information is sent to the second terminal;

[0051] When the second processor executes the second computer program, it performs the following steps:

[0052] S2. Call the native NFC interface to enable the NFC emulation card function;

[0053] S4. Receive the terminal information from the first terminal, select an interconnection channel based on the terminal information, and initiate an interconnection request to the first terminal to establish interconnection.

[0054] As can be seen from the above description, the beneficial effects of the present invention are as follows: When business needs arise, the present invention can quickly discover and select target devices through NFC, without requiring users to manually select target devices, which is more convenient. Furthermore, it automatically selects the interconnection channel based on the data transmitted by NFC, realizing fast and seamless connection between devices. Business developers do not need to consider networking methods and physical protocols, reducing business costs and providing higher scalability.

[0055] Furthermore, both the first terminal and the second terminal are pre-configured with AID;

[0056] Step S3 specifically involves:

[0057] When the second terminal is detected to be approaching, the AID of the second terminal is obtained and compared with its own AID. If they match, the terminal information is sent to the second terminal.

[0058] Step S4 specifically involves:

[0059] The system detects the terminal information sent by the first terminal, obtains the AID of the first terminal and verifies it with its own AID. If they match, the system receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0060] As described above, the terminal is pre-configured with AID to ensure the security of terminal interconnection and to prevent the terminal from accidentally connecting to other people's devices.

[0061] Furthermore, the terminal information includes the terminal's current Wi-Fi information, Bluetooth information, USB port information, and NFC information;

[0062] In step S4, selecting the interconnection channel based on the terminal information specifically involves:

[0063] Based on the current Wi-Fi, Bluetooth, USB port, and NFC information of the first terminal, the optimal interconnection channel is selected from the available interconnection channels according to a preset priority sequence.

[0064] As described above, the terminal can obtain all available interconnection channels between current devices and select the optimal interconnection channel for use, thus better meeting the user's preference for interconnection channel usage.

[0065] Furthermore, the priority sequence is as follows:

[0066] USB communication > Bluetooth networking > Wi-Fi P2P networking > Wi-Fi AP networking > NFC networking.

[0067] As described above, by prioritizing interconnection channels that offer more stable and efficient data transmission, the availability of interconnection channels and the data transmission efficiency of the channels are improved.

[0068] Furthermore, when the second processor executes the second computer program, the process further includes the following step after step S4:

[0069] S5. Determine whether the interconnection was successfully established. If the interconnection fails, re-obtain the terminal information from the first terminal and execute step S4.

[0070] As described above, it is also necessary to determine whether the interconnection was successful. If the interconnection fails, the terminal information of the target terminal needs to be obtained again to confirm whether the connectable interconnection channel has changed. The interconnection channel should then be redefined to improve the efficiency of device interconnection.

[0071] The present invention provides a method and system for achieving rapid interconnection of devices based on NFC, applicable to scenarios where two or more NFC-enabled terminals need to interconnect.

[0072] Please refer to Figure 1 , Figure 3 and Figure 4 Embodiment 1 of the present invention is as follows:

[0073] A method for achieving fast device interconnection based on NFC includes the following steps:

[0074] S1. The first terminal obtains its own terminal information and, according to the application request, calls the native NFC interface to enable the NFC card reading function.

[0075] The terminal information includes the terminal's current Wi-Fi information, Bluetooth information, USB port information, and NFC information.

[0076] In this embodiment, please refer to Figure 4 The relevant program resources in the terminal are divided into a user application layer, a self-organizing network adaptation layer, and a system layer. The user application layer is the user of device discovery and interconnection functions, deciding when to call interfaces to obtain a device list or establish device interconnection with a target terminal based on the application's own business needs. The system layer is the implementation module of the device system functions, executing the corresponding connection request after the self-organizing network adaptation layer completes the connection method decision and connection initiation; in this embodiment, it refers to the Android system layer. The self-organizing network adaptation layer provides interfaces for discovering devices and establishing device connections, allowing developers to quickly and easily access device interconnection; and completes the main functions of terminal discovery, network connection, and optimal connection method decision-making. The main content of this solution is implemented by the self-organizing network adaptation layer, i.e., the self-organizing network service.

[0077] In this embodiment, the self-organizing network service is started either when the user's application binds to the service or by listening for system boot broadcasts. In the first terminal, the user application layer calls the device discovery interface provided by the self-organizing network service according to business needs, waiting for the target device to be discovered. The self-organizing network service reads the terminal information of the first terminal, including the IP address and port of the Wi-Fi LAN, the Bluetooth address and port, USB port information, and NFC information, in preparation for transmission to the target terminal. Simultaneously, after receiving the call request from the user application layer, the self-organizing network service uses the Android native NFC interface to enable the NFC card reading function and waits for the target terminal to read the card.

[0078] S2. The second terminal calls the native NFC interface to enable the NFC simulated card function;

[0079] In this embodiment, the self-organizing network service of the second terminal uses the native NFC card emulation function of Android to simulate the second terminal as an NFC card.

[0080] S3. When the first terminal detects that the second terminal is approaching, it sends the terminal information to the second terminal.

[0081] Both the first terminal and the second terminal are pre-configured with AID;

[0082] Step S3 specifically involves:

[0083] When the first terminal detects that the second terminal is approaching, it obtains the AID of the second terminal and compares it with its own AID. If they match, the first terminal sends the terminal information to the second terminal.

[0084] In this embodiment, both the first and second terminals are pre-assigned AIDs. In this embodiment, an AID is configured by the user when the device is enabled. In other equivalent embodiments, the ID of the user logged into the device can be used as the AID, or other information used to identify the user's identity can be used as the AID, depending on the requirements. When the first terminal approaches the second terminal, the first terminal reads the second terminal simulating an NFC card. When the first terminal recognizes and senses the second terminal simulating an NFC card and obtains that the second terminal's AID is the pre-assigned AID, the first terminal sends its own IP address, port information, Bluetooth address, and other terminal information to the second terminal via NFC.

[0085] S4. The second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0086] Step S4 specifically involves:

[0087] The second terminal detects the terminal information sent by the first terminal, obtains the AID of the first terminal and verifies it with its own AID. If they match, the second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection.

[0088] In step S4, selecting the interconnection channel based on the terminal information specifically involves:

[0089] Based on the current Wi-Fi information, Bluetooth information, USB port information, and NFC information of the first terminal, the optimal interconnection channel is selected from the available interconnection channels according to a preset priority sequence;

[0090] The priority sequence is as follows:

[0091] USB communication > Bluetooth networking > Wi-Fi P2P networking > Wi-Fi AP networking > NFC networking.

[0092] In this embodiment, after receiving the terminal information sent by the first terminal via NFC, the second terminal verifies the AID of the first terminal. If the verification is successful, the second terminal receives the terminal information sent by the first terminal via NFC.

[0093] In this embodiment, the self-organizing network service of the second terminal determines the optimal connection channel based on the Wi-Fi information, Bluetooth information, USB port information and NFC information sent by the first terminal;

[0094] Based on the available networking methods for the first and second terminals, the priority is as follows:

[0095] USB communication -- Bluetooth networking -- Wi-Fi P2P networking -- Wi-Fi AP networking -- NFC networking;

[0096] NFC, as a traditional connection method for Android, is limited in terms of data transmission size and speed, and is often only used in scenarios such as payments and access control. Furthermore, it can lead to contention issues when used by multiple applications, making it difficult to use for general application data transmission scenarios. Therefore, it is considered the least desirable option for establishing interconnection channels.

[0097] S5. The second terminal determines whether the interconnection was successfully established. If the interconnection fails, it re-obtains the terminal information from the first terminal and executes step S4.

[0098] In this embodiment, when the second terminal discovers that the network topology it is using is unreachable and it cannot establish an interconnection with the first terminal, it will reacquire the terminal information of the first terminal and re-determine the optimal connection channel. Once the first terminal and the second terminal successfully form a network, a device interconnection channel is established, and the business interaction data required for subsequent applications can be transmitted through the established interaction channel.

[0099] Please refer to Figure 2 Embodiment two of the present invention is as follows:

[0100] A system 1 for fast device interconnection based on NFC includes a first terminal 2 and a second terminal 3. The first terminal 2 includes a first processor 4, a first memory 5, and a first computer program stored in the first memory 5 and executable on the first processor 4. The second terminal 3 includes a second processor 6, a second memory 7, and a computer program stored in the second memory 7 and executable on the second processor 6. When the first processor 4 executes the first computer program, it implements the steps performed by the first terminal 2 in the above embodiment 1. When the second processor 6 executes the second computer program, it implements the steps implemented by the second terminal 3 in the above embodiment 1.

[0101] The main principle of this invention is to use NFC to determine the terminal information that needs to be interconnected, and then select an available interconnection channel with its own device based on the obtained terminal information, thereby automatically selecting and connecting.

[0102] In summary, the present invention provides a method and system for rapid device interconnection based on NFC. When business needs require it, it can quickly discover and select target devices through NFC without requiring users to manually select target devices, making it more convenient. Furthermore, it automatically selects the interconnection channel based on the data transmitted by NFC, realizing fast and seamless connection between devices. Business developers do not need to consider networking methods and physical protocols, reducing business costs and offering higher scalability.

[0103] The above description is merely an embodiment of the present invention and does not limit the patent scope of the present invention. Any equivalent modifications made based on the content of the present invention specification and drawings, or direct or indirect applications in related technical fields, are similarly included within the patent protection scope of the present invention.

Claims

1. A method for achieving rapid device interconnection based on NFC, characterized in that, Including the following steps: S1. The first terminal obtains its own terminal information and, according to the application request, calls the native NFC interface to enable the NFC card reading function. S2. The second terminal calls the native NFC interface to enable the NFC simulated card function; S3. When the first terminal detects that the second terminal is approaching, it sends the terminal information to the second terminal. S4. The second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection. Both the first terminal and the second terminal are pre-configured with AID; Step S3 specifically involves: When the first terminal detects that the second terminal is approaching, it obtains the AID of the second terminal and compares it with its own AID. If they match, the first terminal sends the terminal information to the second terminal. Step S4 specifically involves: The second terminal detects the terminal information sent by the first terminal, obtains the AID of the first terminal and verifies it with its own AID. If they match, the second terminal receives the terminal information from the first terminal, selects an interconnection channel based on the terminal information, and initiates an interconnection request to the first terminal to establish an interconnection. The terminal information includes the terminal's current Wi-Fi information, Bluetooth information, USB port information, and NFC information; In step S4, selecting the interconnection channel based on the terminal information specifically involves: Based on the current Wi-Fi, Bluetooth, USB port, and NFC information of the first terminal, the optimal interconnection channel is selected from the available interconnection channels according to a preset priority sequence.

2. The method for achieving rapid device interconnection based on NFC according to claim 1, characterized in that, The priority sequence is as follows: USB communication > Bluetooth networking > Wi-Fi P2P networking > Wi-Fi AP networking > NFC networking.

3. The method for achieving rapid device interconnection based on NFC according to claim 1, characterized in that, The steps following step S4 include: S5. The second terminal determines whether the interconnection was successfully established. If the interconnection fails, it re-obtains the terminal information from the first terminal and executes step S4.

4. A system for rapid device interconnection based on NFC, comprising a first terminal and a second terminal, wherein the first terminal includes a first processor, a first memory, and a first computer program stored in the first memory and executable on the first processor, and the second terminal includes a second processor, a second memory, and a second computer program stored in the second memory and executable on the second processor, characterized in that, When the first processor executes the first computer program, it performs the following steps: S1. Obtain its own terminal information, and according to the application request, call the native NFC interface to enable the NFC card reading function; S3. When the second terminal is detected to be approaching, the terminal information is sent to the second terminal; When the second processor executes the second computer program, it performs the following steps: S2. Call the native NFC interface to enable the NFC emulation card function; S4. Receive the terminal information from the first terminal, select an interconnection channel based on the terminal information, and initiate an interconnection request to the first terminal to establish an interconnection; Both the first terminal and the second terminal are pre-configured with AID; Step S3 specifically involves: When the second terminal is detected to be approaching, the AID of the second terminal is obtained and compared with its own AID. If they match, the terminal information is sent to the second terminal. Step S4 specifically involves: If the terminal information sent by the first terminal is detected, the AID of the first terminal is obtained and compared with its own AID. If they match, the terminal information of the first terminal is received, an interconnection channel is selected according to the terminal information, and an interconnection request is initiated to the first terminal to establish an interconnection. The terminal information includes the terminal's current Wi-Fi information, Bluetooth information, USB port information, and NFC information; In step S4, selecting the interconnection channel based on the terminal information specifically involves: Based on the current Wi-Fi, Bluetooth, USB port, and NFC information of the first terminal, the optimal interconnection channel is selected from the available interconnection channels according to a preset priority sequence.

5. A system for rapid device interconnection based on NFC according to claim 4, characterized in that, The priority sequence is as follows: USB communication > Bluetooth networking > Wi-Fi P2P networking > Wi-Fi AP networking > NFC networking.

6. A system for rapid device interconnection based on NFC according to claim 4, characterized in that, The second processor, when executing the second computer program, further includes the following steps after step S4: S5. Determine whether the interconnection was successfully established. If the interconnection fails, obtain the terminal information from the first terminal again and execute step S4.

Citation Information

Patent Citations

  • Application program installation method and device, electronic equipment and storage medium

    CN112346751A