A rotating counting device and counting method based on electromagnetic signals
By using a rotary counting device based on electromagnetic signals and utilizing PCB coils and signal processing circuits, the problems of magnetic sensors being susceptible to magnetic field interference and LC oscillation measurement requiring high inductance in existing technologies are solved, achieving high-precision and miniaturized rotary counting.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-26
- Publication Date
- 2026-04-07
AI Technical Summary
In existing rotary counting technologies, magnetic sensors are susceptible to magnetic field interference, LC oscillation metering has high inductance requirements and is limited by distance, and the coil excitation voltage is relatively susceptible to interference, making it difficult to achieve high-precision and miniaturized rotary counting.
A rotation counting device based on electromagnetic signals is adopted. It utilizes a PCB coil, a pulse excitation circuit, and a signal processing circuit. The signal processor controls the switching of high and low voltages to generate a rectangular signal. The differentiating circuit detects the edge sharp pulse signal. Combined with voltage amplification detection and inverter processing of electromagnetic signals, the rotation detection of the tray is realized.
It improves the accuracy and anti-interference ability of rotation counting, realizes high-precision miniaturized rotation counting, and reduces the influence of external magnetic fields and environmental changes.
Smart Images

Figure CN115828982B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of metrology, and in particular to a rotary counting device and counting method based on electromagnetic signals. Background Technology
[0002] Existing rotation counting technologies include magnetic sensing measurement technology, LC oscillation excitation measurement technology, and coil excitation voltage comparison measurement technology.
[0003] Magnetic sensing measurement technology mostly uses reed switches and Hall elements as sensors. These sensors all have magnetic properties and emit pulse signals under the influence of a magnetic field. However, they all have significant drawbacks. For example, reed switches are encapsulated in glass and may crack in areas with large temperature differences or during transportation. Reed switches also have a limited number of actuations, making them unsuitable for high-precision measurement. Hall elements are moisture-sensitive devices and are easily affected by humidity, leading to a large static current and premature battery depletion in the measurement equipment. These magnetic sensors also share a common drawback: the proximity of a magnet can cause measurement problems. In magnetic measurement devices, the permanent magnet is in a rotating position. When the magnetic sensor passes near the magnet, it will activate, but it is easily affected by external magnetic interference, causing measurement errors.
[0004] Non-magnetic metrology can achieve measurement without magnetic triggering and boasts high stability, high accuracy, and strong anti-interference capabilities, gradually replacing magnetic metrology. However, in LC oscillation-based sensors, the rotating part uses a metallized disk. Approaching this disk changes the damping, and a comparator outputs a pulse. This LC excitation method places high demands on the inductor. With increased distance, the inductance needs to be large, but large inductors have an iron core, making them highly susceptible to strong magnetic fields. Hollow inductors, on the other hand, result in weak energy and poor performance in practical applications due to insufficient distance. LC oscillation-based non-magnetic metrology, limited by distance, requires iron-core inductors. The iron core is affected by strong magnetic fields, impacting the inductance effect. Therefore, it doesn't truly eliminate magnetic interference; it's merely a transitional technology between magnetic and non-magnetic metrology.
[0005] Coil excitation voltage comparison measurement technology mainly uses the coil voltage input to a comparator for pairwise comparison. However, the comparison of weak signals is easily affected by interference, leading to inaccurate measurement. Another method is to use a predetermined voltage comparison reference, which needs to be manually calibrated during use. Another method is to increase the anti-interference ability by adding more transmitting and receiving coils, but this will occupy more space and cannot be used for miniaturization requirements. Summary of the Invention
[0006] To address the shortcomings mentioned above, this invention provides a rotary counting device and counting method based on electromagnetic signals.
[0007] To achieve the above objectives, the present invention provides a rotation counting device based on electromagnetic signals, comprising a tray rotating around its center and a rotation detection device located above the tray and fixed in place. The upper surface of the tray is partially metallized. The rotation detection device includes a PCB coil, a pulse excitation circuit, and a signal processing circuit. The PCB coil includes a transmitting coil parallel to the upper plane of the tray and at least two receiving coils arranged circumferentially at equal angles along the center of the transmitting coil. The signal processing circuit includes a voltage amplification and detection circuit and a signal processor. One end of each receiving coil is connected to an input terminal of the voltage amplification and detection circuit. The pulse excitation circuit includes a resistor R4, a capacitor C4, an inverter P1, and an inverter P2. The voltage output terminal of the signal processor is connected in series with the capacitor C4, the inverter P1, and the inverter P2. One end of the resistor R4 is grounded, and the other end is connected between the capacitor C4 and the inverter P1, so that the capacitor C4 and the resistor R4 form a differentiating circuit.
[0008] The signal processor controls the high and low voltage switching to generate a rectangular signal. The differentiating circuit detects the edge spike signal of the rectangular signal. After passing through the inverter P1, the edge spike signal is coupled to the voltage amplification and detection circuit through capacitor C5. After passing through the inverter P2, it is coupled to the transmitting coil through capacitor C6.
[0009] Preferably, the voltage amplification and detection circuit includes a transistor Q1 and a capacitor C1. One end of the receiving coil is connected to the base of the transistor Q1, one end of the collector of the transistor Q1 is connected to one end of the capacitor C1 and the signal processor, the other end of the capacitor C1 is grounded, and the emitter of the transistor Q1 is connected to the capacitor C5.
[0010] Preferably, in the initial state, capacitor C1 in the voltage amplification and detection circuit is charged.
[0011] Preferably, the edge spike signal is the start signal of the voltage amplification and detection circuit.
[0012] Preferably, after receiving the edge spike signal, the transmitting coil generates an electromagnetic signal and transmits it to the tray, and the receiving coil receives the electromagnetic signal reflected back from the tray.
[0013] Preferably, after the receiving coil receives the electromagnetic signal, the voltage amplification and detection circuit is activated by an edge spike pulse signal, the capacitor C1 is discharged, and after the rectangular signal ends, the signal processor collects the remaining voltage of the capacitor C1.
[0014] Preferably, the metal area covered by the tray is semi-circular.
[0015] The present invention also provides a rotation counting method based on electromagnetic signals, employing the above-mentioned rotation counting device based on electromagnetic signals, comprising:
[0016] The signal processor controls the switching of its voltage high and low to generate a rectangular signal;
[0017] The differentiating circuit detects the edge spike pulse signal of the rectangular signal;
[0018] The edge spike signal, after passing through inverter P1, is coupled to the voltage amplification and detection circuit through capacitor C5, serving as the start signal for the voltage amplification and detection circuit.
[0019] The edge spike signal is then coupled to the transmitting coil through capacitor C6 after passing through inverter P2;
[0020] After receiving the edge spike pulse signal, the transmitting coil generates an electromagnetic signal and transmits it to the tray; the receiving coil receives the electromagnetic signal reflected back from the tray.
[0021] After the receiving coil receives the electromagnetic signal, the capacitor C1 in the voltage amplification and detection circuit discharges. After the rectangular signal ends, the signal processor collects the remaining voltage signal of the capacitor C1.
[0022] Based on the voltage signal, the maximum and minimum values of the voltage signal are calculated.
[0023] Based on the maximum and minimum values of the voltage signal, the voltage signal is converted into a square wave;
[0024] Based on the square wave, the rotation direction and number of rotations of the tray are obtained.
[0025] Preferably, in the initial state, capacitor C1 in the voltage amplification and detection circuit is charged.
[0026] Preferably, obtaining the rotation direction and number of rotations of the tray based on the square wave includes:
[0027] The square wave includes two states: high voltage and low voltage.
[0028] The two square waves formed by the receiving coils have four states, including low voltage and low voltage, low voltage and high voltage, high voltage and high voltage, and high voltage and low voltage.
[0029] Based on the four states, the rotation direction and number of rotations of the tray are obtained.
[0030] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0031] This invention uses a signal processing algorithm to replace the comparator, and improves the counting accuracy and anti-interference ability of the counting device by internally counting and then outputting through a reliable interface. Attached Figure Description
[0032] Figure 1 This is a structural diagram of the electromagnetic signal-based rotation counting device of the present invention;
[0033] Figure 2 This is a circuit diagram of the electromagnetic signal rotation counting device of the present invention;
[0034] Figure 3 This invention is based on a voltage signal diagram in an electromagnetic signal rotation counting device;
[0035] Figure 4 yes Figure 3 The transformed square wave diagram. Detailed Implementation
[0036] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, 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.
[0037] Reference Figure 1 The present invention provides a rotation counting device based on electromagnetic signals, comprising:
[0038] A tray 9 rotates around its center, and a rotation detection device is fixed above the tray 9. The upper surface of the tray 9 is partially metallized. The rotation detection device includes a PCB coil, a pulse excitation circuit, and a signal processing circuit. The PCB coil includes a transmitting coil 1 parallel to the upper plane of the tray 9 and at least two receiving coils 2 arranged circumferentially at equal angles along the center of the transmitting coil 1. Figure 1 The diagram shows three receiving coils: 2-1, 2-2, and 2-3.
[0039] Specifically, tray 9 is circular, and a rotary motor for rotating it is located below tray 9. The covered metal area 7-2 is preferably a semicircle, with its center concentric with the transmitting coil 1, and the remaining area is the uncovered metal area 7-1; other cases can also be counted, for example, the metal area 7-2 covers a 240° circle, with its center not concentric with the transmitting coil 1. The distance between tray 9 and the rotation detection device varies in different cases, with the maximum distance being preferred. The PCB coil is mounted on PCB board 8. The signal processor is a microcontroller.
[0040] Reference Figure 2The signal processing circuit includes a voltage amplification and detection circuit and a signal processor. One end of each receiving coil 2 is connected to the input terminal of a voltage amplification and detection circuit. The pulse excitation circuit includes a resistor R4, a capacitor C4, an inverter P1, and an inverter P2. The voltage output terminal of the signal processor is connected in series with the capacitor C4, the inverter P1, and the inverter P2 in sequence. One end of the resistor R4 is grounded, and the other end is connected between the capacitor C4 and the inverter P1 so that the capacitor C4 and the resistor R4 form a differentiating circuit.
[0041] The signal processor controls the high and low voltage switching to generate a rectangular signal. The differentiating circuit detects the edge spike signal of the rectangular signal. After passing through inverter P1, the edge spike signal is coupled to the voltage amplification and detection circuit through capacitor C5. After passing through inverter P2, it is coupled to the transmitting coil 1 through capacitor C6.
[0042] Furthermore, the voltage amplification and detection circuit includes a transistor Q1 and a capacitor C1. One end of the receiving coil 2 is connected to the base of the transistor Q1, one end of the collector of the transistor Q1 is connected to one end of the capacitor C1 and the signal processor, the other end of the capacitor C1 is grounded, and the emitter of the transistor Q1 is connected to the capacitor C5.
[0043] In this embodiment, initially, capacitor C1 in the voltage amplification and detection circuit is charged; the edge spike signal is the start signal of the voltage amplification and detection circuit; after receiving the edge spike signal, the transmitting coil 1 generates an electromagnetic signal and transmits it to the tray 9. Different material areas on the tray 9 reflect electromagnetic signals with varying intensities, thus the intensity of the electromagnetic signal received by the receiving coil 2 is periodic and is converted into a periodically changing voltage signal. The receiving coil 2 receives the electromagnetic signal reflected back from the tray 9; after receiving the electromagnetic signal, the receiving coil 2 simultaneously activates the voltage amplification and detection circuit with the edge spike signal, and capacitor C1 discharges. After the rectangular signal ends, the signal processor acquires the remaining voltage of capacitor C1.
[0044] The present invention also provides a rotation counting method based on electromagnetic signals, employing the above-mentioned rotation counting device based on electromagnetic signals, comprising:
[0045] Initially, capacitor C1 in the voltage amplification and detection circuit is charged;
[0046] The signal processor controls the switching of its voltage high and low to generate a rectangular signal;
[0047] The differentiating circuit detects the edge spike signal of the rectangular signal;
[0048] After passing through inverter P1, the edge spike signal is coupled to the voltage amplification and detection circuit through capacitor C5, serving as the start signal for the voltage amplification and detection circuit.
[0049] After passing through inverter P2, the edge spike signal is coupled to transmitting coil 1 through capacitor C6;
[0050] After receiving the edge spike pulse signal, the transmitting coil 1 generates an electromagnetic signal and transmits it to the tray 9. The receiving coil 2 receives the electromagnetic signal reflected back from the tray 9.
[0051] After receiving the electromagnetic signal, the capacitor C1 in the voltage amplification and detection circuit discharges. After the rectangular signal ends, the signal processor collects the remaining voltage signal of capacitor C1.
[0052] Based on the voltage signal, the maximum and minimum values of the voltage signal are statistically analyzed;
[0053] Based on the maximum and minimum values of the voltage signal, the voltage signal is converted into a square wave;
[0054] Based on the square wave, the rotation direction and number of rotations of tray 9 are obtained.
[0055] Furthermore, based on the square wave, the rotation direction and number of rotations of tray 9 are obtained, including:
[0056] A square wave includes two states: high voltage and low voltage.
[0057] The two square waves formed by receiving coil 2 have four states, including low voltage and low voltage, low voltage and high voltage, high voltage and high voltage, and high voltage and low voltage.
[0058] Based on the four states, the rotation direction and number of rotations of tray 9 are obtained.
[0059] Reference Figure 3 and Figure 4 The counting process is based on two square waves formed by receiving coil 2:
[0060] The voltage signal collected by receiving coil 2 is converted into voltage signals obtained by two logic receiving coils 2 with an angle of 90 degrees between them, according to the sine and cosine relationship. These are called two counting signals. This is because there are no two orthogonal axes of symmetry in the position of receiving coil 2. Therefore, the voltage signals obtained by two logic receiving coils 2 with an angle of 90 degrees between them can be converted according to the position angle of receiving coil 2.
[0061] The two counting signals are tracked for changes, and their rising and falling trends are statistically analyzed to determine their center positions, called center values. Based on these two center values, upper and lower thresholds are set for each. Using the bistable hysteresis comparison method of a Schmitt trigger, the two counting signals are converted into two counting square waves. Each of these square waves has two states: high voltage and low voltage. The corresponding combinations result in four guaranteed counting states: low-low, low-high, high-high, and high-low, with no other possibilities.
[0062] Based on the periodicity and sequence of these four counting states, they can be respectively represented by a 360-degree forward or reverse rotation, so as to realize the counting of the forward and reverse rotation of the rotating device.
[0063] Counting using these four counting states has the following functional characteristics:
[0064] It can distinguish between forward and reverse rotations, with 4 counting states. The state transition order is different for forward and reverse rotations, such as...
[0065] Positive direction: Low-low => Low-high => High-high => High-low => Low-low
[0066] Reverse: Low-low <= Low-high <= High-high <= High-low <= Low-low
[0067] The sequential determination of the four counting state transitions can prevent incorrect counting due to abnormal transitions caused by external interference, thereby improving the accuracy and anti-interference of counting. Abnormal state transitions include: low-low <=> high-high, low-high <=> high-low. If such state transitions occur due to interference, they will be detected and ignored to prevent incorrect counting.
[0068] After completing several cycles of four counting states, the counting signal within the cycle is statistically analyzed to obtain a new center value. The center value offset direction is obtained by comparing it with the current center value, and the center value is calibrated according to this direction to adapt to the influence of environmental changes and external interference on the counting signal and enhance the counting accuracy of the counting device.
[0069] When significant changes occur in the counting environment, such as large temperature fluctuations, significant deformation of tray 9, or replacement of tray 9, the normal transition of the counting state may not be possible because the actual center value has changed considerably. In such cases, continuous tracking of the changes in the two counting signals can automatically determine a new center value based on statistically derived rising and falling trends, allowing counting to continue without manual intervention, thus enhancing the environmental adaptability and ease of use of the counting device.
[0070] In this embodiment, the counting device outputs the following: when counting occurs, the count value is accumulated and maintained internally, ready for query or periodic notification. Upon detecting a count, the counting device automatically increments and maintains the count value in its internal memory (such as the microcontroller's memory). The count data is transmitted as a byte stream in a predetermined format using a Universal Synchronous Asynchronous Receiver / Transmitter (UART). UART is a universal and reliable bidirectional digital signal transmission interface. Data is transmitted in bit order as a byte stream. Various microcontrollers and PCs (personal computers) support this interface, which avoids the interference issues common with pulse signal interfaces. In other words, this counting device accumulates and maintains the count value internally, outputting positive and negative count values via a reliable Universal Asynchronous Serial Transmitter (UART) method. It can periodically and proactively send counts when there are count changes, or send them on demand according to the application's requirements, thus overcoming the shortcomings of using voltage pulse output.
[0071] The above are merely preferred embodiments of the present invention and are not intended to limit the present invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A rotation counting device based on electromagnetic signals, comprising a tray rotating around its center and a rotation detection device located above the tray and fixed in place, wherein the upper surface of the tray is partially metallized, and the rotation detection device includes a PCB coil, a pulse excitation circuit, and a signal processing circuit, wherein the PCB coil includes a transmitting coil parallel to the upper plane of the tray and at least two receiving coils arranged circumferentially at equal angles along the center of the transmitting coil, characterized in that, The signal processing circuit includes a voltage amplification and detection circuit and a signal processor. One end of each receiving coil is connected to the input terminal of the voltage amplification and detection circuit. The pulse excitation circuit includes a resistor R4, a capacitor C4, an inverter P1, and an inverter P2. The voltage output terminal of the signal processor is connected in series with the capacitor C4, the inverter P1, and the inverter P2 in sequence. One end of the resistor R4 is grounded, and the other end is connected between the capacitor C4 and the inverter P1, so that the capacitor C4 and the resistor R4 form a differentiating circuit. The signal processor controls the switching of high and low voltages to generate a rectangular signal. The differentiating circuit detects the edge spike signal of the rectangular signal. After passing through the inverter P1, the edge spike signal is coupled to the voltage amplification and detection circuit through capacitor C5. After passing through the inverter P2, it is coupled to the transmitting coil through capacitor C6. After receiving the edge spike signal, the transmitting coil generates an electromagnetic signal and transmits it to the tray. The receiving coil receives the electromagnetic signal reflected back from the tray. After receiving the electromagnetic signal, capacitor C1 in the voltage amplification and detection circuit discharges. After the rectangular signal ends, the signal processor collects the remaining voltage signal of capacitor C1. Based on the voltage signal, the maximum and minimum values of the voltage signal are calculated. Based on the maximum and minimum values of the voltage signal, the voltage signal is converted into a square wave. Based on the square wave, the rotation direction and number of rotations of the tray are obtained.
2. The electromagnetic signal-based rotation counting device according to claim 1, characterized in that, The voltage amplification and detection circuit includes a transistor Q1 and a capacitor C1. One end of the receiving coil is connected to the base of the transistor Q1, one end of the collector of the transistor Q1 is connected to one end of the capacitor C1 and the signal processor, the other end of the capacitor C1 is grounded, and the emitter of the transistor Q1 is connected to the capacitor C5.
3. The electromagnetic signal-based rotation counting device according to claim 2, characterized in that, In the initial state, capacitor C1 in the voltage amplification and detection circuit is charged.
4. The electromagnetic signal-based rotation counting device according to claim 3, characterized in that, The edge spike signal is the start signal of the voltage amplification and detection circuit.
5. The electromagnetic signal-based rotation counting device according to claim 4, characterized in that, After receiving the edge-sharp pulse signal, the transmitting coil generates an electromagnetic signal and transmits it to the tray. The receiving coil receives the electromagnetic signal reflected back from the tray.
6. The electromagnetic signal-based rotation counting device according to claim 5, characterized in that, After the receiving coil receives the electromagnetic signal, the edge spike pulse signal simultaneously activates the voltage amplification and detection circuit, the capacitor C1 discharges, and after the rectangular signal ends, the signal processor collects the remaining voltage of the capacitor C1.
7. The electromagnetic signal-based rotation counting device according to claim 6, characterized in that, The metal area covered by the tray is semi-circular.
8. A rotation counting method based on electromagnetic signals, employing the rotation counting device based on electromagnetic signals as described in any one of claims 1-7, characterized in that, include: The signal processor controls the switching of its voltage high and low to generate a rectangular signal; The differentiating circuit detects the edge spike pulse signal of the rectangular signal; The edge spike signal, after passing through inverter P1, is coupled to the voltage amplification and detection circuit through capacitor C5, serving as the start signal for the voltage amplification and detection circuit. The edge spike signal is then coupled to the transmitting coil through capacitor C6 after passing through inverter P2; After receiving the edge spike pulse signal, the transmitting coil generates an electromagnetic signal and transmits it to the tray; the receiving coil receives the electromagnetic signal reflected back from the tray. After the receiving coil receives the electromagnetic signal, the capacitor C1 in the voltage amplification and detection circuit discharges. After the rectangular signal ends, the signal processor collects the remaining voltage signal of the capacitor C1. Based on the voltage signal, the maximum and minimum values of the voltage signal are calculated. Based on the maximum and minimum values of the voltage signal, the voltage signal is converted into a square wave; Based on the square wave, the rotation direction and number of rotations of the tray are obtained.
9. The rotation counting method based on electromagnetic signals according to claim 8, characterized in that, In the initial state, capacitor C1 in the voltage amplification and detection circuit is charged.
10. The rotation counting method based on electromagnetic signals according to claim 9, characterized in that, Based on the square wave, obtaining the rotation direction and number of rotations of the tray includes: The square wave includes two states: high voltage and low voltage. The two square waves formed by the receiving coils have four states, including low voltage and low voltage, low voltage and high voltage, high voltage and high voltage, and high voltage and low voltage. Based on the four states, the rotation direction and number of rotations of the tray are obtained.
Citation Information
Patent Citations
Rotation detection device
CN111174856A
Anti-radio frequency interference metering module and rotary counting device
CN214951597U