A method, circuit, and device for energy harvesting and sensorless motor control based on an NFC single antenna.

CN122844485APending Publication Date: 2026-09-29SHENZHEN ZHICHENG KELAIDI SCI & TECH LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611334444.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-31
Publication Date
2026-09-29

AI Technical Summary

Technical Problem

[0006]本发明的目的在于提供一种基于NFC单天线的能量采集与电机无传感器控制方法、电路及设备,以解决现有技术中通信稳定性与储能效率、MCU供电与电容充电、无传感器检测精度与计算资源的三重技术矛盾

Benefits of technology

1、供电能力显著提升:通过分流技术及单天线设计,为MCU提供超过3mA的工作电流,相比传统方案的1.5mA提升一倍以上,使系统可选型32位单片机,资源极大提升,支持AES等高强度加密算法,显著增强安全性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122844485A_ABST
    Figure CN122844485A_ABST
Patent Text Reader

Abstract

This invention discloses a sensorless motor control and energy harvesting method based on an NFC single-antenna, belonging to the field of near-field communication energy harvesting and motor control technology. A single-antenna coil simultaneously receives NFC radio frequency energy and communication signals, and a rectifier-shunt circuit provides a suitable operating current to the MCU. A DC blocking capacitor is connected in series between the coil and the TAG chip to block the internal DC overvoltage clamping path, enabling boost charging of the energy storage capacitor. A MOSFET controls the charging priority, ensuring stable power supply to the MCU. The MCU collects the motor current at fixed intervals, and the resistance waveform is restored through hardware and software collaborative filtering. This waveform is then compared with a pre-stored standard model to achieve sensorless position detection. This invention solves the triple technical contradictions in NFC single-antenna systems: communication and energy storage, MCU power supply and capacitor charging, and sensorless detection accuracy and computing resources. It is applicable to scenarios such as smart locks, shared equipment cabinets, and IoT terminals. This invention also discloses circuits and devices based on this method.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of near-field communication energy harvesting and motor control technology, and in particular to a method, circuit, and device for energy harvesting and sensorless motor control based on an NFC single antenna. Background Technology

[0002] In the field of NFC near-field communication energy harvesting technology, such as NFC passive locks, the single-antenna architecture, which simultaneously undertakes radio frequency communication and energy transmission functions, faces the following technical challenges: 1. Insufficient Power Supply: In existing passive power supply technologies for NFC, traditional solutions obtain power from the TAG chip (tag chip), which simultaneously powers both the TAG chip itself and the MCU (controller unit). Limited by the power supply capacity of the TAG chip, the current it can provide is typically less than 1.5mA, severely restricting the selection range of MCUs. Generally, only 8-bit microcontrollers with an operating current of less than 1mA can be selected. These microcontrollers have extremely small Flash storage capacity, making them unable to run high-strength encryption algorithms such as AES, resulting in poor security.

[0003] 2. Dual-antenna interference problem. To address the insufficient power supply issue, some solutions employ a dual-antenna design, consisting of a communication coil and a charging coil. However, the communication coil can be interfered with by the charging coil, causing unstable communication; simultaneously, the charging coil can also be interfered with by the communication coil, resulting in energy loss during charging and overall low efficiency.

[0004] 3. Single-antenna clamping voltage limitation. Although the single-coil design can avoid interference from dual antennas, the TAG chip itself has a DC overvoltage clamping function with a clamping voltage of 4V, which prevents the capacitor charging voltage from being boosted, resulting in low energy storage efficiency.

[0005] 4. Crude Motor Control. Due to limited microcontroller resources, the MCU's motor control method is rather crude, basically only using timed opening and closing of the motor. Some solutions don't even perform rotation processing because of insufficient capacitor energy storage. This makes it impossible to accurately determine the motor's stopping position, affecting the reliability and security of the lock. Summary of the Invention

[0006] The purpose of this invention is to provide a method, circuit, and device for energy harvesting and sensorless motor control based on an NFC single antenna, so as to solve the triple technical contradictions in the prior art: communication stability and energy storage efficiency, MCU power supply and capacitor charging, and sensorless detection accuracy and computing resources.

[0007] As a first aspect of the present invention, the present invention provides the following technical solution: a method for energy harvesting and sensorless motor control based on an NFC single antenna, comprising a single antenna coil, an MCU, an NFC TAG chip, a DC blocking capacitor, an energy storage element, a motor unit, and a motor drive circuit, and further comprising the following steps: S1. Energy Harvesting and Dynamic Diversion: A single antenna coil is used to simultaneously receive NFC radio frequency energy and communication signals. The radio frequency energy is converted into DC power through a rectifier circuit. The DC power is divided into two paths by a dynamic diversion control unit. The dynamic diversion control unit adjusts the output path according to the MCU's power supply voltage. The first path provides continuous operating current to the MCU through a voltage regulator circuit, and the second path is an energy storage branch that charges the energy storage element through a controllable switch. S2, DC clamping breakthrough and voltage priority control: A DC blocking capacitor is connected in series in the radio frequency path between the single antenna coil and the NFC TAG chip. The DC blocking capacitor presents low impedance in the radio frequency communication band to ensure NFC communication. In the DC energy transmission path, the DC path of the overvoltage clamping circuit inside the NFC TAG chip is blocked, so that the rectified DC voltage breaks through the clamping voltage limit of the NFC TAG chip and realizes the boost charging of the energy storage element. The charging on / off state is controlled by a switching device connected between the rectifier circuit and the energy storage element. In the initial stage of system startup, the switching device is turned off, and NFC energy is preferentially supplied to the MCU until the MCU voltage stabilizes. After the MCU voltage stabilizes, the switching device is turned on, and the remaining energy charges the energy storage element. After the energy storage element stores enough energy to reach the drive threshold, the MCU can start the motor drive circuit. S3. Dynamic sampling of motor current: During the motor driving process, the MCU collects the motor driving current at a fixed sampling interval and obtains the current waveform data during the motor rotation process through ADC analog-to-digital conversion; S4. Position Detection: Based on the current waveform data, the motor load resistance waveform is reconstructed. The resistance waveform is processed by hardware and software collaborative filtering, the waveform feature parameters are extracted and compared with the pre-stored standard resistance model to determine the motor rotor position.

[0008] As a further explanation of this technical solution: Preferably, the voltage regulator circuit in step S1 is a low dropout voltage regulator module or a reference voltage regulator circuit, which provides continuous operating current for the MCU; through current shunting and voltage regulation, the continuous operating current of the MCU reaches or exceeds 3mA.

[0009] Preferably, the capacitance value of the DC blocking capacitor in step S2 is calculated and selected based on the operating frequency of the NFC antenna and the inductance of a single antenna coil, so that the DC blocking capacitor presents low impedance in the radio frequency communication band to ensure NFC communication, while allowing the peak DC voltage obtained by the energy storage branch to be higher than the DC clamping threshold of the NFC TAG chip.

[0010] Preferably, the switching device in step S2 is a MOSFET, and the conduction voltage of the MOSFET is adapted to the power supply voltage of the MCU: when the power supply voltage of the MCU reaches a stable threshold, the MOSFET turns on to conduct current to charge the energy storage element.

[0011] Preferably, the fixed sampling interval in step S3 is 4ms, corresponding to a sampling rate of 250Hz; during the motor start-up phase, the ADC sampling value is in the range of 150 to 250, and shows an exponential decay trend as the motor speed increases; during the steady-state operation phase of the motor, the ADC sampling value fluctuates in the range of 56 to 262.

[0012] Preferably, the standard resistance model in step S4 is obtained through the following calibration process: running the motor at a known mechanical position, recording the current waveform, and establishing a "position-waveform feature" mapping table; the hardware and software collaborative filtering includes: at the hardware level, setting a configurable RC low-pass filter at the ADC sampling front end, wherein the cutoff frequency is dynamically adjusted according to the spectral distribution of the fundamental frequency of the motor current signal and the PWM switching frequency; at the software level, a cascaded filtering structure is adopted, first eliminating random noise through moving average filtering, then eliminating pulse interference through median filtering, and finally extracting the slope features of the resistance waveform through differential operation.

[0013] Preferably, in step S4, the waveform characteristic parameters include a starting peak point, a trough point, and a plateau segment; the starting peak point is the maximum value of the filtered data in the first 10 sampling points, corresponding to the maximum current at the moment the motor starts; the trough point is the minimum value in the 5th to 15th sampling points, corresponding to the spring being compressed to its maximum position; the plateau segment is a data segment in which the absolute value of the difference between M consecutive sampling points is less than the threshold ε, which is determined as the motor stopping position.

[0014] Preferably, the comparison with the pre-stored standard resistance model employs a dynamic time warping algorithm: D(i,j) = |z i -r j | + min{D(i-1,j), D(i,j-1), D(i-1,j-1)} Where {z i} represents the filtered measured resistance sequence, {r j} represents the resistance sequence of the standard model. The position corresponding to the standard model with the smallest matching distance is the current rotor position of the motor.

[0015] Preferably, the system further includes a security authentication step: the MCU communicates with an external reading and writing device via an NFC antenna and uses the AES algorithm to complete identity authentication and key negotiation; only after the security authentication result is valid and the energy storage voltage of the energy storage element reaches the motor drive threshold is the motor drive control in step S3 executed.

[0016] As another aspect of the present invention, an NFC passive lock power supply and control circuit employing the above method is also provided. include: A single antenna coil is used to simultaneously receive NFC radio frequency energy and communication signals; A rectifier circuit, connected to the single antenna coil, is used to convert radio frequency energy into DC power. The NFC TAG chip is connected to the single antenna coil via a DC blocking capacitor, which is used to block the DC path of the overvoltage clamping circuit inside the TAG chip. A voltage regulator circuit, connected to the rectifier circuit, is used to provide a stable operating voltage for the MCU; The energy storage element is an energy storage capacitor, used to store electrical energy; A MOSFET is connected between the rectifier circuit and the energy storage element to control the charging on / off state. The MCU is connected to the voltage regulator circuit, MOSFET and motor drive circuit. It has an operating current greater than 3mA and is used to control the MOSFET to turn on / off, collect motor current and execute position detection algorithm. The motor drive circuit and the motor are connected to the energy storage capacitor and the MCU. The DC blocking capacitor is connected in series in the radio frequency path between the single antenna coil and the TAG chip, presenting low impedance in the NFC communication band and blocking the clamping circuit in the DC path.

[0017] The present invention also provides an intelligent lock device, including a housing, a lock body mechanism, and an NFC passive lock power supply and control circuit as described above; the lock body mechanism includes a rotary motor driven by the circuit, a transmission gear set, and a lock tongue assembly; the MCU controls the engagement / disengagement state of the transmission gear set according to the stop position determined in step S4; when the energy storage capacitor reaches the drive threshold, the motor drive is started; and when the motor reaches the target position, the motor drive circuit is controlled to stop output.

[0018] Compared with the prior art, the present invention has the following beneficial effects: 1. Significantly improved power supply capability: Through current shunting technology and single antenna design, it provides the MCU with more than 3mA of operating current, which is more than double the 1.5mA of the traditional solution. This allows the system to select a 32-bit microcontroller, greatly improves resources, supports high-strength encryption algorithms such as AES, and significantly enhances security.

[0019] 2. Eliminate antenna interference: The single-antenna design avoids the mutual interference problem between the communication coil and the charging coil in the dual-antenna scheme, resulting in more stable communication and higher charging efficiency.

[0020] 3. Overcoming clamping voltage limitations: By connecting the coil and the TAG chip in series with a capacitor, the 4V DC clamping voltage limitation of the TAG chip is broken, allowing all the energy of the coil to be released into the capacitor, thus greatly improving energy storage efficiency.

[0021] 4. Stable MCU power supply: Controlled by the MOSFET charging switch, the MCU is ensured that its energy is not diverted by the charging of the large capacitor before it obtains a stable voltage, thus ensuring the reliability of system startup.

[0022] 5. Precise Motor Position Detection: By reconstructing the motor resistance waveform through 4ms rapid current sampling and combining it with software and hardware smoothing processing, the stopping position of the motor can be accurately determined, achieving precise control of the motor and improving the reliability and security of the lock.

[0023] 6. Reduced system cost: The single-antenna design reduces the number of antennas, thereby reducing material costs and manufacturing complexity; the abundant resources of the 32-bit MCU also reduce the need for peripheral devices. Attached Figure Description

[0024] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings: Figure 1 This is a block diagram of the energy harvesting and sensorless motor control system based on an NFC single antenna of the present invention; Figure 2 This is a circuit diagram of the power supply and control circuit for an NFC passive lock according to an embodiment of the present invention; Figure 3 This is a flowchart illustrating the shunt power supply and MOSFET charging switch control according to an embodiment of the present invention; Figure 4 This is a flowchart of motor current sampling and position detection according to an embodiment of the present invention; Figure 5 This is a schematic diagram of the motor ADC sampling current waveform (start-up phase) according to an embodiment of the present invention. Figure 6 This is a schematic diagram of the motor ADC sampling current waveform (steady-state operation stage) according to an embodiment of the present invention. Figure 7 This is a waveform diagram illustrating the determination of the motor's stop position according to an embodiment of the present invention. Detailed Implementation

[0025] The technical solutions in the embodiments of the present invention will be clearly and completely described below. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0026] Example 1 Structure: like Figure 1 As shown, the NFC passive lock single-antenna power supply system of the present invention includes: an NFC antenna coil, a TAG chip, a DC blocking capacitor, a MOSFET, an energy storage element, an MCU, a motor drive circuit, and a motor. The energy storage element is preferably a large-capacity capacitor, and the DC blocking capacitor is a capacitor connected in series between the antenna coil and the TAG chip; it can be one capacitor or two or more capacitors connected in parallel.

[0027] The NFC antenna coil is a single-coil design, simultaneously handling communication and charging energy reception. When an NFC reader or writer, such as a mobile phone, approaches, the antenna coil generates AC power through electromagnetic induction. The coil inductance is designed based on the NFC operating frequency of 13.56MHz and communication distance requirements, with a typical value ranging from 1.2μH to 5μH. The coil output is converted into pulsating DC power by a diode bridge rectifier and sent to a dynamic shunt control unit. This unit divides the DC power into two paths: a voltage regulator circuit and an energy storage branch. The voltage regulator circuit includes a low-dropout regulator (LDO), preferably a Shinco HT7130S / HT7530S chip. The energy storage branch includes a MOSFET and a charging circuit for the energy storage element.

[0028] A DC blocking capacitor is connected between the coil and the TAG chip to break the 4V DC overvoltage clamping limitation of the TAG chip. The TAG chip's RF port has a built-in DC overvoltage clamping circuit with a clamping voltage of approximately 4V. Without the DC blocking capacitor, the antenna-induced signal generates a DC component after rectification by the chip's built-in rectifier. This DC potential directly acts on the RF port and is limited by the clamping circuit, confining the maximum voltage of the energy storage capacitor to around 4V. The series DC blocking capacitor blocks the DC path between the antenna and the chip's RF pins, isolating DC potential coupling. The 13.56MHz NFC RF AC signal can be transmitted normally through the capacitor. The alternating energy induced by the antenna coil is no longer constrained by the chip's 4V DC clamping and can continuously charge the downstream energy storage capacitor. The measured energy storage capacitor voltage can reach 3.5V to 10V.

[0029] The capacitance Cb of the DC blocking capacitor is selected based on the coil inductance and the target resonant frequency, with typical values ​​ranging from tens to hundreds of pF.

[0030] In one embodiment, the specific method for selecting the value of the DC blocking capacitor Cb is as follows: The value of the DC blocking capacitor Cb must meet two conditions: Condition 1: Low impedance of RF path To ensure normal transmission of NFC communication signals, the capacitive reactance of the DC blocking capacitor at 13.56MHz must be much smaller than the RF input impedance of the TAG chip. A typical NFC TAG chip (such as the NXP NTAG213) has an RF input impedance of approximately 500Ω (parallel equivalent). Engineering requirements dictate: Xc < Zin / 10 = 50Ω. Calculate the minimum capacitance: C > 1 / (2π × 13.56 × 10). 6 (× 50) ≈ 235pF In practice, Cb = 330pF (standard capacitance value) is selected. At this point: Xc = 1 / (2π × 13.56 × 10 6 × 330×10 -12 ) ≈ 35.6Ω < 50Ω RF signal attenuation: 35.6Ω / (35.6Ω + 500Ω) ≈ 6.6% The signal strength reaching the TAG chip is >93%, so the impact on communication is negligible.

[0031] Condition 2: Do not disrupt the original resonance characteristics The antenna resonant circuit consists of a coil inductance L (2.2μH) and a matching capacitor Cmatch (approximately 62.5pF), with the resonant frequency precisely tuned at 13.56MHz.

[0032] The DC blocking capacitor Cb is connected in series in the RF path. Its capacitive reactance (35.6Ω) is much smaller than the characteristic impedance of the resonant circuit (about 500Ω). The impact on the Q value and resonant frequency of the original LC resonant circuit is less than 5%, and the antenna still maintains a high-quality factor resonance around 13.56MHz.

[0033] The MCU is connected to the rectifier circuit via a voltage regulator circuit. An LDO (low dropout linear regulator) is used to regulate the rectified DC voltage to 3.0V, providing a stable operating voltage for the MCU. The LDO has an input voltage range of 3.5V to 10V, a maximum output current of 150mA, and a quiescent current of less than 50μA.

[0034] like Figure 2 The diagram shown is a circuit diagram of one embodiment. Here, two capacitors C23 and C24 are connected in parallel as DC blocking capacitors; Q3 is a MOSFET; the energy storage element is a large capacitor C11; U1 is an MCU; and U10 is a TAG chip.

[0035] In this embodiment, MOSFET Q3 acts as a shunt controller, connected between the rectifier circuit and the charging circuit of the large capacitor C11. During initial system startup, MOSFET Q3 is off, cutting off the charging circuit of the large capacitor C11 and ensuring that the limited energy obtained by the antenna coil is preferentially supplied to U1, allowing U1 to quickly obtain a stable operating voltage. Once the voltage of U1 stabilizes, MOSFET Q3 turns on, directing the remaining energy to the large capacitor C11 for energy storage. The selection of MOSFET Q3 must be based on the MCU's stable threshold voltage (equal to the Q3's turn-on voltage) and must meet the requirements of low on-resistance and matching of the gate drive voltage with the MCU U1 output level.

[0036] The charging control process of MOSFET Q3 in one embodiment is as follows: System startup phase (t < t1): When the rectified voltage is below 3.0V, MOSFET Q3 is turned off, and all NFC energy is supplied to MCUU1. The MCU U1 supply voltage Vmcu rises from 0V to the stable threshold Vstable = 3.0V. During this phase, the voltage Vc of the energy storage capacitor C11 is 0V.

[0037] Rapid voltage rise phase (t1 ≤ t < t2): When MCU U1 Vmcu = Vstable, MOSFET Q3 is directly turned on. The energy storage capacitor voltage Vc rises rapidly from 0V.

[0038] If Vc ≥ Vtarget = 8V, the motor can be started after the target voltage is reached.

[0039] The above charging control ensures stable power supply to the MCU U1 and allows the energy storage capacitor voltage to rise rapidly, preventing excessive charging current from draining the MCU power supply during system startup. Actual charging time from 0V to 8V is approximately 3-10 seconds (depending on the NFC radio frequency field strength).

[0040] The energy storage capacitor C11 is used to store electrical energy, providing energy reserves for subsequent motor drive. The capacitance value of the energy storage capacitor C11 is calculated based on the pulse current and duration required for motor drive, with typical values ​​ranging from 1500μF to 4700μF. Its voltage rating must be higher than the maximum voltage boosted by the series capacitor. In this embodiment, C11 = 2200μF, with a voltage rating of 16V, and the energy storage capacity E = 1 / 2 × 2200 × 10⁻⁶. -6 × 8 2 ≈ 70.4mJ, which can meet the single drive requirements of the motor.

[0041] The MCU (main control unit) U1 uses a 32-bit ARM Cortex-M0+ microcontroller core (such as the STM32L0 or GD32L series), integrating a hardware AES engine and a 12-bit ADC. It can operate normally with a current consumption of less than 3mA, has ample Flash storage space (e.g., 64KB or more), supports AES-128 / 256 encryption algorithms, and enables secure interaction with mobile phones. The rich peripheral resources of the 32-bit MCU (multi-channel ADC, PWM timer, GPIO, etc.) also provide a hardware foundation for precise motor control.

[0042] Example 2: Energy Diversion Power Supply Control Process

[0043] In traditional single-antenna designs, the VCC pin of the TAG chip has a diode connected to GND, which conducts and discharges when the AC peak value exceeds 4.0V. This invention introduces a DC blocking capacitor connected in series between the antenna coil and the TAG chip, forming a high-pass filter impedance network. At the 13.56MHz operating frequency band, the DC blocking capacitor presents a low-impedance path to ensure communication modulation; simultaneously, it cuts off the DC path, preventing the energy storage node voltage from being clamped. Actual measurements show that at a 3cm operating distance, the energy storage capacitor C11 can be stably charged to 8V (typical value), an 80% improvement over traditional solutions, sufficient to drive a bipolar stepper motor to complete the full-stroke unlocking action.

[0044] like Figure 3 As shown, the energy shunt power supply and MOSFET charging switch control process of one embodiment of the present invention is as follows: Step 201: The single antenna coil senses and acquires NFC radio frequency energy, which is then rectified by the rectifier circuit to output a pulsating DC voltage.

[0045] Step 202: DC blocking capacitors C23 and C24 are connected in series in the RF path, presenting a low impedance (approximately 35.6Ω) at 13.56MHz, ensuring normal transmission of NFC communication signals; at the same time, they block the internal 4V clamping circuit of TAG chip U10 in the DC path, allowing the rectified DC voltage to rise to 6V-16V.

[0046] Step 203: MOSFET Q3 is initially in the off state, and energy is preferentially supplied to MCU U1. U1 starts up quickly and reaches a stable operating voltage of 3.0V.

[0047] Step 204: When the voltage is 3.0V, MOSFET Q3 is turned on.

[0048] Step 205: After MOSFET Q3 is turned on, the capacitor voltage rises rapidly.

[0049] Step 206: When the voltage of the energy storage capacitor C11 reaches the target value of 8V (depending on the actual product and spring force), stop charging and wait for the motor drive command.

[0050] Step 207: When the motor needs to be driven, the energy storage capacitor C11 releases the stored electrical energy and drives the motor to rotate through the motor drive circuit.

[0051] Through the above-mentioned shunt control, the system achieves priority management of "first ensuring power supply to the MCU, then storing energy to drive the motor", ensuring the reliability of system startup.

[0052] Example 3: Rapid sampling of motor current and position detection

[0053] like Figure 3 As shown, the motor current sampling and position detection process of one embodiment of the present invention is as follows: Step 301: The MCU starts the motor driver, outputs a level to control the motor drive circuit, and the motor starts to rotate.

[0054] Step 302: The MCU's internal ADC module continuously samples the motor current at a 4ms sampling interval. A 4ms sampling interval corresponds to a 250Hz sampling rate, effectively capturing resistance changes during motor rotation. The ADC resolution is 10 bits. The sampling channel obtains the motor current signal through a current sampling resistor (typically 1Ω) connected in series in the motor drive circuit. The current signal is amplified by an operational amplifier and then sent to the ADC.

[0055] Step 303: The MCU stores the acquired ADC data in an internal circular buffer to form a continuous current waveform data sequence.

[0056] Step 304: The MCU performs algorithm processing on the acquired current waveform data to reconstruct the resistance waveform during motor rotation.

[0057] Step 305: Through hardware and software collaborative smoothing, sampling noise and transient interference are filtered out to improve the signal-to-noise ratio.

[0058] Step 306: Based on the smoothed waveform characteristics, accurately determine the position of the motor rotor.

[0059] Step 307: Based on the motor rotor position determination result, control the motor drive circuit to perform corresponding actions, such as stopping the output or performing fine-tuning of rotation.

[0060] Example 4: Specific Implementation of the Position Detection Algorithm

[0061] One embodiment of the position detection algorithm of the present invention specifically includes the following steps: Step 401: Moving Average Filtering For the original ADC sampled data sequence {x1, x2, ..., x n Perform an N-point moving average: yi = (x i + x i+1 + ... + x i+n-1 ) / N Where N = 4, the sampling interval is 4ms, and the time resolution after filtering is maintained at 16ms.

[0062] Step 402: Median Filtering Perform a 3-point median filter on the moving average data {yᵢ}: z i = median(y i-1 , y i , y i+1 ) Eliminate occasional pulse interference.

[0063] Step 403: Calculate the slope using the first-order difference Calculate the difference sequence of the filtered data: Δz i = z i - z i-1 The slope reflects the rate of change of resistance.

[0064] Step 404: Feature Point Recognition Identify key feature points in the resistance waveform: - Startup peak point: max{z i | i ∈ [1, 10]}, which corresponds to the maximum current at the moment the motor starts, that is, the maximum value of the filtered data in the first 10 sampling points, which corresponds to the maximum current at the moment the motor starts; - Trough point: min{z i | i ∈ [5, 15]}, which corresponds to the spring being compressed to its maximum position, that is, the trough point is the minimum value among the 5th to 15th sampling points, which corresponds to the spring being compressed to its maximum position; - Plateau segment: M consecutive sampling points satisfy |Δz i If | < ε, it is determined to be a stopping position, that is, a data segment in which the absolute value of the difference between M consecutive sampling points is less than the threshold ε is determined to be a stopping position of the motor.

[0065] Where M = 5 (corresponding to 20ms), ε = 5 (ADC quantization unit).

[0066] Step 405: Location Matching The extracted feature point sequence is matched with a pre-stored standard resistance model using dynamic time warping (DTW): D(i,j) = |z i -r j| + min{D(i-1,j), D(i,j-1), D(i-1,j-1)} Where {z i} represents the filtered measured resistance sequence, {r j} represents the resistance sequence of the standard resistance model. The position corresponding to the standard resistance model with the smallest matching distance is the current rotor position of the motor.

[0067] In a preferred embodiment, the initialization and boundary conditions of the cumulative distance matrix DD of the Dynamic Time Warping (DTW) algorithm are defined as follows: Initialization: Set D(0,0)=0 Boundary conditions: For the case where i>0 and j=0, set D(i,0)=∞ (infinity); for the case where i=0 and j>0, set D(0,j)=∞.

[0068] Example 5: Motor ADC Sampling Waveform Analysis

[0069] like Figure 4 and Figure 5 As shown, in one embodiment of the present invention, the motor current is sampled by an ADC, and the obtained waveform data has the following characteristics: 1. Startup phase waveform ( Figure 4 At the moment of motor startup, since the rotor is stationary, the back electromotive force is zero, and the current value is relatively large, with the ADC sampling value ranging from 150 to 250. As the motor speed increases, the back electromotive force gradually increases, and the current gradually decreases, with the sampling value gradually decreasing from about 100 to about 50, showing a clear exponential decay trend. This stage reflects the transition process of the motor from standstill to stable operation, and the peak current corresponds to the maximum resistance torque at startup.

[0070] 2. Waveform during steady-state operation ( Figure 5 After the motor enters steady-state operation, it pushes the slider inward to prepare for unlocking, while simultaneously compressing the spring. The current value begins to slowly rise, and the ADC sampling value rises from 50 to around 150, reaching a peak, indicating that the unlocking is complete and the spring is compressed to its maximum force. Next, the current value begins to decline from 150 to 50, the slider begins to retract, and the spring begins to rebound. When it reaches 50, it indicates that the spring and slider have fully returned to their original positions. Each group of 20 consecutive sampling points (corresponding to an 80ms time window) constitutes a complete resistance waveform cycle. The waveform exhibits a characteristic of first decreasing and then fluctuating. - Front section (sampling points 1-8): The current value gradually decreases from about 210-260 to about 90-150, reflecting the process of the motor overcoming the initial resistance in the mechanical structure; - Mid-section (sampling points 9-14): The current value fluctuates within the range of 60-150, reflecting the change in resistance encountered by the motor at different mechanical positions; - Later stage (sampling points 15-20): The current value tends to stabilize in the range of 56-80, reflecting that the resistance tends to be constant when the motor approaches the stop position.

[0071] 3. Multi-cycle sampling data: The system collects multiple sets (more than 10 sets) of continuous motor current waveform data. The waveforms in each set show a consistent trend, but the specific values ​​differ, reflecting the resistance variation pattern of the motor in different operating cycles. Through comparative analysis of multiple sets of data, a standard model of the motor resistance waveform can be established, i.e., a standard resistance model, which is stored in the MCU's Flash memory as a reference for position determination.

[0072] 4. Motor Stop Position Determination: By analyzing multiple sets of ADC sampled waveform data, the MCU can identify feature points in the current waveform corresponding to the motor's stop position. When the latter part of the current waveform stabilizes and falls below a preset threshold, the motor is determined to have reached the stop position. Combined with hardware and software smoothing processing, interference from mechanical vibration and electrical noise can be effectively filtered out, achieving millisecond-level accurate position determination.

[0073] Example 6: Software and hardware co-processing for smooth processing

[0074] To improve the accuracy of motor position determination, one embodiment of the present invention employs a hardware and software collaborative smoothing processing scheme as follows: Hardware smoothing: An RC low-pass filter circuit is set at the ADC sampling front end to filter out high-frequency electrical noise. The filter circuit uses an RC low-pass filter, and the values ​​of resistor R and capacitor C are calculated and determined based on the effective bandwidth of the motor current signal (usually tens to hundreds of Hz) and the noise frequency to be filtered out (such as PWM switching frequency of 100kHz, power supply ripple frequency). The cutoff frequency fc = 1 / (2πRC) is set according to the effective bandwidth of the motor current signal, generally set to 2 to 5 times the highest frequency of the signal, ensuring that useful resistance waveform information is retained while filtering out high-frequency interference. In one embodiment, R = 10kΩ and C = 0.1μF are selected, then fc = 1 / (2π × 10 × 10). 3 × 0.1×10 -6 ) ≈ 159Hz ≈ 50Hz × 3.2 times, which can effectively filter out 100kHz PWM switching noise while retaining the main frequency components (<50Hz) of the motor resistance waveform.

[0075] Software smoothing: The MCU performs the following processing on the ADC sampled data: (1) Moving average filtering: Take the average value of four consecutive sampling points to eliminate random noise.

[0076] (2) Median filtering: The median value of the data within the sliding window is taken to eliminate impulse interference. The window width for median filtering is 3 sampling points.

[0077] (3) Waveform feature extraction: Extract feature parameters such as slope (first-order difference), peak value, and plateau segment (data segment with variance less than the threshold) from the smoothed waveform. The slope reflects the rate of change of resistance, the peak value corresponds to the position of maximum resistance, and the plateau segment corresponds to the stopping position.

[0078] (4) Position determination: The extracted feature parameters are matched with the pre-stored standard model of motor resistance waveform (standard resistance model) using DTW (Dynamic Time Warping). The standard resistance model can be obtained through the calibration process: run the motor at a known mechanical position, record the current waveform, and establish a "position-waveform feature" mapping table. During actual operation, the features extracted in real time are compared with the standard model, and the current position of the motor is determined by minimum error matching.

[0079] For specific methods, please refer to the detailed implementation of the position detection algorithm in Example 4.

[0080] Through the above-mentioned hardware and software collaborative processing, the precise determination of the motor's stopping position is finally achieved, and the control accuracy can reach the level of a single mechanical tooth pitch (such as 0.5mm to 1mm).

[0081] Example 7: Security Authentication Workflow

[0082] One embodiment of the present invention also includes security authentication, the complete workflow of which is as follows: 1. System power-on: When an external NFC reader or writer approaches, the single antenna coil senses and obtains radio frequency energy. After the DC blocking capacitor blocks the clamping voltage limitation, the energy is preferentially supplied to the MCU.

[0083] 2. MCU startup: MOSFET Q3 remains off. After the MCU receives a stable power supply, it starts up quickly and performs system initialization (configuring clock, GPIO, ADC, PWM, NFC communication interface, etc.).

[0084] 3. Security Authentication: The MCU communicates encrypted with external reading and writing devices, such as mobile phones, via the NFC antenna, using the AES-128 algorithm for authentication and key negotiation. The ample computing resources of the 32-bit MCU ensure the rapid completion of the encryption process (typically within a few hundred milliseconds).

[0085] 4. Energy storage preparation: After the voltage reaches 3.0V, the MOSFET Q3 turns on the switch to conduct the circuit and charges the energy storage capacitor C11.

[0086] 5. Motor drive: When the safety certification is passed and the energy storage capacitor C11 reaches the drive threshold (8V), the MCU starts the motor drive circuit and outputs a level to drive the motor to rotate and perform the target action, such as unlocking / locking.

[0087] 6. Current sampling: The MCU continuously collects motor current ADC data at 4ms intervals to monitor the motor's operating status in real time and stores the data in a buffer.

[0088] 7. Position determination: The MCU performs hardware and software smoothing on the sampled data to restore the motor resistance waveform. By comparing it with the standard model using the DTW algorithm, the position of the motor rotor is accurately determined.

[0089] 8. Action completed: After the motor reaches the target position, the MCU controls the motor drive circuit to stop outputting, completing the unlocking / locking action. If necessary, it performs a fine-tuning action to eliminate mechanical backlash and sends the operation result back to external NFC reading / writing devices, such as mobile phones.

[0090] 9. System Sleep: After the operation is completed, the MCU shuts down the motor driver, ADC and other peripherals, enters low-power sleep mode, and waits for the next NFC wake-up.

[0091] Industrial applicability

[0092] The energy harvesting and sensorless motor control method based on an NFC single antenna described in this invention can be widely applied to scenarios requiring passive power supply and precise control, such as smart door locks, shared equipment cabinets, smart express cabinets, and IoT terminals. By reducing material costs through a single-antenna design, enhancing driving capability through boost energy storage, and achieving precise position control through current sampling, it demonstrates significant technological advancements and economic benefits.

[0093] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for energy harvesting and sensorless motor control based on an NFC single antenna, comprising a single antenna coil, an MCU, an NFC TAG chip, a DC blocking capacitor, an energy storage element, a motor unit, and a motor drive circuit, characterized in that, Includes the following steps: S1. Energy Harvesting and Dynamic Diversion: A single antenna coil is used to simultaneously receive NFC radio frequency energy and communication signals. The radio frequency energy is converted into DC power through a rectifier circuit. The DC power is divided into two paths by a dynamic diversion control unit. The dynamic diversion control unit adjusts the output path according to the MCU's power supply voltage. The first path provides continuous operating current to the MCU through a voltage regulator circuit, and the second path is an energy storage branch that charges the energy storage element through a controllable switch. S2, DC clamping breakthrough and voltage priority control: A DC blocking capacitor is connected in series in the radio frequency path between the single antenna coil and the NFC TAG chip. The DC blocking capacitor presents low impedance in the radio frequency communication band to ensure NFC communication. In the DC energy transmission path, the DC path of the overvoltage clamping circuit inside the NFC TAG chip is blocked, so that the rectified DC voltage breaks through the clamping voltage limit of the NFC TAG chip and realizes the boost charging of the energy storage element. The charging on / off state is controlled by a switching device connected between the rectifier circuit and the energy storage element. In the initial stage of system startup, the switching device is turned off, and NFC energy is preferentially supplied to the MCU until the MCU voltage stabilizes. After the MCU voltage stabilizes, the switching device is turned on, and the remaining energy charges the energy storage element. After the energy storage element stores enough energy to reach the drive threshold, the MCU can start the motor drive circuit. S3. Dynamic sampling of motor current: During the motor driving process, the MCU collects the motor driving current at a fixed sampling interval and obtains the current waveform data during the motor rotation process through ADC analog-to-digital conversion; S4. Position Detection: Based on the current waveform data, the motor load resistance waveform is reconstructed. The resistance waveform is processed by hardware and software collaborative filtering, the waveform feature parameters are extracted and compared with the pre-stored standard resistance model to determine the motor rotor position.

2. The method according to claim 1, characterized in that, The voltage regulator circuit mentioned in step S1 is a low dropout voltage regulator module or a reference voltage regulator circuit, which provides continuous operating current for the MCU; through current shunting and voltage regulation, the continuous operating current of the MCU reaches or exceeds 3mA.

3. The method according to claim 1, characterized in that, The capacitance value of the DC blocking capacitor in step S2 is calculated and selected based on the operating frequency of the NFC antenna and the inductance of a single antenna coil, so that the DC blocking capacitor presents low impedance in the radio frequency communication band to ensure NFC communication, while allowing the peak DC voltage obtained by the energy storage branch to be higher than the DC clamping threshold of the NFC TAG chip.

4. The method according to claim 1, characterized in that, The switching device mentioned in step S2 is a MOSFET, and the conduction voltage of the MOSFET is adapted to the power supply voltage of the MCU: when the power supply voltage of the MCU reaches a stable threshold, the MOSFET turns on to conduct current to charge the energy storage element.

5. The method according to claim 1, characterized in that, The fixed sampling interval in step S3 is 4ms, corresponding to a sampling rate of 250Hz. During the motor start-up phase, the ADC sampling value is in the range of 150 to 250, and it decreases exponentially with the increase of motor speed. During the steady-state operation phase of the motor, the ADC sampling value fluctuates in the range of 56 to 262.

6. The method according to claim 1, characterized in that, The standard resistance model mentioned in step S4 is obtained through the following calibration process: run the motor at a known mechanical position, record the current waveform, and establish a "position-waveform feature" mapping table; The hardware and software collaborative filtering includes: at the hardware level, a configurable RC low-pass filter with a cutoff frequency is set at the front end of the ADC sampling, and the cutoff frequency is dynamically adjusted according to the spectral distribution of the fundamental frequency of the motor current signal and the PWM switching frequency; at the software level, a cascaded filtering structure is adopted, firstly, random noise is eliminated by moving average filtering, then pulse interference is eliminated by median filtering, and finally, the slope characteristics of the resistance waveform are extracted by differential operation.

7. The method according to claim 1, characterized in that, In step S4, the waveform characteristic parameters include the starting peak point, the trough point, and the plateau segment; the starting peak point is the maximum value of the filtered data in the first 10 sampling points, corresponding to the maximum current at the moment the motor starts; the trough point is the minimum value in the 5th to 15th sampling points, corresponding to the spring being compressed to its maximum position; the plateau segment is a data segment in which the absolute value of the difference between M consecutive sampling points is less than the threshold ε, which is determined to be the motor stopping position; The comparison with the pre-stored standard resistance model employs a dynamic time warping algorithm: D(i,j) = |z i -r j | + min{D(i-1,j), D(i,j-1), D(i-1,j-1)} Where {z i } represents the filtered measured resistance sequence, {r j } represents the resistance sequence of the standard model. The position corresponding to the standard model with the smallest matching distance is the current rotor position of the motor.

8. The method according to claim 1, characterized in that, It also includes a security authentication step: the MCU communicates with the external reading and writing device in encrypted form through the NFC antenna and uses the AES algorithm to complete identity authentication and key negotiation; only after the security authentication result is valid and the energy storage voltage of the energy storage element reaches the motor drive threshold is the motor drive control in step S3 executed.

9. An NFC passive lock power supply and control circuit for implementing the method of any one of claims 1-8, characterized in that, include: A single antenna coil is used to simultaneously receive NFC radio frequency energy and communication signals; A rectifier circuit, connected to the single antenna coil, is used to convert radio frequency energy into DC power. The NFC TAG chip is connected to the single antenna coil via a DC blocking capacitor, which is used to block the DC path of the overvoltage clamping circuit inside the TAG chip. A voltage regulator circuit, connected to the rectifier circuit, is used to provide a stable operating voltage for the MCU; The energy storage element is an energy storage capacitor, used to store electrical energy; A MOSFET is connected between the rectifier circuit and the energy storage element to control the charging on / off state. The MCU is connected to the voltage regulator circuit, MOSFET and motor drive circuit. It has an operating current greater than 3mA and is used to control the MOSFET to turn on / off, collect motor current and execute position detection algorithm. The motor drive circuit and the motor are connected to the energy storage capacitor and the MCU. The DC blocking capacitor is connected in series in the radio frequency path between the single antenna coil and the TAG chip, presenting low impedance in the NFC communication band and blocking the clamping circuit in the DC path.

10. A smart lock device, characterized in that, The device includes a housing, a lock body mechanism, and an NFC passive lock power supply and control circuit as described in claim 9. The lock body mechanism includes a rotary motor driven by the circuit, a transmission gear set, and a latch assembly. The MCU controls the engagement / disengagement state of the transmission gear set according to the stop position determined in step S4. When the energy storage capacitor reaches the drive threshold, the motor drive is started. After the motor reaches the target position, the motor drive circuit is controlled to stop outputting.