CN116980869B - NFC tag life cycle management method based on detection line state - Google Patents
NFC tag life cycle management method based on detection line state Download PDFInfo
- Publication number
- CN116980869B CN116980869B CN202310897116.9A CN202310897116A CN116980869B CN 116980869 B CN116980869 B CN 116980869B CN 202310897116 A CN202310897116 A CN 202310897116A CN 116980869 B CN116980869 B CN 116980869B
- Authority
- CN
- China
- Prior art keywords
- instruction code
- instruction
- state
- detection line
- data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000001514 detection method Methods 0.000 title claims abstract description 89
- 238000007726 management method Methods 0.000 title claims description 18
- 238000000034 method Methods 0.000 claims abstract description 36
- 238000012795 verification Methods 0.000 claims abstract description 22
- 238000012545 processing Methods 0.000 claims description 54
- 238000013500 data storage Methods 0.000 claims description 22
- 238000004891 communication Methods 0.000 claims description 15
- 230000000873 masking effect Effects 0.000 claims description 6
- 230000008569 process Effects 0.000 claims description 3
- 230000006870 function Effects 0.000 description 9
- 238000010586 diagram Methods 0.000 description 6
- 230000007246 mechanism Effects 0.000 description 3
- 230000002093 peripheral effect Effects 0.000 description 3
- 238000011837 external investigation Methods 0.000 description 2
- 230000007547 defect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000000802 evaporation-induced self-assembly Methods 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/80—Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Near-Field Transmission Systems (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
The embodiment of the invention relates to a method for managing a life cycle of an NFC tag based on a detection line state, which comprises the following steps: the NFC tag receives an instruction; extracting a life cycle stage and a cut-back password; and generating a detection line state; in the pre-release stage, whether the instruction code is a return incision command checking instruction code is identified, if yes, the return data is set as instruction code errors, otherwise, the instruction program is operated to obtain the return data; when the state of the detection line is open circuit in the post-release stage, identifying whether the instruction code is a shielding instruction code, if so, setting the return data as instruction code errors, otherwise, running the instruction program to obtain the return data; performing a back cut command verification at the post-release stage when the detection line state is communicated; after the verification is successful, the instruction program is operated to obtain return data; and sending back the return data to the NFC terminal. The invention can reduce the label rejection rate and improve the label multiplexing rate.
Description
Technical Field
The invention relates to the technical field of data processing, in particular to a method for managing life cycle of an NFC tag based on detection line state.
Background
The lifecycle stages of a Near Field Communication (NFC) tag include at least two stages, a pre-release stage and a post-release stage. The lifecycle management mode of the conventional NFC tag is: 1) In the pre-issue stage, no restriction is required to any instruction of the tag instruction set; 2) In the post-issue stage, certain instructions in the tag instruction set need to be masked, for example: instructions related to key loading, instructions related to lifecycle switching, etc.; 3) The lifecycle stage can be switched from the pre-release stage to the post-release stage only, and cannot be switched back from the post-release stage to the pre-release stage. The conventional life cycle management method has a problem that if missing or error of tag data is found to occur after entering the post-release stage, the problem tends to increase the rejection rate of the NFC tag and reduce the reuse rate of the NFC tag.
In addition, with the application and development of NFC tag technology, various new NFC tags are presented in recent years. One of them is the NFC label that can external investigation line, and this kind of novel NFC label can be to the intercommunication or the open circuit state of external investigation line discernment. How to improve the traditional NFC label life cycle management mode based on the novel function of the novel NFC label so as to achieve the purposes of reducing the label rejection rate and improving the label multiplexing rate is the technical problem to be solved by the invention.
Disclosure of Invention
The invention aims at overcoming the defects of the prior art and provides a method, electronic equipment and a computer readable storage medium for managing the life cycle of an NFC tag based on the state of a detection line; NFC label based on external detection line can provide the function characteristic of detecting two kinds of connected state (intercommunication state, disconnection state) of line and improve traditional NFC label life cycle management mode into: 1) When the life cycle is in the pre-release stage, no limitation is required to any instruction in the label instruction set (without a return cut command checking instruction) no matter whether the detection line is in a connected state or an open state; 2) When the life cycle is in the post-release stage, shielding some specific instructions (including a return cut command checking instruction) in the tag instruction set based on a preset shielding instruction code set if the detection line is in an open circuit state; 3) When the life cycle is in the post-release stage, if the detection line is in the connected state, after the user successfully completes the verification of the life cycle back-cut command, the tag is switched back to the state similar to the pre-release stage, but the life cycle stage data preset in the local data storage area is not changed substantially, and any command in the tag command set (including the back-cut command verification command) is not limited as long as the detection line is not pulled out of the connecting slot of the NFC tag. The invention provides a processing mechanism for temporarily cutting back the life cycle through the external detection line and the life cycle cut-back on the basis of being compatible with the traditional NFC label life cycle management mode, so that the NFC label with data missing or false issuing can be remedied even in the post-issuing stage; the invention can achieve the purposes of reducing the rejection rate of the labels and improving the reuse rate of the labels.
To achieve the above object, a first aspect of the present invention provides a method for performing lifecycle management by an NFC tag based on a detected line state, where the method includes:
the NFC tag receives a first instruction sent by an NFC terminal; the first instruction comprises a first instruction code and a first instruction parameter; the NFC tag comprises a first detection line connecting groove and a second detection line connecting groove;
Extracting life cycle stage data and life cycle back cut command data preset in a local data storage area to serve as corresponding first stage and first back cut commands; and performing detection line state identification processing according to the first detection line connecting groove and the second detection line connecting groove to generate a corresponding first state; the first stage includes a pre-release stage and a post-release stage; the first state comprises a connected state and an disconnected state;
When the first stage is a pre-release stage, setting check state data as check failure by a back notch preset in a local data storage area; identifying whether the first instruction code is a preset back cut command checking instruction code; if yes, setting the corresponding first return data to be in a preset instruction code error return state; if not, executing an instruction program according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
When the first stage is a post-release stage and the first state is an open state, setting the back cut command verification state data to be verification failure; performing shielding instruction code identification processing on the first instruction code according to a preset shielding instruction code set to obtain a corresponding first identification result; if the first identification result is yes, setting the corresponding first return data as the instruction code error return state; if the first identification result is negative, performing instruction program operation according to the first instruction code and the first instruction parameter to obtain corresponding first return data; the shielding instruction code set comprises a plurality of first shielding instruction codes, wherein one first shielding instruction code is the back cut command checking instruction code;
When the first stage is a post-release stage and the first state is a communication state, identifying whether the first instruction code is the back cut command checking instruction code; if the first instruction code is the check instruction code of the back incision command, identifying whether the first instruction parameter is matched with the first back incision command, if so, setting the check state data of the back incision command to pass the check, and if not, setting the check state data of the back incision command to fail the check; if the first instruction code is not the back cut command verification instruction code, identifying whether the back cut command verification state data is verification failure or not, if so, setting the corresponding first return data as the error return state of the instruction code, and if not, executing an instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data;
And sending the obtained first return data back to the NFC terminal.
Preferably, the first and second detecting line connecting grooves of the NFC tag are used for connecting two ends of a detecting line, and the detecting line is a conductive connecting line; the connecting wire material of the detection line is a low-resistance material; when two ends of the detecting line are respectively inserted into the first detecting line connecting groove and the second detecting line connecting groove, the NFC tag and the detecting line form a loop, and the absolute potential difference between the first detecting line connecting groove and the second detecting line connecting groove is reduced.
Preferably, the detecting line state identifying process according to the first detecting line connecting slot and the second detecting line connecting slot generates a corresponding first state, which specifically includes:
Taking the absolute potential difference between the first detection line connecting groove and the second detection line connecting groove as a corresponding first potential difference; and identifying whether the first potential difference is below a preset open-circuit potential difference threshold; if yes, setting the corresponding first state as a communication state; if not, the corresponding first state is set to be an off state.
Preferably, the executing the instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data specifically includes:
Taking an instruction processing flow corresponding to the first instruction code in the built-in operating system as a corresponding first processing flow; inputting the first instruction parameters into the first processing flow for processing; and taking the return data of the first processing flow as the corresponding first return data.
Preferably, the step of performing the masking instruction code recognition processing on the first instruction code according to the preset masking instruction code set to obtain a corresponding first recognition result specifically includes:
Traversing all the first mask instruction codes of the mask instruction code set; and traversing, wherein the first shielding instruction code traversed currently is used as a corresponding current instruction code; identifying whether the first instruction code is matched with the current instruction code or not; if the first instruction code is matched with the current instruction code, setting the corresponding first identification result as yes, and ending traversal; if the first instruction code is not matched with the current instruction code, setting a corresponding first identification result as no, identifying whether the current instruction code is the last first shielding instruction, if not, turning to the next first shielding instruction to continue traversing, and if so, ending traversing;
and outputting the first recognition result obtained finally as the current processing result when the traversal is finished.
Preferably, the method further comprises:
When the check state data of the NFC tag passes through the check through the back cut in the local data storage area, the NFC tag continuously performs detection line state identification processing according to the first detection line connecting groove and the second detection line connecting groove to generate a corresponding first state; and setting the check state data to be failed in check by the back notch in the local data storage area once the latest obtained first state is changed into an open state.
A second aspect of an embodiment of the present invention provides an electronic device, including: memory, processor, and transceiver;
The processor is configured to couple to the memory, and read and execute the instructions in the memory, so as to implement the method steps described in the first aspect;
The transceiver is coupled to the processor and is controlled by the processor to transmit and receive messages.
A third aspect of the embodiments of the present invention provides a computer-readable storage medium storing computer instructions that, when executed by a computer, cause the computer to perform the method of the first aspect described above.
The embodiment of the invention provides a method, electronic equipment and a computer readable storage medium for managing a life cycle of an NFC tag based on a detection line state; NFC label based on external detection line can provide the function characteristic of detecting two kinds of connected state (intercommunication state, disconnection state) of line and improve traditional NFC label life cycle management mode into: 1) When the life cycle is in the pre-release stage, no limitation is required to any instruction in the label instruction set (without a return cut command checking instruction) no matter whether the detection line is in a connected state or an open state; 2) When the life cycle is in the post-release stage, shielding some specific instructions (including a return cut command checking instruction) in the tag instruction set based on a preset shielding instruction code set if the detection line is in an open circuit state; 3) When the life cycle is in the post-release stage, if the detection line is in the connected state, after the user successfully completes the verification of the life cycle back-cut command, the tag is switched back to the state similar to the pre-release stage, but the life cycle stage data preset in the local data storage area is not changed substantially, and any command in the tag command set (including the back-cut command verification command) is not limited as long as the detection line is not pulled out of the connecting slot of the NFC tag. The invention provides a processing mechanism for temporarily cutting back the life cycle through the external detection line and the life cycle cut-back on the basis of being compatible with the traditional NFC label life cycle management mode, so that the NFC label with data missing or false issuing can be remedied even in the post-issuing stage; the invention reduces the rejection rate of the labels and improves the reuse rate of the labels.
Drawings
Fig. 1 is a schematic diagram of a method for managing a lifecycle of an NFC tag according to a first embodiment of the present invention;
Fig. 2 is a schematic diagram illustrating connection between an NFC tag and a detection line according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of an electronic device according to a second embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail below with reference to the accompanying drawings, and it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
An embodiment of the present invention provides a method for performing lifecycle management by an NFC tag based on a detection line state, as shown in fig. 1, which is a schematic diagram of a method for performing lifecycle management by an NFC tag based on a detection line state according to the first embodiment of the present invention, the method mainly includes the following steps:
Step 1, an NFC tag receives a first instruction sent by an NFC terminal;
The first instruction comprises a first instruction code and a first instruction parameter; the NFC tag comprises a first detection line connecting groove and a second detection line connecting groove; the first detection line connecting groove and the second detection line connecting groove of the NFC label are used for connecting two ends of the detection line, and the detection line is a conductive connecting line; the connecting wire material of the detection line is selected from low-resistance materials; when two ends of the detection line are respectively inserted into the first detection line connecting slot and the second detection line connecting slot, the NFC tag and the detection line form a loop, and the absolute potential difference between the first detection line connecting slot and the second detection line connecting slot is reduced.
Here, the manner of the NFC tag and the sensing line according to the embodiment of the present invention is shown in fig. 2, which is a schematic diagram illustrating connection between the NFC tag and the sensing line according to the first embodiment of the present invention; the NFC terminal in the embodiment of the invention is a module, a device, equipment and a server which can enable the NFC tag to be powered on to perform working state based on the NFC communication protocol and enable the NFC tag to perform instruction-return data interaction based on the NFC communication protocol and enter the working state, such as a mobile phone with an NFC function, an NFC card reader and the like.
Step2, extracting the preset life cycle stage data and life cycle back cut command data in the local data storage area to serve as corresponding first stage and first back cut commands; and performing detection line state identification processing according to the first detection line connecting slot and the second detection line connecting slot to generate a corresponding first state;
the method specifically comprises the following steps: step 21, extracting the preset life cycle stage data and life cycle back cut command data in the local data storage area as corresponding first stage and first back cut commands;
wherein the first stage comprises a pre-release stage and a post-release stage;
Here, two necessary data are preset in the local data storage area of the NFC tag according to the embodiment of the present invention: lifecycle stage data, lifecycle loop cut order data; the life cycle stage data is used for storing the current life cycle stage information of the tag, and the life cycle stage information has two values: a pre-release stage and a post-release stage; the life cycle back cut order data is used for storing the life cycle back cut order of the current label;
Step 22, performing detection line state identification processing according to the first detection line connecting slot and the second detection line connecting slot to generate a corresponding first state;
wherein the first state includes a connected state and an disconnected state;
The method specifically comprises the following steps: taking the absolute potential difference between the first detection line connecting groove and the second detection line connecting groove as a corresponding first potential difference; and identifying whether the first potential difference is below a preset open-circuit potential difference threshold; if yes, setting the corresponding first state as a communication state; if not, the corresponding first state is set to be the disconnection state.
Here, the threshold value of the open-circuit potential difference according to the embodiment of the present invention is a preset voltage threshold value.
Step 3, when the first stage is the pre-release stage, setting the check state data of a preset back cut in the local data storage area as check failure; identifying whether the first instruction code is a preset back cut command checking instruction code; if yes, setting the corresponding first return data to be in a preset instruction code error return state; if not, executing the instruction program according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
The method specifically comprises the following steps: step 31, when the first stage is the pre-release stage, setting the check state data of the preset back cut in the local data storage area to be failed in check;
Here, a necessary data is also preset in the local data storage area of the NFC tag according to the embodiment of the present invention: checking state data by a back incision command, wherein the back incision command checking state data stores a verification result of a life cycle back incision command; the embodiment of the invention provides that if the life cycle of the label is in the pre-release stage, namely the first stage is the pre-release stage, the check state data of the back cut command is not referred to, so the check state data of the back cut command is always kept as check failure;
Step 32, identifying whether the first instruction code is a preset back cut command checking instruction code; if yes, setting the corresponding first return data to be in a preset instruction code error return state; if not, executing the instruction program according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
The method comprises the steps of executing an instruction program according to a first instruction code and a first instruction parameter to obtain corresponding first return data, wherein the first return data specifically comprises the following steps: taking an instruction processing flow corresponding to the first instruction code in the built-in operating system as a corresponding first processing flow; inputting the first instruction parameters into a first processing flow for processing; and taking the return data of the first processing flow as corresponding first return data; here, similar to the conventional NFC tag, the NFC tag according to the embodiment of the present invention also has a built-in operating system, where the built-in operating system has an instruction processing flow corresponding to each tag instruction, where the instruction processing flow has a parameter transferring and data returning function, and where the instruction processing flow may be a system function, a system interface, an executable script, or an executable program.
Here, the embodiment of the present invention provides that the tag instruction corresponding to the back-cut order check instruction code is not responded when the life cycle of the tag is in the pre-issue stage, so that the instruction code error state is returned when the first instruction code=the back-cut order check instruction code; in addition, similar to conventional lifecycle management, there is no restriction on any other instruction in the tag instruction set than the cut-back instruction.
Step 4, when the first stage is the post-release stage and the first state is the open state, setting the check state data of the back cut command as check failure; performing shielding instruction code identification processing on the first instruction codes according to a preset shielding instruction code set to obtain corresponding first identification results; if the first identification result is yes, setting the corresponding first return data as an instruction code error return state; if the first identification result is negative, performing instruction program operation according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
The method specifically comprises the following steps: step 41, when the first stage is the post-release stage and the first state is the open state, setting the check state data of the back cut to be check failure;
Here, the embodiment of the present invention provides that if the life cycle of the tag is in the post-issuance stage but the external detection line is not connected, that is, the first stage is the post-issuance stage and the first state is the off state, the check state data of the back-cut command is not referred to, so that the check state data of the back-cut command is always kept as the check failure;
step 42, performing shielding instruction code identification processing on the first instruction code according to a preset shielding instruction code set to obtain a corresponding first identification result;
The shielding instruction code set comprises a plurality of first shielding instruction codes, wherein one first shielding instruction code is a back-cut command checking instruction code;
here, the masking instruction codes given in the masking instruction code set in the embodiment of the present invention should include the instruction code of the back-cut instruction verification instruction, i.e., the back-cut instruction verification instruction code, in addition to the instruction code of the specified instruction (such as the instruction related to the key loading, the instruction related to the lifecycle switching, etc.) that needs to be masked conventionally;
The method specifically comprises the following steps: step 421, traversing all first mask instruction codes of the mask instruction code set; the first shielding instruction code of the current traversal is used as the corresponding current instruction code in the traversal; identifying whether the first instruction code is matched with the current instruction code or not; if the first instruction code is matched with the current instruction code, setting the corresponding first identification result as yes, and ending the traversal; if the first instruction code is not matched with the current instruction code, setting a corresponding first identification result as no, identifying whether the current instruction code is the last first shielding instruction, if not, turning to the next first shielding instruction to continue traversing, and if so, ending traversing;
Step 422, when the traversal is finished, outputting the finally obtained first recognition result as the current processing result;
Step 43, if the first recognition result is yes, setting the corresponding first return data to be an instruction code error return state; if the first identification result is negative, performing instruction program operation according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
Here, similar to step 32, the execution of the instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data is specifically: taking an instruction processing flow corresponding to the first instruction code in the built-in operating system as a corresponding first processing flow; inputting the first instruction parameters into a first processing flow for processing; and the return data of the first processing flow is used as corresponding first return data.
Step 5, when the first stage is the post-release stage and the first state is the communication state, identifying whether the first instruction code is a back cut command checking instruction code; if the first instruction code is a check instruction code of the back cut command, identifying whether the first instruction parameter is matched with the first back cut command, if so, setting the check state data of the back cut command to pass the check, and if not, setting the check state data of the back cut command to fail the check; if the first instruction code is not the return cut command checking instruction code, identifying whether the return cut command checking state data is checking failure or not, if so, setting the corresponding first return data as an instruction code error return state, and if not, executing an instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data;
The method specifically comprises the following steps: step 51, when the first stage is the post-issue stage and the first state is the connected state, identifying whether the first instruction code is a back cut command check instruction code;
Step 52, if the first instruction code is the check instruction code of the back-cut command, identifying whether the first instruction parameter is matched with the first back-cut command, if so, setting the check state data of the back-cut command to pass the check, and if not, setting the check state data of the back-cut command to fail the check;
It should be noted that, when the check state data is checked by the back cut of the NFC tag in the local data storage area, the first state is generated continuously by performing the detection line state identification processing according to the first and second detection line connection slots; immediately setting check state data to be failed in check by a back cut in a local data storage area once the latest obtained first state is changed into an open circuit state;
Step 53, if the first instruction code is not the loop-cut instruction checking instruction code, identifying whether the loop-cut instruction checking status data is a checking failure, if so, setting the corresponding first return data as an instruction code error return status, and if not, performing instruction program operation according to the first instruction code and the first instruction parameter to obtain the corresponding first return data;
Here, similar to step 32, the execution of the instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data is specifically: taking an instruction processing flow corresponding to the first instruction code in the built-in operating system as a corresponding first processing flow; inputting the first instruction parameters into a first processing flow for processing; and the return data of the first processing flow is used as corresponding first return data.
As can be seen from the above steps 51-53, in the embodiment of the present invention, when the life cycle of the tag is in the post-issuance stage and the external detection line is connected, i.e. the first stage is the post-issuance stage and the first state is the connected state, the tag is switched back to the state similar to the pre-issuance stage, but the life cycle back-cut command verification needs to be successfully completed before the back-cut, and the life cycle stage data preset in the local data storage area is not substantially changed, so long as the detection line is not pulled out from the connection slot of the NFC tag, the tag is similar to the pre-issuance stage and any instruction in the tag instruction set is not limited.
And 6, sending the obtained first return data back to the NFC terminal.
Fig. 3 is a schematic structural diagram of an electronic device according to a second embodiment of the present invention. The electronic device may be a terminal device or a server for implementing the method of the embodiment of the present invention, or may be a terminal device or a server for implementing the method of the embodiment of the present invention, which is connected to the foregoing terminal device or server. As shown in fig. 3, the electronic device may include: a processor 301 (e.g., a CPU), a memory 302, a transceiver 303; the transceiver 303 is coupled to the processor 301, and the processor 301 controls the transceiving actions of the transceiver 303. The memory 302 may store various instructions for performing the various processing functions and implementing the processing steps described in the method embodiments previously described. Preferably, the electronic device according to the embodiment of the present invention further includes: a power supply 304, a system bus 305, and a communication port 306. The system bus 305 is used to implement communication connections between the elements. The communication port 306 is used for connection communication between the electronic device and other peripheral devices.
The system bus 305 referred to in fig. 3 may be a peripheral component interconnect standard (PERIPHERAL COMPONENT INTERCONNECT, PCI) bus, or an extended industry standard architecture (Extended Industry Standard Architecture, EISA) bus, or the like. The system bus may be classified into an address bus, a data bus, a control bus, and the like. For ease of illustration, the figures are shown with only one bold line, but not with only one bus or one type of bus. The communication interface is used to enable communication between the database access apparatus and other devices (e.g., clients, read-write libraries, and read-only libraries). The Memory may include random access Memory (Random Access Memory, RAM) and may also include Non-Volatile Memory (Non-Volatile Memory), such as at least one disk Memory.
The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU), a network processor (Network Processor, NP), a graphics processor (Graphics Processing Unit, GPU), etc.; but may also be a digital signal Processor (DIGITAL SIGNAL Processor, DSP), application SPECIFIC INTEGRATED Circuit (ASIC), field programmable gate array (Field Programmable GATE ARRAY, FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components.
It should be noted that, the embodiments of the present invention also provide a computer readable storage medium, where instructions are stored, when the computer readable storage medium runs on a computer, to cause the computer to perform the method and the process provided in the above embodiments.
The embodiment of the invention also provides a chip for running the instructions, and the chip is used for executing the processing steps described in the embodiment of the method.
The embodiment of the invention provides a method, electronic equipment and a computer readable storage medium for managing a life cycle of an NFC tag based on a detection line state; NFC label based on external detection line can provide the function characteristic of detecting two kinds of connected state (intercommunication state, disconnection state) of line and improve traditional NFC label life cycle management mode into: 1) When the life cycle is in the pre-release stage, no limitation is required to any instruction in the label instruction set (without a return cut command checking instruction) no matter whether the detection line is in a connected state or an open state; 2) When the life cycle is in the post-release stage, shielding some specific instructions (including a return cut command checking instruction) in the tag instruction set based on a preset shielding instruction code set if the detection line is in an open circuit state; 3) When the life cycle is in the post-release stage, if the detection line is in the connected state, after the user successfully completes the verification of the life cycle back-cut command, the tag is switched back to the state similar to the pre-release stage, but the life cycle stage data preset in the local data storage area is not changed substantially, and any command in the tag command set (including the back-cut command verification command) is not limited as long as the detection line is not pulled out of the connecting slot of the NFC tag. The invention provides a processing mechanism for temporarily cutting back the life cycle through the external detection line and the life cycle cut-back on the basis of being compatible with the traditional NFC label life cycle management mode, so that the NFC label with data missing or false issuing can be remedied even in the post-issuing stage; the invention reduces the rejection rate of the labels and improves the reuse rate of the labels.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative elements and steps are described above generally in terms of function in order to clearly illustrate the interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied in hardware, in a software module executed by a processor, or in a combination of the two. The software modules may be disposed in Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The foregoing description of the embodiments has been provided for the purpose of illustrating the general principles of the invention, and is not meant to limit the scope of the invention, but to limit the invention to the particular embodiments, and any modifications, equivalents, improvements, etc. that fall within the spirit and principles of the invention are intended to be included within the scope of the invention.
Claims (4)
1. A method for managing a lifecycle of an NFC tag based on a sensing line state, the method comprising:
the NFC tag receives a first instruction sent by an NFC terminal; the first instruction comprises a first instruction code and a first instruction parameter; the NFC tag comprises a first detection line connecting groove and a second detection line connecting groove;
Extracting life cycle stage data and life cycle back cut command data preset in a local data storage area to serve as corresponding first stage and first back cut commands; and performing detection line state identification processing according to the first detection line connecting groove and the second detection line connecting groove to generate a corresponding first state; the first stage includes a pre-release stage and a post-release stage; the first state comprises a connected state and an disconnected state; the local data storage area is a data storage area of an NFC tag;
When the first stage is a pre-release stage, setting check state data to be failed in check by a back notch preset in the local data storage area; identifying whether the first instruction code is a preset back cut command checking instruction code; if yes, setting the corresponding first return data to be in a preset instruction code error return state; if not, executing an instruction program according to the first instruction code and the first instruction parameter to obtain corresponding first return data;
When the first stage is a post-release stage and the first state is an open state, setting the back cut command verification state data to be verification failure; performing shielding instruction code identification processing on the first instruction code according to a preset shielding instruction code set to obtain a corresponding first identification result; if the first identification result is yes, setting the corresponding first return data as the instruction code error return state; if the first identification result is negative, performing instruction program operation according to the first instruction code and the first instruction parameter to obtain corresponding first return data; the shielding instruction code set comprises a plurality of first shielding instruction codes, wherein one first shielding instruction code is the back cut command checking instruction code;
When the first stage is a post-release stage and the first state is a communication state, identifying whether the first instruction code is the back cut command checking instruction code; if the first instruction code is the check instruction code of the back incision command, identifying whether the first instruction parameter is matched with the first back incision command, if so, setting the check state data of the back incision command to pass the check, and if not, setting the check state data of the back incision command to fail the check; if the first instruction code is not the back cut command verification instruction code, identifying whether the back cut command verification state data is verification failure or not, if so, setting the corresponding first return data as the error return state of the instruction code, and if not, executing an instruction program according to the first instruction code and the first instruction parameter to obtain the corresponding first return data;
The obtained first return data is returned to the NFC terminal;
The first detection line connecting groove and the second detection line connecting groove of the NFC tag are used for connecting two ends of a detection line, and the detection line is a conductive connecting line; the connecting wire material of the detection line is a low-resistance material; when two ends of the detection line are respectively inserted into the first detection line connecting groove and the second detection line connecting groove, the NFC tag and the detection line form a loop, and the absolute potential difference between the first detection line connecting groove and the second detection line connecting groove is reduced;
The detecting line state identifying process is performed according to the first detecting line connecting slot and the second detecting line connecting slot to generate a corresponding first state, and the method specifically comprises the following steps:
Taking the absolute potential difference between the first detection line connecting groove and the second detection line connecting groove as a corresponding first potential difference; and identifying whether the first potential difference is below a preset open-circuit potential difference threshold; if yes, setting the corresponding first state as a communication state; if not, the corresponding first state is set to be an off state.
2. The method for lifecycle management by an NFC tag according to claim 1, wherein the executing an instruction program according to the first instruction code and the first instruction parameter obtains the corresponding first return data, and specifically includes:
Taking an instruction processing flow corresponding to the first instruction code in the built-in operating system as a corresponding first processing flow; inputting the first instruction parameters into the first processing flow for processing; and taking the return data of the first processing flow as the corresponding first return data.
3. The method for performing lifecycle management by using an NFC tag according to claim 1, wherein the performing, according to a preset masking instruction code set, masking instruction code recognition processing on the first instruction code to obtain a corresponding first recognition result specifically includes:
Traversing all the first mask instruction codes of the mask instruction code set; and traversing, wherein the first shielding instruction code traversed currently is used as a corresponding current instruction code; identifying whether the first instruction code is matched with the current instruction code or not; if the first instruction code is matched with the current instruction code, setting the corresponding first identification result as yes, and ending traversal; if the first instruction code is not matched with the current instruction code, setting a corresponding first identification result as no, identifying whether the current instruction code is the last first shielding instruction, if not, turning to the next first shielding instruction to continue traversing, and if so, ending traversing;
and outputting the first recognition result obtained finally as the current processing result when the traversal is finished.
4. The method of lifecycle management of NFC tags based on a sniffer line state of claim 1, further comprising:
When the check state data of the NFC tag pass through the check through the back cut in the local data storage area, the NFC tag continuously performs detection line state identification processing according to the first detection line connecting groove and the second detection line connecting groove to generate a corresponding first state; and setting the check state data to be failed in check by the back notch in the local data storage area once the latest obtained first state is changed into an open state.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310897116.9A CN116980869B (en) | 2023-07-20 | 2023-07-20 | NFC tag life cycle management method based on detection line state |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310897116.9A CN116980869B (en) | 2023-07-20 | 2023-07-20 | NFC tag life cycle management method based on detection line state |
Publications (2)
Publication Number | Publication Date |
---|---|
CN116980869A CN116980869A (en) | 2023-10-31 |
CN116980869B true CN116980869B (en) | 2024-04-23 |
Family
ID=88477677
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310897116.9A Active CN116980869B (en) | 2023-07-20 | 2023-07-20 | NFC tag life cycle management method based on detection line state |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116980869B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2016190717A1 (en) * | 2015-05-27 | 2016-12-01 | 주식회사 신흥정밀 | Method and computer program for using dual-interface nfc tag |
CN113329379A (en) * | 2020-02-29 | 2021-08-31 | 华为技术有限公司 | Communication method, device and system based on NFC |
CN113852637A (en) * | 2021-09-28 | 2021-12-28 | 全球能源互联网研究院有限公司 | Weak password detection method and device and electronic equipment |
CN216748782U (en) * | 2022-01-24 | 2022-06-14 | 芯电智联(北京)科技有限公司 | NFC label |
CN114640976A (en) * | 2020-11-30 | 2022-06-17 | 华为技术有限公司 | NFC tag verification method and related equipment |
CN115633338A (en) * | 2022-08-18 | 2023-01-20 | 芯电智联(北京)科技有限公司 | Data updating processing method of NFC label |
-
2023
- 2023-07-20 CN CN202310897116.9A patent/CN116980869B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2016190717A1 (en) * | 2015-05-27 | 2016-12-01 | 주식회사 신흥정밀 | Method and computer program for using dual-interface nfc tag |
CN113329379A (en) * | 2020-02-29 | 2021-08-31 | 华为技术有限公司 | Communication method, device and system based on NFC |
CN114640976A (en) * | 2020-11-30 | 2022-06-17 | 华为技术有限公司 | NFC tag verification method and related equipment |
CN113852637A (en) * | 2021-09-28 | 2021-12-28 | 全球能源互联网研究院有限公司 | Weak password detection method and device and electronic equipment |
CN216748782U (en) * | 2022-01-24 | 2022-06-14 | 芯电智联(北京)科技有限公司 | NFC label |
CN115633338A (en) * | 2022-08-18 | 2023-01-20 | 芯电智联(北京)科技有限公司 | Data updating processing method of NFC label |
Also Published As
Publication number | Publication date |
---|---|
CN116980869A (en) | 2023-10-31 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108427731B (en) | Page code processing method and device, terminal equipment and medium | |
CN113946546B (en) | Abnormality detection method, computer storage medium, and program product | |
CN114003538A (en) | Intelligent network card and identification method thereof | |
CN112996020A (en) | Bluetooth-based automatic testing method and device and Bluetooth testing terminal | |
CN111831365A (en) | Interface route forwarding method, system, computer equipment and readable storage medium | |
CN114661423A (en) | Cluster configuration detection method and device, computer equipment and storage medium | |
CN114327484A (en) | Multi-architecture supporting K8S integration and deployment method, system and storage medium | |
CN116980869B (en) | NFC tag life cycle management method based on detection line state | |
CN112732427B (en) | Data processing method, system and related device based on Redis cluster | |
CN109560964B (en) | Equipment compliance checking method and device | |
CN115904317A (en) | Method, device, equipment and storage medium for uniformly calling front-end interface and back-end interface | |
CN112286780A (en) | Method, device and equipment for testing recognition algorithm and storage medium | |
CN115858345A (en) | Application service module verification method and device, electronic equipment and storage medium | |
CN113852610B (en) | Message processing method, device, computer equipment and storage medium | |
CN115543755A (en) | Performance monitoring method, device, system, equipment and medium | |
CN112787886B (en) | Processing method, device driver, readable storage medium and computer for real-time system network device auto-negotiation | |
CN115061921A (en) | Automatic test method, device, electronic equipment and readable storage medium | |
CN112822666B (en) | Communication method, communication device, electronic equipment and storage medium | |
CN115062313A (en) | Intelligent contract vulnerability detection method, device, equipment and storage medium | |
US10877870B2 (en) | Method and system for verifying properties of source code | |
CN115858256A (en) | Test method and device for Internet of things equipment and electronic equipment | |
CN114185318A (en) | Production line information processing method and system based on artificial intelligence | |
CN108509478B (en) | Splitting and calling method of rule engine file, electronic device and storage medium | |
CN112579376B (en) | Double-running-stage data verification method, system, equipment and storage medium | |
CN113868030B (en) | CPU test tool self-adaptive matching method, system, terminal and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |