Waveform quantization apparatus and method

By using waveform quantization devices and methods, the negative signal of the electrotherapy waveform is converted into a positive signal and integrated, which solves the problem of charge accumulation caused by waveform asymmetry in electrotherapy, realizes the quantitative detection of charge, and ensures the safety of electrotherapy.

CN115714591BActive Publication Date: 2026-06-12ANYANG XIANGYU MEDICAL EQUIP

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ANYANG XIANGYU MEDICAL EQUIP
Filing Date
2022-11-03
Publication Date
2026-06-12

AI Technical Summary

Technical Problem

Existing electrotherapy equipment cannot quantify and judge when the output waveform is asymmetrical or defective, leading to the accumulation of charge, which can easily cause electrical burns, and there is a lack of methods to measure the amount of charge.

Method used

A waveform quantization device is provided, including a waveform processing circuit and an MCU. The device converts the waveform into a positive signal by superimposing the negative and positive signals, and performs integration processing using the MCU to determine whether the charge quantity is within a preset range.

🎯Benefits of technology

It enables quantitative judgment of waveform symmetry and charge accumulation, avoiding electrical burns and ensuring the safety of the electrotherapy process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115714591B_ABST
    Figure CN115714591B_ABST
Patent Text Reader

Abstract

The application discloses a waveform quantization device and method, and relates to the field of medical waveforms. The application provides a waveform quantization device, which comprises a waveform processing circuit and an MCU, wherein the waveform processing circuit can superimpose negative signals and positive signals of waveforms in a waveform output loop, and convert negative signals in the superimposed results into positive signals; the output end of the waveform processing circuit is connected with the MCU; the MCU can quantize signals output by the waveform processing circuit through integral processing; whether the accumulation of the charge quantity exceeds the range that can be accepted by a user is determined by judging the result of the quantization, and a quantization mode for detecting whether the waveforms are completely symmetrical and whether the accumulation of the charge quantity exceeds the range is provided. The application also provides a waveform quantization method, which is applied to a device comprising the above-mentioned waveform processing circuit and MCU, and corresponds to the waveform quantization device, and can also achieve waveform quantization processing and analysis.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of medical waveforms, and in particular to a waveform quantization device and method. Background Technology

[0002] In recent years, the number of electrotherapy products has gradually increased. However, electrical burns are prone to occur during electrotherapy. These burns are usually caused by problems such as poor electrode contact, insufficient contact area, and incorrect electrotherapy output waveform. Specifically, the output waveform may be asymmetrical or defective, resulting in a non-zero accumulated charge. When the accumulated charge reaches a certain value, electrical burns will occur. Poor electrode contact and insufficient contact area can be ruled out through observation, but problems with the electrotherapy output waveform require professional investigation.

[0003] The current troubleshooting of electrotherapy output waveform problems is mainly done using an oscilloscope. An oscilloscope can show conventional parameters such as waveform shape, amplitude, and frequency, but it cannot determine whether the waveform is completely symmetrical. There is currently no quantitative method for judging waveform symmetry, nor can it measure the amount of accumulated charge. Summary of the Invention

[0004] The purpose of this application is to provide a waveform quantization device and method that can quantize waveforms and determine whether the waveform is completely symmetrical or whether there is an accumulation of charge based on the quantization results.

[0005] To solve the above-mentioned technical problems, this application provides a waveform quantization device, including: a waveform processing circuit and an MCU;

[0006] The first end of the waveform processing circuit is connected to the waveform output circuit, and the second end of the waveform processing circuit is connected to the detection end of the MCU. It is used to superimpose the negative signal and the positive signal of the waveform in the waveform output circuit and convert the negative signal in the superposition result into a positive signal.

[0007] The MCU is used to acquire the signal output by the waveform processing circuit, process the signal according to the integration method to obtain the quantization result, and determine whether the quantization result meets the preset conditions. If yes, it is determined that the amount of charge accumulated in the waveform is within the preset range; otherwise, it is determined that the amount of charge accumulated in the waveform exceeds the preset range.

[0008] Preferably, the waveform processing circuit includes: a first operational amplifier, a second operational amplifier, a first resistor, a second resistor, a third resistor, a fourth resistor, a fifth resistor, a first diode, and a second diode;

[0009] Among them, the first end of the first resistor is connected to the waveform output circuit and the first end of the fourth resistor;

[0010] The first terminal of the first operational amplifier is connected to the first terminal of the first diode, the first terminal of the second resistor, and the second terminal of the first resistor. The second terminal of the first operational amplifier is grounded. The third terminal of the first operational amplifier is connected to the second terminal of the first diode and the first terminal of the second diode.

[0011] The second terminal of the second diode is connected to the second terminal of the second resistor and the first terminal of the third resistor;

[0012] The second terminal of the third resistor is connected to the first terminal of the second operational amplifier, the second terminal of the fourth resistor, and the first terminal of the fifth resistor;

[0013] The second terminal of the second operational amplifier is grounded, and the third terminal of the second operational amplifier is connected to the second terminal of the fifth resistor and the detection terminal of the MCU.

[0014] Preferably, the waveform processing circuit further includes: a first transistor;

[0015] The first terminal of the first transistor is connected to the second terminal of the fourth resistor and the first terminal of the fifth resistor. The second terminal of the first transistor is connected to the second terminal of the fifth resistor, the third terminal of the second operational amplifier, and the detection terminal of the MCU. The third terminal of the first transistor is connected to a preset power supply to clamp the voltage of the third terminal of the second operational amplifier within a preset voltage range.

[0016] Preferably, it further includes: a positive voltage control circuit and a negative voltage control circuit, used to control the voltage to drop to a preset voltage value;

[0017] The positive voltage control circuit includes a sixth resistor, a seventh resistor, a first MOSFET, and a first capacitor; the negative voltage control circuit includes an eighth resistor, a ninth resistor, a second MOSFET, and a second capacitor.

[0018] Among them, the first end of the seventh resistor is connected to the waveform output after PWM modulation, and the second end of the seventh resistor is connected to the control terminal of the first MOSFET.

[0019] The first terminal of the first MOSFET is connected to the second terminal of the sixth resistor, and the second terminal of the first MOSFET is connected to the first terminal of the first capacitor.

[0020] The first terminal of the sixth resistor is connected to the positive terminal of the power supply;

[0021] The second terminal of the first capacitor is grounded;

[0022] The first end of the ninth resistor is connected to the waveform output after PWM modulation, and the second end of the ninth resistor is connected to the control terminal of the second MOSFET.

[0023] The first terminal of the second MOSFET is connected to the second terminal of the eighth resistor, and the second terminal of the second MOSFET is connected to the first terminal of the second capacitor.

[0024] The first terminal of the eighth resistor is connected to the negative terminal of the power supply;

[0025] The second terminal of the second capacitor is grounded.

[0026] Preferably, it further includes: a positive voltage detection circuit and a negative voltage detection circuit, used to convert the negative signal in the waveform into a positive signal and output it to the MCU, and to clamp the voltage at the detection terminal of the MCU within a preset voltage range. The MCU is also used to detect whether the voltage value after being controlled by the positive voltage control circuit and the negative voltage control circuit is the first preset voltage value.

[0027] If so, the voltage output through the positive and negative voltage control circuits meets the usage standards.

[0028] If not, the voltage output through the positive and negative voltage control circuits does not meet the usage standards;

[0029] The positive voltage detection circuit includes the tenth resistor, the eleventh resistor, the third diode, and the third capacitor; the negative voltage detection circuit includes the twelfth resistor, the thirteenth resistor, the fourteenth resistor, the third operational amplifier, the second transistor, and the fourth capacitor.

[0030] Among them, the first end of the tenth resistor is connected to the second end of the first MOSFET and the first end of the first capacitor, and the second end of the tenth resistor is connected to the first end of the eleventh resistor, the second end of the third diode and the first end of the third capacitor.

[0031] The second terminal of the eleventh resistor is grounded;

[0032] The first end of the third diode is connected to the power supply, and the second end of the third diode is connected to the first end of the second capacitor and the detection terminal of the MCU.

[0033] The second terminal of the third capacitor is grounded;

[0034] The first end of the twelfth resistor is connected to the second end of the second MOSFET and the first end of the second capacitor. The second end of the twelfth resistor is connected to the first end of the second transistor and the first end of the thirteenth resistor.

[0035] The second terminal of the thirteenth resistor is connected to the first terminal of the third operational amplifier and the first terminal of the fourteenth resistor;

[0036] The second terminal of the third operational amplifier is grounded, and the third terminal of the third operational amplifier is connected to the second terminal of the second transistor, the second terminal of the fourteenth resistor, the first terminal of the fourth capacitor, and the detection terminal of the MCU.

[0037] The third terminal of the second transistor is connected to the power supply;

[0038] The second terminal of the fourth capacitor is grounded.

[0039] Preferably, it further includes: a peak-to-peak detection circuit, used to convert the negative half-axis peak voltage into a positive half-axis peak voltage output when the input is a negative half-axis peak voltage, and to output a positive half-axis peak voltage when the input is a positive half-axis peak voltage. The MCU is also used to detect whether the peak-to-peak voltage value of the waveform is a second preset voltage value.

[0040] If so, the peak-to-peak voltage in the peak-to-peak detection circuit meets the usage standard;

[0041] If not, the peak-to-peak voltage in the peak-to-peak detection circuit does not meet the usage standard;

[0042] The peak-to-peak detection circuit includes a fourth operational amplifier, a fifth operational amplifier, a fifteenth resistor, a sixteenth resistor, a first switching device, a second switching device, a fifth capacitor, and a sixth capacitor;

[0043] Among them, the first terminal of the fourth operational amplifier is connected to the waveform output circuit and the first terminal of the fifteenth resistor, the second terminal of the fourth operational amplifier is connected to the third terminal of the fourth operational amplifier, and the third terminal of the fourth operational amplifier is connected to the first terminal of the first switching device.

[0044] The second terminal of the first switching device is connected to the control terminal of the MCU, and the third terminal of the first switching device is connected to the detection terminal of the MCU and the first terminal of the fifth capacitor.

[0045] The second terminal of the fifth capacitor is grounded;

[0046] The second terminal of the fifteenth resistor is connected to the first terminal of the sixteenth resistor and the first terminal of the fifth operational amplifier;

[0047] The second terminal of the fifth operational amplifier is grounded, and the third terminal of the fifth operational amplifier is connected to the second terminal of the sixteenth resistor and the first terminal of the second switching device.

[0048] The second terminal of the second switching device is connected to the control terminal of the MCU, and the third terminal of the second switching device is connected to the detection terminal of the MCU and the first terminal of the sixth capacitor.

[0049] The second terminal of the sixth capacitor is grounded.

[0050] Preferably, the MCU is also used to determine the cause based on the accumulation of charge in the waveform exceeding a preset range; wherein the cause includes any one or combination of the voltage value controlled by the voltage control circuit not being the first preset voltage value and the peak-to-peak voltage value of the waveform not being the second preset voltage value.

[0051] To address the aforementioned technical problems, this application also provides a waveform quantization method applied to a waveform quantization device comprising a waveform processing circuit and an MCU. The waveform processing circuit is used to superimpose the negative and positive signals of the waveform in the waveform output loop, and convert the negative signal in the superposition result into a positive signal. The method includes:

[0052] Acquire the signal output by the waveform processing circuit;

[0053] The signal is processed using an integral method to obtain the quantization result;

[0054] Determine whether the quantification results meet the preset conditions;

[0055] If so, then determine that the amount of charge accumulated in the waveform is within the preset range;

[0056] If not, then it is determined that the accumulated charge in the waveform exceeds the preset range.

[0057] Preferably, processing the signal using an integral processing method to obtain the quantization result includes:

[0058] Select at least one time period on the waveform;

[0059] Obtain the integral values ​​obtained by definite integral operation for at least one time period.

[0060] Preferably, determining whether the quantification result meets the preset conditions includes:

[0061] Determine whether each integral value is less than or equal to a preset integral value;

[0062] If all integral values ​​are less than or equal to the preset integral value and the total integral value obtained by adding all integral values ​​is less than or equal to the preset integral value, then the amount of charge accumulated in the shape is determined to be within the preset range.

[0063] If all integral values ​​are less than or equal to the preset integral value and the total integral value obtained by adding all integral values ​​is greater than the preset integral value, then it is determined that the accumulated charge in the waveform exceeds the preset range.

[0064] If at least one integral value is greater than a preset integral value, it is determined that the accumulated charge in the waveform exceeds the preset range.

[0065] This application provides a waveform quantization device, which includes a waveform processing circuit and an MCU capable of superimposing negative and positive signals of a waveform in a waveform output circuit and converting the negative signal in the superposition result into a positive signal. The MCU is connected to the output terminal of the waveform processing circuit. The MCU can perform quantization processing on the signal output by the waveform processing circuit using an integral processing method. By judging the result of the quantization processing, it can determine whether the accumulation of charge exceeds the range acceptable to the user. This provides a quantization method for detecting whether the waveform is completely symmetrical and whether the accumulation of charge exceeds the range.

[0066] The waveform quantization method provided in this application is applied to a waveform processing circuit that can superimpose negative and positive signals in a medical waveform and convert the negative signal in the superposition result into a positive signal. The method acquires the signal of the output waveform after circuit processing, processes the signal according to the quantization method to obtain the quantization result, and determines whether the accumulation of charge in the waveform is within a certain range by judging whether the quantization result meets the preset conditions. If the accumulation of charge in the waveform is within the specified range, it can be determined that the electrotherapy waveform will not cause electric burns. The method provides a waveform symmetry quantization method by quantizing the waveform and measuring the quantized result to judge whether the waveform is completely symmetrical, and can measure the amount of charge. Attached Figure Description

[0067] To more clearly illustrate the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0068] Figure 1 A structural diagram of a waveform quantization device provided in an embodiment of this application;

[0069] Figure 2 This is a waveform processing circuit structure diagram according to another embodiment of this application;

[0070] Figure 3 A structural diagram of a positive pressure control circuit provided in another embodiment of this application;

[0071] Figure 4 A structural diagram of a negative pressure control circuit provided in another embodiment of this application;

[0072] Figure 5 This is a structural diagram of a positive pressure detection circuit provided in another embodiment of this application;

[0073] Figure 6 This is a structural diagram of a negative pressure detection circuit provided in another embodiment of this application;

[0074] Figure 7 This is a schematic diagram of a peak-to-peak detection circuit according to another embodiment of this application;

[0075] Figure 8 A flowchart of a waveform quantization method provided in another embodiment of this application. Detailed Implementation

[0076] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.

[0077] Due to waveform asymmetry or defects, charge may accumulate. When the charge accumulates to a certain value, it will cause discomfort to the user and, in severe cases, electrical burns. Currently, the causes of electrical burns are only investigated from the external perspective, without detailed quantitative testing of internal design defects. During the design process, only the shape and amplitude of the electrotherapy output waveform are observed. This method can detect severe waveform asymmetry, but it cannot detect incomplete waveforms. Furthermore, the symmetry of the waveform at each moment is not tested in detail.

[0078] The core of this application is to provide a waveform quantization device and method, which includes a waveform processing circuit and a micro control unit (MCU) capable of superimposing the negative signal and positive signal of the waveform in the waveform output circuit and converting the negative signal in the superposition result into a positive signal. The MCU can process and quantize the signal of the output waveform after processing by the waveform processing circuit according to the integration processing method, so as to determine whether the amount of charge accumulated in the waveform will cause electric burns to the human body based on the quantization result.

[0079] This application mainly focuses on the quantitative analysis of electrical burns caused by charge accumulation or discomfort caused by electrical stimulation during electrotherapy. It mainly involves the integration and quantification of waveforms at different times. In the case of charge accumulation, ideally, the accumulation of positive and negative charges will eventually cancel each other out to achieve zero charge accumulation. However, due to issues such as incomplete asymmetry and defects in waveforms during normal use, there will be a certain amount of charge accumulation. When the amount of charge accumulation exceeds a certain value, it will cause electrical stimulation or even electrical burns to the user.

[0080] It should be noted that the waveform quantization device and method mentioned in this application can be implemented by an MCU or other types of control devices, and there is no limitation on this, nor does it affect the implementation of this technical solution. The processing of positive and negative signals in the waveform mentioned in this application can be implemented by a waveform processing circuit, or by other circuits or modules, and there is no limitation on this, nor does it affect the implementation of this technical solution.

[0081] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0082] This application provides a waveform quantization apparatus. Figure 1 A structural diagram of a waveform quantization device provided in an embodiment of this application; as shown Figure 1 The device includes: waveform processing circuit 1 and MCU 3.

[0083] The first end of the waveform processing circuit 1 is connected to the waveform output circuit 2, and the second end of the waveform processing circuit 1 is connected to the detection end of the MCU 3. It is used to superimpose the negative signal and the positive signal of the waveform in the waveform output circuit 2, and convert the negative signal in the superposition result into a positive signal.

[0084] MCU3 is used to acquire the signal output by waveform processing circuit 1, process the signal according to the integration method to obtain the quantization result, and determine whether the quantization result meets the preset conditions. If yes, it is determined that the amount of charge accumulated in the waveform is within the preset range; otherwise, it is determined that the amount of charge accumulated in the waveform exceeds the preset range.

[0085] In specific implementation, the input terminal of waveform processing circuit 1 is connected to waveform output circuit 2, which is a branch of the circuit after voltage reduction control. The output terminal of waveform processing circuit 1 is connected to the analog-to-digital converter (ADC) of MCU3. The electrotherapy output waveform passes through waveform processing circuit 1, which superimposes the positive and negative signals in the electrotherapy output waveform. The superimposed result is then converted from a negative signal to a positive signal by an inverting amplifier circuit and output to the ADC detection terminal of MCU3. After receiving the processed output waveform signal, MCU3 performs integral processing. The corresponding waveform function expression has been programmed in machine language, and the program's running cycle time can be determined. A definite integral function is used to calculate the definite integral of the function expression of the predicted waveform over time. By performing definite integral operations on the function expression of different time periods, the program can output the corresponding definite integral value. It can also perform definite integral operations on multiple small time periods, and then sum the integral values ​​of each small time period to obtain the result value. By comparing the integral value of a single time period and the sum of the integral values ​​of multiple small time periods with the preset value, it can be determined whether the accumulated charge exceeds the preset range.

[0086] If the integral values ​​of each time period obtained by the definite integral calculation of the electrotherapy output waveform signal by MCU3 are all less than the preset value, in order to ensure that the cumulative charge in the entire electrotherapy waveform does not exceed the preset range, the preset range is the range that will not cause electric burns or electric stimulation and other discomfort, and the user's experience of the entire electrotherapy process is normal. It is also necessary to add up the integral values ​​of each time period to obtain the total integral value, and the total integral value does not exceed the preset value. Only in this way can we ensure that the user will not experience electric stimulation or electric burns during electrotherapy.

[0087] It should be noted that the preset value in this embodiment is the critical value at which the electrotherapy waveform causes electric burns to the user. This value can be obtained from a large number of simulated human experiments, or it can be a value that the setter obtains in advance and sets in MCU3.

[0088] It should be noted that the data required for definite integral calculation of the waveform in this embodiment, including parameters such as function expression, waveform start time, period, and phase, has been stored in MCU3 and can be directly called. The smallest unit of definite integral calculation is the smallest period of the waveform, and the largest unit is the entire waveform segment. Since the electrotherapy waveform is set according to the treatment method determined by the doctor, the entire treatment waveform will be spliced ​​together. Therefore, definite integral calculation of a single sub-waveform can also be performed. Integral calculations for different event period segments can be obtained by adding and subtracting the integrals of each sub-waveform segment.

[0089] It should be noted that the MCU3 in this embodiment can be other types of controllers, as long as the controller can store a pre-set integration calculation program and can complete the integration calculation.

[0090] This application provides a waveform quantization device, which includes a waveform processing circuit 1 and an MCU3 capable of superimposing the negative and positive signals of the waveform in the waveform output circuit 2 and converting the negative signal in the superposition result into a positive signal. The MCU3 is connected to the output terminal of the waveform processing circuit 1. The MCU3 can perform quantization processing on the signal output by the waveform processing circuit 1 by integration processing. By judging the result of the quantization processing, it can determine whether the accumulation of charge exceeds the range acceptable to the user. This provides a quantization method for detecting whether the waveform is completely symmetrical and whether the accumulation of charge exceeds the range.

[0091] The above embodiments include a waveform processing circuit that can superimpose the negative and positive signals of the waveform in the waveform output circuit, and convert the negative signal in the superposition result into a positive signal, which is then output to the ADC detection terminal of the MCU for integration and judgment by the MCU. Based on the above embodiments, as a preferred embodiment, Figure 2 This is a waveform processing circuit structure diagram according to another embodiment of this application; as shown Figure 1 As shown, the waveform processing circuit includes: a first operational amplifier, a second operational amplifier, a first resistor, a second resistor, a third resistor, a fourth resistor, a fifth resistor, a first diode, and a second diode.

[0092] In the diagram, the first resistor is R1, the second resistor is R2, the third resistor is R3, the fourth resistor is R4, the fifth resistor is R5, the first operational amplifier is U1, the second operational amplifier is U2, the first diode is D1, and the second diode is D2.

[0093] like Figure 2 As shown, the connection method within the waveform processing circuit is as follows:

[0094] The first terminal of R1 is connected to the waveform output circuit and the first terminal of R4; the first terminal of U1 is connected to the first terminal of D1, the first terminal of R2, and the second terminal of R1, and the second terminal of U1 is grounded; the third terminal of U1 is connected to the second terminal of D1 and the first terminal of D2; the second terminal of D2 is connected to the second terminal of R2 and the first terminal of R3; the second terminal of R3 is connected to the first terminal of U2, the second terminal of R4, and the first terminal of R5; the second terminal of U2 is grounded; the third terminal of U2 is connected to the second terminal of R5 and the detection terminal of the MCU.

[0095] In practical implementation, when the voltage input to the waveform output circuit is positive, D1 is cut off and D2 is turned on. R1, R2, and U1 together form an inverting amplifier circuit with a gain of -1. R3, R4, R5, and U2 together form an inverting adder circuit. The gain of the branch through resistor R4 is -1, and the gain of the branch through R3 is -2. After equivalence, for a positive voltage input, the gain is 1, and the input impedance at this time is R1||R4. When the voltage input to the waveform output circuit is negative, D1 is turned on and D2 is cut off. At this time, the function of U1 is to clamp the potential of the left end of R2 to 0V, while the feedback effect of U2 makes the potential of the right end of R3 0. This is because the operational amplifier has the characteristic of virtual short circuit. When no power supply voltage is applied to the output terminal, the positive input terminal and the inverting input terminal are considered to release the same voltage. Therefore, the potentials at both ends of branch R2 and R3 are equal and there is no current. At this point, the entire circuit is actually an inverting amplifier circuit with a gain of -1 composed of R4, R5, and U2. The input impedance of the circuit is still: R1||R4. Based on this, it can be concluded that the waveform processing circuit is equivalent to taking the absolute value.

[0096] It should be noted that the final amplification factor obtained in this embodiment is 1. It can be understood that when the amplification factor is related to the resistance, the amplification factor can be adjusted and is not limited. However, this solution does not require a large amplification factor because a voltage divider is performed before the waveform output circuit is connected to the waveform processing circuit to obtain a stable voltage, and the voltage value is not large.

[0097] It should be noted that the first operational amplifier, the second operational amplifier, the first resistor, the second resistor, the third resistor, the fourth resistor, the fifth resistor, the first diode, and the second diode in this embodiment are merely preferred embodiments, and the connection between them is only based on this embodiment. In practical applications, the number, type, and connection method of the devices are not limited, as long as they can superimpose the negative and positive signals of the waveform in the waveform output circuit and convert the negative signal in the superposition result into a positive signal to be output to the ADC detection terminal of the MCU.

[0098] The specific implementation of the waveform processing circuit provided in this embodiment uses an operational amplifier, resistors, and unidirectional diodes to process negative signals in the waveform, converting the negative signals into positive signals that the MCU can receive. The circuit structure is simple and can accomplish the purpose of waveform processing.

[0099] Based on the detailed description of the internal components and structure of the waveform processing circuit in the above embodiments, this embodiment proposes that the waveform processing circuit also includes a first transistor, such as... Figure 2 As shown, the first transistor is Q1.

[0100] In this configuration, the first terminal of Q1 is connected to the second terminal of R4 and the first terminal of R5. The second terminal of Q1 is connected to the second terminal of R5, the third terminal of U2, and the detection terminal of the MCU. The third terminal of Q1 is connected to a preset power supply. Q1 is used to clamp the voltage at the third terminal of U2 within a preset voltage range.

[0101] Figure 2 Q1 in the circuit is a PNP transistor. The three terminals of a PNP transistor are the base, collector, and emitter. Correspondingly, the base of the PNP transistor is connected to the preset power supply, and the collector and emitter are connected in parallel across R5. In the waveform processing circuit, the PNP transistor protects the MCU from excessive voltage, preventing damage. Understandably, the voltage received by the MCU cannot be too high, typically around 3.3V.

[0102] It should be noted that the use of a PNP transistor to protect the MCU in this embodiment is merely a preferred embodiment; a Zener diode or voltage regulator can also be used, and there is no limitation in practical applications. The connection method of the PNP transistor in this embodiment is determined based on the specific connection of the above circuit and is not limited thereto.

[0103] In this embodiment, the transistor controls the output voltage of the waveform processing circuit, thereby controlling the port voltage of the MCU and preventing excessive output voltage from damaging the MCU.

[0104] In the above embodiments, the input terminal of the waveform processing circuit is connected to the waveform output circuit. Based on the above embodiments, Figure 3 A structural diagram of a positive pressure control circuit provided in another embodiment of this application; Figure 4 This is a structural diagram of a negative pressure control circuit provided in another embodiment of this application; as shown below. Figure 3 , Figure 4 As shown, the waveform output circuit includes a positive voltage control circuit and a negative voltage control circuit, which are used to control the voltage to drop to a preset voltage value.

[0105] The positive voltage control circuit includes a sixth resistor, a seventh resistor, a first MOSFET, and a first capacitor; the negative voltage control circuit includes an eighth resistor, a ninth resistor, a second MOSFET, and a second capacitor.

[0106] Among them, the sixth resistor is Figure 3 In the diagram, R6 is the seventh resistor, R7 is the seventh resistor, Q2 is the first MOSFET, C1 is the first capacitor, and correspondingly, the eighth resistor is... Figure 4 In the circuit, R8 is the ninth resistor, R9 is the ninth resistor, Q3 is the second MOSFET, and C2 is the second capacitor.

[0107] like Figure 3As shown, the connection method of the positive voltage control circuit in the waveform processing circuit is as follows:

[0108] The first terminal of R7 is connected to the waveform output after PWM modulation. The second terminal of R7 is connected to the control terminal of Q2. The first terminal of Q2 is connected to the second terminal of R6. The second terminal of Q2 is connected to the first terminal of C1. The first terminal of R6 is connected to the positive terminal of the power supply. The second terminal of C1 is grounded.

[0109] like Figure 4 As shown, the connection method of the negative voltage control circuit in the waveform processing circuit is as follows:

[0110] The first terminal of R9 is connected to the waveform output after PWM modulation. The second terminal of R9 is connected to the control terminal of Q3. The first terminal of Q3 is connected to the second terminal of R8. The second terminal of Q3 is connected to the first terminal of C2. The first terminal of R8 is connected to the negative terminal of the power supply. The second terminal of C2 is grounded.

[0111] In practical implementation, the positive voltage control circuit and the negative voltage control circuit control the total power supply of the waveform output. Utilizing the characteristic of the MOSFET that it only turns on when the gate voltage reaches a preset value, the total power supply voltage is controlled. R6, connected to the total voltage, is used for voltage division, thereby achieving voltage reduction. Correspondingly, the negative voltage control circuit uses the same components and connection method as the positive voltage control circuit. Resistor R8 is used for voltage division, and MOSFET Q3 is used to turn on when the gate voltage reaches the preset value, outputting the controlled voltage.

[0112] It should be noted that the preset value in this embodiment is the stable voltage value of the waveform output. The output voltage value can be reduced by devices such as resistors and MOSFETs. This is only a preferred embodiment. There are no limitations on the resistance value or number of resistors, nor on the MOSFET. Other power electronic devices can also be used, as long as they meet the purpose of turning on the circuit when the voltage reaches a certain value. It can be understood that the connection method in this embodiment is only based on this embodiment.

[0113] This embodiment controls the total power supply voltage by setting up a voltage control circuit and a negative voltage control circuit, thereby completing the voltage reduction and providing the required voltage value to form a waveform output circuit. For example, if the total power supply voltage is 150V, the required voltage value can be obtained after voltage control.

[0114] The above embodiments describe in detail the total power supply voltage control of the waveform output. However, when the amplitudes of the positive and negative half-axis of the waveform are inconsistent, the charge accumulation of the final output waveform will be outside the safe range. For example, the target waveform should have a peak-to-peak value of ±50V, but the actual positive voltage may reach +60V, while the negative voltage may only be -30V. In this case, no matter how the voltage control circuit controls it, it will not achieve a waveform with a good symmetry of ±50V peak-to-peak value. Therefore, as a preferred embodiment, this application detects the positive and negative voltages of the positive and negative waveforms from a hardware perspective. By detecting them, it can be determined which voltage value is insufficient, which facilitates subsequent voltage compensation for this circuit.

[0115] Figure 5 This is a structural diagram of a positive pressure detection circuit provided in another embodiment of this application; Figure 6 This is a structural diagram of a negative pressure detection circuit provided in another embodiment of this application; as shown below. Figure 5 , Figure 6 As shown, the voltage detection circuit includes a positive voltage detection circuit and a negative voltage detection circuit, which are used to convert the negative signal in the waveform into a positive signal and output it to the MCU, and clamp the voltage at the detection terminal of the MCU within a preset voltage range. The MCU is also used to detect whether the voltage value after being controlled by the positive voltage control circuit and the negative voltage control circuit is the first preset voltage value; if so, the voltage output by the positive voltage control circuit and the negative voltage control circuit meets the usage standard; if not, the voltage output by the positive voltage control circuit and the negative voltage control circuit does not meet the usage standard.

[0116] The positive voltage detection circuit includes a tenth resistor, an eleventh resistor, a third diode, and a third capacitor; the negative voltage detection circuit includes a twelfth resistor, a thirteenth resistor, a fourteenth resistor, a third operational amplifier, a second transistor, and a fourth capacitor. Figure 5 , Figure 6 As shown, the tenth resistor is R10, the eleventh resistor is R11, the twelfth resistor is R12, the thirteenth resistor is R13, the fourteenth resistor is R14, the third diode is D3, the third capacitor is C3, the fourth capacitor is C4, the third operational amplifier is U3, and the second transistor is Q4.

[0117] like Figure 5 As shown, its connection method is as follows:

[0118] In the positive pressure detection circuit, the first end of R10 is connected to the second end of Q2 and the first end of C1. The second end of R10 is connected to the first end of R11, the second end of D3 and the first end of C3. The second end of R11 is grounded. The first end of D3 is connected to the power supply. The second end of D3 is connected to the first end of C2 and the detection terminal of the MCU. The second end of C3 is grounded.

[0119] like Figure 6As shown, its connection method is as follows:

[0120] In the negative pressure detection circuit, the first terminal of R12 is connected to the second terminal of Q3 and the first terminal of C2. The second terminal of R12 is connected to the first terminal of Q4 and the first terminal of R13. The second terminal of R13 is connected to the first terminal of U3 and the first terminal of R14. The second terminal of U3 is grounded. The third terminal of U3 is connected to the second terminal of Q4, the second terminal of R14, the first terminal of C4, and the detection terminal of the MCU. The third terminal of Q4 is connected to the power supply, and the second terminal of C4 is grounded.

[0121] In this implementation, R10 and R11 are positive voltage divider resistors, D3 is a clamping transistor used to control the voltage value at the end of D3 connected to C2, protecting the MCU's detection port. C2 is an energy storage filter capacitor. Correspondingly, R12 and R13 are negative voltage divider resistors, R14 is a feedback resistor, and a transistor Q4 is included in the negative voltage detection circuit. In a preferred embodiment, Q4 can be a PNP transistor. The base of the PNP transistor is connected to the power supply, and the collector and emitter of the PNP transistor are connected in parallel across R9 and R10. The PNP transistor in the detection circuit protects the MCU from excessive voltage, preventing damage. It is understood that the voltage received by the MCU cannot be too high, generally around 3.3V. In this embodiment, the operational amplifier U3 converts the negative voltage to a positive voltage and connects it to the MCU's detection port, amplifying and inverting the negative voltage, similar to the function of the operational amplifier in the waveform processing circuit.

[0122] It is understood that the use of a PNP transistor to protect the MCU in this embodiment is merely a preferred embodiment; a Zener diode or voltage regulator can also be used, and there is no limitation in practical applications. The connection method of the PNP transistor in this embodiment is determined based on the specific connection of the above circuit and is not limited thereto.

[0123] It should be noted that the output voltage detection in this embodiment is set up with a positive voltage control circuit and a negative voltage control circuit. The resistors, capacitors, diodes and transistors in the circuit in this embodiment are only a preferred embodiment. The resistance value and number of resistors are not limited, and the circuit structure is not specifically limited. It is only necessary to realize the detection of positive and negative voltage.

[0124] It should be noted that the MCUs in the positive pressure detection circuit and the negative pressure detection circuit in this embodiment can be the same or different; no specific limitation is made in this regard.

[0125] This embodiment provides a detailed description of the voltage detection circuit, which includes both positive and negative voltage detection circuits. The voltage is detected by converting negative voltage into positive voltage and by voltage division. The detection method is performed by an MCU to avoid directly outputting voltage values ​​that do not meet the standards.

[0126] The above embodiments describe the control and detection of voltage in detail. Based on the above embodiments, as a preferred embodiment, the peak-to-peak value of the waveform output can also be detected. The peak-to-peak value detection circuit is used to convert the negative half-axis peak voltage into a positive half-axis peak voltage output when the input is a negative half-axis peak voltage, and to output a positive half-axis peak voltage when the input is a positive half-axis peak voltage.

[0127] The MCU is also used to detect whether the peak-to-peak voltage value of the waveform is the second preset voltage value. If it is, the peak-to-peak voltage in the peak-to-peak detection circuit meets the usage standard; otherwise, the peak-to-peak voltage in the peak-to-peak detection circuit does not meet the usage standard.

[0128] Figure 7 This is a schematic diagram of a peak-to-peak detection circuit according to another embodiment of this application; as shown below. Figure 7 As shown, the peak-to-peak detection circuit includes a fourth operational amplifier, a fifth operational amplifier, a fifteenth resistor, a sixteenth resistor, a first switching device, a second switching device, a fifth capacitor, and a sixth capacitor.

[0129] Among them, the fourth operational amplifier is U4, the corresponding fifth operational amplifier is U5, the fifteenth resistor is R15, the sixteenth resistor is R16, the first switching device is K1, the second switching device is K2, the fifth capacitor is C5, and the sixth capacitor is C6.

[0130] like Figure 7 As shown, the first terminal of U4 is connected to the waveform output circuit, the first terminal of R15, the second terminal of U4 is connected to the third terminal of U4, the third terminal of U4 is connected to the first terminal of K1, the second terminal of K1 is connected to the control terminal of the MCU, the third terminal of K1 is connected to the detection terminal of the MCU, the first terminal of C5, the second terminal of C5 is grounded, the second terminal of R15 is connected to the first terminal of R16, the first terminal of U5, the second terminal of U5 is grounded, the third terminal of U5 is connected to the second terminal of R16, the first terminal of K2, the second terminal of K2 is connected to the control terminal of the MCU, the third terminal of K2 is connected to the detection terminal of the MCU, the first terminal of C6, and the second terminal of C6 is grounded.

[0131] In practical implementation, the input of the peak-to-peak detection circuit is connected to the output of the waveform. It detects the peak-to-peak value of both the positive and negative half-axis waveforms. The positive half-axis waveform passes through U4 and SW1 (controlled by the MCU), which opens switch K1, outputting a positive voltage to the MCU's ADC detection port. The MCU then detects the peak value. Similarly, the negative half-axis peak detection works in the same way. The negative half-axis waveform passes through operational amplifier U5 and feedback resistor R16, and SW2 (controlled by the MCU), which opens switch K2, converting the negative peak voltage into a positive peak voltage and outputting it to the MCU. The MCU then detects the peak value.

[0132] It should be noted that the MCU in the peak-to-peak detection circuit of this embodiment can be the same or different, and there is no specific limitation on this.

[0133] It should be noted that the peak-to-peak detection circuit is set up for detecting the peak-to-peak value of the output voltage in this embodiment. The resistors, switches, and capacitors in the peak-to-peak detection circuit in this embodiment are merely a preferred embodiment. There are no limitations on the resistance value or the number of resistors, nor are there any specific limitations on the circuit structure. It is only necessary to achieve the detection of peak-to-peak voltage.

[0134] This embodiment provides a detailed description of the peak-to-peak detection circuit. By converting the peak value of the negative half-axis into a positive peak value and detecting the peak voltage, the detection method is performed by the MCU. This allows for timely detection of whether the peak-to-peak voltage is abnormal, thus avoiding the presence of non-standard peak-to-peak voltages.

[0135] The above embodiments perform detection from various angles, including not only calculating the charge amount through integration and detecting the accumulated charge, but also peak-to-peak value detection, voltage value detection, and so on. Compared to traditional design detection methods that add a sampling resistor to the output circuit to collect the circuit voltage, this approach offers a variety of detection methods and can provide detection feedback from multiple angles.

[0136] Based on the above embodiments, as a preferred embodiment, the MCU in this embodiment is further used to determine the cause based on the charge accumulation in the waveform exceeding a preset range; wherein, the cause includes any one or combination of the voltage value controlled by the voltage control circuit not being the first preset voltage value and the peak-to-peak voltage value of the waveform not being the second preset voltage value.

[0137] This application includes the detection of charge accumulation, peak-to-peak value, and control voltage, which complete the detection and feedback of waveform from different perspectives. All detections are controlled by an MCU. It is understood that the MCUs for multiple detections can be the same or multiple, and there is no limitation on this. If there are multiple MCUs for multiple detections, the multiple MCUs can establish communication and exchange information with each other.

[0138] In practice, the detection is performed from three perspectives: peak-to-peak voltage, output voltage, and charge accumulation. If the charge accumulation exceeds the preset range, that is, the charge in the waveform exceeds the user's acceptable range, it may cause electric burns. The peak-to-peak voltage and output voltage detected can also be used to determine which one is causing the excessive charge accumulation. The cause may be a single factor, such as an excessively large peak-to-peak voltage or an output voltage that is not within the standard range. It may also be caused by multiple factors, such as an output voltage that is not within the standard range or an excessively large peak-to-peak voltage.

[0139] It should be noted that the detection method combining peak-to-peak value, output voltage, and charge accumulation in this embodiment is merely a preferred embodiment and is not intended to limit the scope. It is understood that if problems occur in peak-to-peak value detection and output voltage detection, they can be resolved by adjusting the circuit parameters, such as the resistance value, MOSFET, diode, and transistor, thereby controlling the peak-to-peak value, output voltage, and charge accumulation.

[0140] This embodiment is designed to perform detection feedback from multiple angles, including closed-loop detection control of total output voltage, closed-loop detection control of peak-to-peak value, and charge accumulation detection control. With multiple closed-loop controls, the control accuracy is higher, the data error rate is greatly reduced, the reference value of the data is significantly improved, and the safety and practicality are enhanced.

[0141] This application also provides a waveform quantization method, applied to a waveform quantization device including a waveform processing circuit and an MCU. The waveform processing circuit is used to superimpose the negative signal and the positive signal of the waveform in the waveform output circuit, and convert the negative signal in the superposition result into a positive signal.

[0142] It's important to note that the various waveforms in electrotherapy are outputs created by concatenating different mathematical functions. For example, a triangular wave is formed by concatenating a linear function Y = AX + B. The forward and reverse linear functions have the same slope and intersection point, only their directions are opposite. Concatenating two linear functions yields a trigonometric waveform. A sine wave is formed by concatenating the function Y = sinX, and so on. Based on these function expressions, the software can express them using programming languages. The program execution has corresponding machine cycle times, and timers can also be set accordingly.

[0143] The electrotherapy device involved in this application allows for the selection of different treatment module parameters. The device is equipped with an MCU or other type of controller. Sub-elements of each function waveform are pre-stored in the MCU's storage module. These sub-waveform elements include waveform number, phase, step size, starting point, intensity, period, and mode information. Once the MCU's storage module contains all the waveform elements for all output types, it then concatenates these sub-waveform elements according to time, period, wavelength, intensity, and other parameters, based on traditional medical treatment methods and prescription requirements, ultimately achieving the designed output.

[0144] For example, if an electrotherapy device is to treat conditions such as facial nerve paralysis, insomnia, dizziness, myopia, and tearing eye according to the prescription, and to achieve the shaking effect of traditional Chinese medicine massage techniques in clinical practice, then the waveform pulse width needs to be set to 260μs, pulse interval to 100ms, duration to 5.6s, and off time to 2.3s.

[0145] It should be noted that the programming program is pre-stored in the MCU or other types of controllers in this method, which does not affect the implementation of this technical solution.

[0146] Figure 8 A flowchart of a waveform quantization method provided in another embodiment of this application; as shown Figure 8 As shown, the method includes:

[0147] S10: Obtain the signal output by the waveform processing circuit.

[0148] The action acquisition in this step can be completed by the MCU or other types of controllers. The output signal can be processed by the waveform processing circuit or by other circuits or modules. As long as it can superimpose the negative and positive signals of the waveform in the waveform output loop, convert the negative signal in the superposition result into a positive signal and output it to the detection port of the MCU.

[0149] In this step, the signal processed and output by the waveform processing circuit includes the electrotherapy waveform. As one possible implementation, the MCU can acquire the signal processed and output by the waveform processing circuit in real time, that is, after the MCU or other type of controller acquires the signal processed and output by the waveform processing circuit, it can upload it to the MCU and store it in real time. Alternatively, it can be acquired at regular intervals, with a corresponding period set. After the MCU or other type of controller acquires the complete signal processed and output by the waveform processing circuit, it can upload it to the MCU and store it.

[0150] S11: Process the signal using an integral processing method to obtain the quantization result.

[0151] This step involves mathematical integration and quantization of the waveform. This is done by integrating the waveform over several cycles or a single cycle, within multiple time intervals within a single cycle or multiple cycles. For example, to integrate and quantize the waveform within a single cycle, four time points are selected: t0, t1, t2, and t3. Then, integration is performed over the time intervals t0-t1, t1-t2, and t2-t3. The results are f0, f1, and f2, respectively. If f0 = f1 = f2 = 0, it indicates that the waveform has good symmetry at each moment, with no charge accumulation, making it a relatively ideal waveform that will not harm the human body. If f0 = f1 = 0, f2 ≠ 0, or other conditions cause f0 + f1 + f2 ≠ 0, it indicates charge accumulation. When the charge accumulation reaches a certain amount, it may cause harm to the human body. When the accumulation is small, it will not cause harm, but it will affect the patient's sensation. If f0 = 0, f1 + f2 = 0, or f0 = f1 = f2 = 0 occurs, it can be proven that there is no charge accumulation during the entire cycle. However, charge accumulation may occur at a certain point in time within the measurement cycle, resulting in an imbalance between positive and negative charges. This may also cause discomfort to the human body during treatment at some point.

[0152] In this step, the MCU pre-stores the corresponding waveform expression and period. The MCU also has a corresponding definite integral algorithm. The definite integral function performs a time definite integral operation on the function expression of the predicted waveform. The MCU can output the corresponding definite integral value, which is the quantization result.

[0153] In practice, the signal can be processed by integration by selecting multiple time periods or a single time period, and then selecting multiple time segments to obtain the definite integral value corresponding to each time segment. It should be noted that there is no limitation on the multiple time segments selected, nor is there any limitation on the selected time nodes.

[0154] S12: Determine whether the quantization result meets the preset conditions; if the quantization result meets the preset conditions, proceed to S13; if the quantization result does not meet the preset conditions, proceed to S14.

[0155] The definite integral result obtained from the above steps is the quantization result. To determine whether the quantization result meets the preset conditions, it is necessary to determine whether the integral value of a time period is less than or equal to the preset value. If so, the waveform in that time period can be considered to meet medical requirements and will not lead to a large accumulation of charge. Alternatively, the integral value can be calculated for the entire waveform. If the integral value is less than or equal to the preset value, it can be considered that there will be no large accumulation of charge in the entire waveform. However, in practical applications, simply calculating that the integral value of a time period is less than or equal to the preset value only indicates that there is no large accumulation of charge in that time period, but it cannot guarantee that there is no large accumulation of charge in the entire waveform. Similarly, simply calculating that the integral value of the entire waveform is less than or equal to the preset value only indicates that there will be no large accumulation of charge in the entire waveform, but it cannot guarantee that there will be no large accumulation of charge in each time period. Therefore, as a preferred embodiment, it is reasonable to use a combination of two integration methods to determine whether the charge in the waveform output has accumulated.

[0156] S13: Determine that the amount of charge accumulated in the waveform is within a preset range.

[0157] S14: Determines that the accumulated charge in the waveform exceeds the preset range.

[0158] In this embodiment, whether the charge accumulation in the waveform is within the preset range is determined by comparing the quantization result, i.e. the integration result, with the preset value. If it exceeds the preset value, it can be determined that the waveform is not an ideal waveform and that a large amount of charge has accumulated, which can cause electrical burns.

[0159] It should be noted that the preset value in this embodiment is the maximum amount of electric charge that the human body can accept. Exceeding this value may cause electric burns or discomfort.

[0160] The waveform quantization method provided in this application is applied to a waveform processing circuit that can superimpose negative and positive signals in a medical waveform and convert the negative signal in the superposition result into a positive signal. The method acquires the signal of the output waveform after circuit processing, processes the signal according to the quantization method to obtain the quantization result, and determines whether the accumulation of charge in the waveform is within a certain range by judging whether the quantization result meets the preset conditions. If the accumulation of charge in the waveform is within the specified range, it can be determined that the electrotherapy waveform will not cause electric burns. The method provides a waveform symmetry quantization method by quantizing the waveform and measuring the quantized result to judge whether the waveform is completely symmetrical, and can measure the amount of charge.

[0161] In the above embodiments, the signal output after waveform processing is processed by the waveform processing circuit and processed by integration. As a preferred embodiment, based on the above embodiments, the signal is processed by integration to obtain quantization results, including: selecting at least one time period on the waveform and obtaining the integral values ​​of each time period obtained by definite integration operation.

[0162] In practice, multiple time points can be selected from the waveform, and the corresponding time periods can be derived from the time points. The integral value of each time period can be calculated. It can be understood that time points are selected in the entire waveform, and there is no limit to the number or position of the time points. Multiple time points can be in multiple cycles.

[0163] This embodiment calculates the integral value for each time period, which helps the MCU to judge the charge accumulation in each time period according to a pre-set program.

[0164] The above embodiments select at least one time period for the waveform, and the MCU obtains the integral values ​​obtained by definite integral operation for at least one time period. Based on the above embodiments, as a preferred embodiment, determining whether the quantization result meets the preset conditions includes:

[0165] Determine whether each integral value is less than or equal to a preset integral value;

[0166] If all integral values ​​are less than or equal to the preset integral value and the total integral value obtained by adding all integral values ​​is less than or equal to the preset integral value, then the amount of charge accumulated in the shape is determined to be within the preset range.

[0167] If all integral values ​​are less than or equal to the preset integral value and the total integral value obtained by adding all integral values ​​is greater than the preset integral value, then it is determined that the accumulated charge in the waveform exceeds the preset range.

[0168] If at least one integral value is greater than a preset integral value, it is determined that the accumulated charge in the waveform exceeds the preset range.

[0169] This embodiment obtains the integral values ​​of each time period and the total integral value obtained by adding the integral values ​​of each time period. First, it determines whether the integral value of each time period is less than or equal to a preset value. If the integral value of each time period is less than or equal to the preset value, the integral values ​​of each time period are added to obtain the total integral value. Then, it determines whether the total integral value is also less than or equal to the preset value. If the total integral value is also less than or equal to the preset value, it can be determined that there may be charge accumulation in the electrotherapy waveform, but the accumulated value is within the range that the human body can tolerate. That is, using this electrotherapy waveform to treat the human body will not cause electric burns or electric stimulation. If the integral value of each time period is greater than the preset value, it can be determined that there is charge accumulation in at least one time period that exceeds the range that the human body can tolerate. It is determined that there is charge accumulation in the electrotherapy waveform, and the accumulated value exceeds the range that the human body can tolerate. That is, using this electrotherapy waveform to treat the human body will cause electric burns or electric stimulation.

[0170] This embodiment compares the integral values ​​of each time period and the total integral value with preset values ​​to ensure that the output of the entire waveform is reasonable and will not cause a large amount of charge accumulation. That is, using this electrotherapy waveform to treat the user will not cause problems such as electric stimulation or electric burns, thus ensuring the safety of the electrotherapy process.

[0171] The waveform quantization apparatus and method provided in this application have been described in detail above. The various embodiments in the specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section. It should be noted that those skilled in the art can make several improvements and modifications to this application without departing from the principles of this application, and these improvements and modifications also fall within the protection scope of the claims of this application.

[0172] It should also be noted that, in this specification, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. A waveform quantization device, characterized in that, include: Waveform processing circuit, MCU; The first end of the waveform processing circuit is connected to the waveform output circuit, and the second end of the waveform processing circuit is connected to the detection end of the MCU. It is used to superimpose the negative signal and the positive signal of the waveform in the waveform output circuit and convert the negative signal in the superposition result into a positive signal. The MCU is used to acquire the positive signal output by the waveform processing circuit, process the positive signal according to the integration processing method to obtain the quantization result, and determine whether the quantization result meets the preset conditions. If yes, it is determined that the charge accumulation in the waveform is within the preset range; otherwise, it is determined that the charge accumulation in the waveform exceeds the preset range. The step of processing the positive signal using an integral processing method to obtain the quantization result includes: Select at least one time period on the waveform; Obtain at least one integral value obtained by definite integral operation for the time period; The determination of whether the quantification result meets the preset conditions includes: Determine whether each integral value is less than or equal to a preset integral value; If each of the integral values ​​is less than or equal to the preset integral value and the total integral value obtained by adding the integral values ​​is less than or equal to the preset integral value, then it is determined that the amount of charge accumulated in the shape is within a preset range. If each of the integral values ​​is less than or equal to the preset integral value and the total integral value obtained by adding the integral values ​​is greater than the preset integral value, then it is determined that the charge accumulation in the waveform exceeds the preset range. If at least one of the integral values ​​is greater than the preset integral value, it is determined that the accumulated charge in the waveform exceeds the preset range.

2. The waveform quantization apparatus according to claim 1, characterized in that, The waveform processing circuit includes: a first operational amplifier, a second operational amplifier, a first resistor, a second resistor, a third resistor, a fourth resistor, a fifth resistor, a first diode, and a second diode; Wherein, the first end of the first resistor is connected to the waveform output circuit and the first end of the fourth resistor; The first terminal of the first operational amplifier is connected to the first terminal of the first diode, the first terminal of the second resistor, and the second terminal of the first resistor. The second terminal of the first operational amplifier is grounded. The third terminal of the first operational amplifier is connected to the second terminal of the first diode and the first terminal of the second diode. The second terminal of the second diode is connected to the second terminal of the second resistor and the first terminal of the third resistor; The second end of the third resistor is connected to the first end of the second operational amplifier, the second end of the fourth resistor, and the first end of the fifth resistor; The second terminal of the second operational amplifier is grounded, and the third terminal of the second operational amplifier is connected to the second terminal of the fifth resistor and the detection terminal of the MCU.

3. The waveform quantization apparatus according to claim 2, characterized in that, The waveform processing circuit further includes: a first transistor; The first end of the first transistor is connected to the second end of the fourth resistor and the first end of the fifth resistor. The second end of the first transistor is connected to the second end of the fifth resistor, the third end of the second operational amplifier, and the detection end of the MCU. The third end of the first transistor is connected to a preset power supply to clamp the voltage of the third end of the second operational amplifier within a preset voltage range.

4. The waveform quantization apparatus according to any one of claims 1 to 3, characterized in that, Also includes: Positive voltage control circuit and negative voltage control circuit are used to control the voltage to drop to a preset voltage value; The positive voltage control circuit includes a sixth resistor, a seventh resistor, a first MOSFET, and a first capacitor; the negative voltage control circuit includes an eighth resistor, a ninth resistor, a second MOSFET, and a second capacitor. Wherein, the first end of the seventh resistor is connected to the waveform output after PWM modulation, and the second end of the seventh resistor is connected to the control terminal of the first MOS transistor; The first terminal of the first MOSFET is connected to the second terminal of the sixth resistor, and the second terminal of the first MOSFET is connected to the first terminal of the first capacitor. The first terminal of the sixth resistor is connected to the positive terminal of the power supply; The second terminal of the first capacitor is grounded; The first end of the ninth resistor is connected to the waveform output after PWM modulation, and the second end of the ninth resistor is connected to the control terminal of the second MOS transistor. The first terminal of the second MOSFET is connected to the second terminal of the eighth resistor, and the second terminal of the second MOSFET is connected to the first terminal of the second capacitor. The first terminal of the eighth resistor is connected to the negative terminal of the power supply. The second terminal of the second capacitor is grounded.

5. The waveform quantization apparatus according to claim 4, characterized in that, Also includes: The positive pressure detection circuit and the negative pressure detection circuit are used to convert the negative signal in the waveform into a positive signal and output it to the MCU, and clamp the voltage at the detection terminal of the MCU within the preset voltage range. The MCU is also used to detect whether the voltage value after being controlled by the positive pressure control circuit and the negative pressure control circuit is a first preset voltage value. If so, the voltage output by the positive voltage control circuit and the negative voltage control circuit meets the usage standard; If not, the voltage output by the positive voltage control circuit and the negative voltage control circuit does not meet the usage standard; The positive voltage detection circuit includes a tenth resistor, an eleventh resistor, a third diode, and a third capacitor; the negative voltage detection circuit includes a twelfth resistor, a thirteenth resistor, a fourteenth resistor, a third operational amplifier, a second transistor, and a fourth capacitor. Wherein, the first end of the tenth resistor is connected to the second end of the first MOS transistor and the first end of the first capacitor, and the second end of the tenth resistor is connected to the first end of the eleventh resistor, the second end of the third diode and the first end of the third capacitor; The second terminal of the eleventh resistor is grounded; The first end of the third diode is connected to the power supply, and the second end of the third diode is connected to the first end of the second capacitor and the detection terminal of the MCU. The second terminal of the third capacitor is grounded; The first end of the twelfth resistor is connected to the second end of the second MOS transistor and the first end of the second capacitor, and the second end of the twelfth resistor is connected to the first end of the second transistor and the first end of the thirteenth resistor; The second end of the thirteenth resistor is connected to the first end of the third operational amplifier and the first end of the fourteenth resistor; The second terminal of the third operational amplifier is grounded, and the third terminal of the third operational amplifier is connected to the second terminal of the second transistor, the second terminal of the fourteenth resistor, the first terminal of the fourth capacitor, and the detection terminal of the MCU. The third terminal of the second transistor is connected to the power supply; The second terminal of the fourth capacitor is grounded.

6. The waveform quantization apparatus according to claim 5, characterized in that, Also includes: The peak-to-peak detection circuit is used to convert the negative half-axis peak voltage into a positive half-axis peak voltage output when the input is a negative half-axis peak voltage, and to output the positive half-axis peak voltage when the input is a positive half-axis peak voltage. The MCU is also used to detect whether the peak-to-peak voltage value of the waveform is a second preset voltage value. If so, the peak-to-peak voltage in the peak-to-peak detection circuit conforms to the usage standard; If not, the peak-to-peak voltage in the peak-to-peak detection circuit does not meet the usage standard; The peak-to-peak detection circuit includes a fourth operational amplifier, a fifth operational amplifier, a fifteenth resistor, a sixteenth resistor, a first switching device, a second switching device, a fifth capacitor, and a sixth capacitor; Wherein, the first terminal of the fourth operational amplifier is connected to the waveform output circuit and the first terminal of the fifteenth resistor, the second terminal of the fourth operational amplifier is connected to the third terminal of the fourth operational amplifier, and the third terminal of the fourth operational amplifier is connected to the first terminal of the first switching device. The second terminal of the first switching device is connected to the control terminal of the MCU, and the third terminal of the first switching device is connected to the detection terminal of the MCU and the first terminal of the fifth capacitor. The second terminal of the fifth capacitor is grounded; The second end of the fifteenth resistor is connected to the first end of the sixteenth resistor and the first end of the fifth operational amplifier; The second terminal of the fifth operational amplifier is grounded, and the third terminal of the fifth operational amplifier is connected to the second terminal of the sixteenth resistor and the first terminal of the second switching device; The second terminal of the second switching device is connected to the control terminal of the MCU, and the third terminal of the second switching device is connected to the detection terminal of the MCU and the first terminal of the sixth capacitor. The second terminal of the sixth capacitor is grounded.

7. The waveform quantization apparatus according to claim 6, characterized in that, The MCU is also used to determine the cause based on the charge accumulation in the waveform exceeding the preset range; wherein the cause includes any one or combination of the voltage value controlled by the voltage control circuit not being the first preset voltage value and the peak-to-peak voltage value of the waveform not being the second preset voltage value.

8. A waveform quantization method, characterized in that, An apparatus for waveform quantization, comprising a waveform processing circuit and an MCU, wherein the waveform processing circuit is used to superimpose negative and positive signals of a waveform in the waveform output loop, and to convert the negative signal in the superposition result into a positive signal, the method comprising: Obtain the positive signal output by the waveform processing circuit; The positive signal is processed using an integral processing method to obtain the quantization result; Determine whether the quantization result meets the preset conditions; If so, then it is determined that the amount of charge accumulated in the waveform is within a preset range; If not, then it is determined that the accumulated charge in the waveform exceeds a preset range; The step of processing the positive signal using an integral processing method to obtain the quantization result includes: Select at least one time period on the waveform; Obtain at least one integral value obtained by definite integral operation for the time period; The determination of whether the quantification result meets the preset conditions includes: Determine whether each integral value is less than or equal to a preset integral value; If each of the integral values ​​is less than or equal to the preset integral value and the total integral value obtained by adding the integral values ​​is less than or equal to the preset integral value, then it is determined that the amount of charge accumulated in the shape is within a preset range. If each of the integral values ​​is less than or equal to the preset integral value and the total integral value obtained by adding the integral values ​​is greater than the preset integral value, then it is determined that the charge accumulation in the waveform exceeds the preset range. If at least one of the integral values ​​is greater than the preset integral value, it is determined that the accumulated charge in the waveform exceeds the preset range.