Waveform output method and device for pulse signal of physiotherapy instrument and electronic equipment

By splitting and fitting the pulse signal of the physiotherapy instrument and generating an envelope waveform, the problem of difficulty in quickly and accurately outputting the envelope waveform of the physiotherapy instrument pulse signal in the prior art is solved, and the analysis efficiency is improved.

CN119524316APending Publication Date: 2025-02-28CHANGSHA ANXIANG MEDICAL TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411586688.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-07
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

The prior art is difficult to quickly and accurately output the envelope waveform of the physiotherapy instrument pulse signal, which leads to difficulties for users to study the physiotherapy instrument pulse signal.

Method used

By obtaining the pulse signal of the physiotherapy instrument, splitting it into pulse signal segments, analyzing each signal segment, extracting feature points, and fitting feature points based on the functional formula in the preset function library to generate fitting functions and envelope waveforms.

Benefits of technology

It realizes the envelope waveform of the physiotherapy instrument pulse signal quickly and accurately, and improves the user's analysis of the functions and functions of the physiotherapy instrument.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119524316A_ABST
    Figure CN119524316A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of physiotherapy instruments, and discloses a waveform output method and device for a pulse signal of a physiotherapy instrument and electronic equipment, and the method comprises the steps: obtaining the pulse signal of the physiotherapy instrument, splitting each continuous waveform in the pulse signal into a pulse signal segment, and analyzing each pulse signal segment, the method comprises the steps of obtaining a plurality of feature points of each pulse signal segment, fitting all the feature points of each pulse signal segment based on a functional expression in a preset function library to generate a fitting function of each pulse signal segment, and determining an envelope waveform of the functional expression corresponding to each fitting function as an envelope waveform of the corresponding pulse signal segment, and outputting the fitting function and the envelope waveform of each pulse signal segment according to the sequence of each pulse signal segment in the pulse signal. Through the mode, the waveform of the pulse signal of the physiotherapy instrument can be rapidly and accurately output, so that a user can conveniently research the physiotherapy instrument.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the technical field of physiotherapy apparatus, and specifically to a waveform output method of a pulse signal of a physiotherapy apparatus, a waveform output device of a pulse signal of a physiotherapy apparatus, and an electronic device. Background Art

[0002] Physiotherapy devices can generate currents of different envelope waveforms, frequencies and intensities, and transmit them to the skin surface through electrodes to stimulate nerve fibers to relieve pain, or cause muscle contraction to achieve muscle training or prevent muscle atrophy. In order to continuously improve the functions of physiotherapy devices, in addition to basic research on the effects of physiotherapy devices on the human body, it is also necessary to study a large number of pulse signals.

[0003] At present, the pulse signal of the physiotherapy instrument is mainly collected by instruments such as oscilloscopes and logic analyzers, and the envelope waveform is viewed and analyzed by these instruments, and the pulse signal of the physiotherapy instrument is analyzed by operating these instruments through the rollers and buttons on the instruments. However, with the increase in the complexity of the waveform, it is extremely difficult to analyze the envelope waveform from nanoseconds to tens of minutes on the instrument. Therefore, in order to enable users to study the pulse signal of the physiotherapy instrument more conveniently, how to quickly and accurately output the envelope waveform of the pulse signal of the physiotherapy instrument has become a problem that needs to be solved urgently. Summary of the invention

[0004] In view of the above problems, the embodiments of the present application provide a waveform output method of a physiotherapy device pulse signal, a waveform output device of a physiotherapy device pulse signal and an electronic device, which are used to solve the problem in the prior art that the envelope waveform of the physiotherapy device pulse signal cannot be output quickly and accurately, so as to facilitate users to study the pulse signal of the physiotherapy device.

[0005] According to one aspect of an embodiment of the present application, a waveform output method for a pulse signal of a physical therapy device is provided, the method comprising: obtaining a pulse signal of a physical therapy device; splitting each continuous waveform in the pulse signal into a pulse signal segment; analyzing each pulse signal segment to obtain multiple feature points of each pulse signal segment, wherein the multiple feature points include at least one peak point in each cycle of the pulse signal segment; fitting all feature points of each pulse signal segment based on a function formula in a preset function library to generate a fitting function for each pulse signal segment, wherein the preset function library pre-stores multiple function formulas and the envelope waveform of each function formula; determining the envelope waveform of the function formula corresponding to each fitting function as the envelope waveform of the corresponding pulse signal segment; and outputting the fitting function and envelope waveform of each pulse signal segment in the order of each pulse signal segment in the pulse signal.

[0006] In an optional manner, obtaining a pulse signal of a physical therapy device specifically includes: obtaining a first time and its corresponding first amplitude, a second time and its corresponding second amplitude; obtaining a pulse signal between the first time and the second time to obtain a pulse signal; calculating the difference between the first time and the second time to obtain the time difference of the pulse signal; calculating the difference between the first amplitude and the second amplitude to obtain the amplitude difference of the pulse signal; calculating parameter information of the pulse signal, the parameter information including the frequency, peak-to-peak value and pulse width of the pulse signal; and outputting the time difference, amplitude difference, frequency, peak-to-peak value and pulse width of the pulse signal.

[0007] In an optional manner, based on the function formula in the preset function library, all the characteristic points of each pulse signal segment are fitted to generate a fitting function for each pulse signal segment, specifically including: performing the following steps for each pulse signal segment: substituting all the characteristic points of the pulse signal segment into each function formula in the preset function library, determining the coefficient of each function formula, and obtaining multiple candidate fitting functions corresponding to the pulse signal segment; substituting all the characteristic points of the pulse signal segment into each candidate fitting function corresponding to it, determining the matching degree of each candidate fitting function with the pulse signal segment; and determining the candidate fitting function with the highest matching degree as the fitting function of the pulse signal segment.

[0008] In an optional manner, all feature points of a pulse signal segment are substituted into each candidate fitting function corresponding thereto, and the degree of match between each candidate fitting function and the pulse signal segment is determined, specifically including: performing the following steps for each candidate fitting function: substituting the time of all feature points of the pulse signal segment into the candidate fitting function to obtain the predicted amplitude corresponding to each feature point; if the difference between the actual amplitude of the feature point and the predicted amplitude corresponding to the feature point is within a first preset error range, determining that the feature point is consistent with the candidate fitting function; counting the number of feature points that are consistent with the candidate fitting function among all feature points of the pulse signal segment; calculating the ratio between the number of consistent feature points and the total number of feature points of the pulse signal segment to obtain the degree of match between the candidate fitting function and the pulse signal segment.

[0009] In an optional manner, the fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, specifically including: obtaining two adjacent pulse signal segments according to the order of each pulse signal segment in the pulse signal; judging whether the envelope waveforms of the two adjacent pulse signal segments are similar; if the envelope waveforms of the two adjacent pulse signal segments are similar, retaining any one of the two adjacent pulse signal segments, and increasing the number of envelope waveforms of any one pulse signal segment by one, obtaining the next two adjacent pulse signal segments according to the order of the pulse signal segments in the pulse signal, and jumping to the step of judging whether the envelope waveforms of the two adjacent pulse signal segments are similar, until all the pulse signal segments are traversed. Some pulse signal segments, wherein the previous pulse signal segment between the next two adjacent pulse signal segments is any retained pulse signal segment; if the envelope waveforms of the two adjacent pulse signal segments are not similar, then the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal, and directly jump to the step of judging whether the envelope waveforms of the two adjacent pulse signal segments are similar, until all the pulse signal segments in the pulse signal are traversed, wherein the previous pulse signal segment between the next two adjacent pulse signal segments is the latter pulse signal segment between the two adjacent pulse signal segments; and the fitting function, envelope waveform and number of envelope waveforms of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal.

[0010] In an optional manner, determining whether the envelope waveforms of two adjacent pulse signal segments are similar specifically includes: calculating the error between the coefficients of the fitting function of the previous pulse signal segment in the two adjacent pulse signal segments and the coefficients of the fitting function of the subsequent pulse signal segment to obtain the coefficient error; if the coefficient error is outside the second preset error range, the envelope waveforms of the two adjacent pulse signal segments are not similar; if the coefficient error is within the second preset error range, performing the following steps: substituting the time of all feature points of the previous pulse signal segment in the two adjacent pulse signal segments into the fitting function of the previous pulse signal segment to obtain the predicted amplitude corresponding to each feature point of the previous pulse signal segment; calculating the difference between the actual amplitudes of all feature points of the previous pulse signal segment and the corresponding predicted amplitudes, Obtain the error of the fitting function of the previous pulse signal segment; substitute the time of all feature points of the latter pulse signal segment in the two adjacent pulse signal segments into the fitting function of the latter pulse signal segment to obtain the predicted amplitude corresponding to each feature point of the latter pulse signal segment; calculate the difference between the actual amplitude of all feature points of the latter pulse signal segment and the corresponding predicted amplitude to obtain the error of the fitting function of the latter pulse signal segment; calculate the difference between the error of the fitting function of the previous pulse signal segment and the error of the fitting function of the latter pulse signal segment to obtain the fitting error; if the fitting error is within a third preset error range, the envelope waveforms of the two adjacent pulse signal segments are similar; if the fitting error is outside the third preset error range, the envelope waveforms of the two adjacent pulse signal segments are not similar.

[0011] In an optional manner, each pulse signal segment is analyzed to obtain multiple characteristic points of each pulse signal segment, specifically including: for each pulse signal segment, the following steps are performed respectively: the first point in the pulse signal segment whose amplitude is greater than or equal to the first preset amplitude is determined in sequence as the first sampling point; the point after the first sampling point on the pulse signal segment is determined as the second sampling point, and the point after the second sampling point is determined as the third sampling point; the difference between the amplitude of the first sampling point and the amplitude of the second sampling point is calculated to obtain the first difference; the difference between the amplitude of the second sampling point and the amplitude of the second sampling point is calculated to obtain the second difference; it is determined whether the first difference and the second difference are both within the preset difference range; if so, the second sampling point is determined as the characteristic a point in the pulse signal segment whose amplitude is equal to the first preset amplitude is determined as a new first sampling point, and jumps to the step of determining a point on the pulse signal segment that is continuous with the first sampling point as a second sampling point, and a point on the pulse signal segment that is continuous with the second sampling point as a third sampling point, until the pulse signal segment is traversed, wherein the amplitude of the previous point of the new first sampling point is less than the first preset amplitude, and the amplitude of the next point on the new first sampling point is greater than the first preset amplitude; if not, the second sampling point is determined as a new first sampling point, and jumps to the step of determining a point on the pulse signal segment that is continuous with the first sampling point as a second sampling point, and a point on the pulse signal segment that is continuous with the second sampling point as a third sampling point, until the pulse signal segment is traversed.

[0012] In an optional manner, each continuous waveform in a pulse signal is split into a pulse signal segment, specifically including: determining a pulse signal in the pulse signal whose amplitude is continuously equal to a second preset amplitude and whose duration is greater than or equal to a preset time as a pause segment; and sequentially splitting the pulse signal before the first pause segment in the pulse signal, the pulse signal after the last pause segment, and the pulse signal between all two adjacent pause segments into a pulse signal segment.

[0013] According to another aspect of an embodiment of the present application, a waveform output device for a pulse signal of a physical therapy device is provided, comprising: an acquisition module for acquiring a pulse signal of a physical therapy device; a splitting module for splitting each continuous waveform in the pulse signal into a pulse signal segment; an analysis module for analyzing each pulse signal segment to obtain multiple feature points of each pulse signal segment, wherein the multiple feature points include at least one peak point in each cycle of the pulse signal segment; a fitting module for fitting all feature points of each pulse signal segment based on a function formula in a preset function library to generate a fitting function for each pulse signal segment, wherein the preset function library pre-stores multiple function formulas and the envelope waveform of each function formula; a determination module for determining the envelope waveform of the function formula corresponding to each fitting function as the envelope waveform of the corresponding pulse signal segment; and an output module for outputting the fitting function and envelope waveform of each pulse signal segment in the order of each pulse signal segment in the pulse signal.

[0014] According to another aspect of an embodiment of the present application, an electronic device is provided, comprising a memory, a processor and a computer program stored on the memory, wherein the processor executes the computer program to implement the waveform output method of the pulse signal of a physiotherapy device as described in any one of the above.

[0015] In the embodiment of the present application, first, after obtaining the pulse signal of the physiotherapeutic instrument, each continuous waveform in the pulse signal is split into a pulse signal segment, so that each pulse signal segment can be analyzed separately more conveniently, which is conducive to improving the accuracy of the fitting function and the envelope waveform. Secondly, at least one peak point in each cycle of the pulse signal segment is used as the characteristic point of the pulse signal segment, and all characteristic points of each pulse signal segment are fitted based on the function formula of the preset function library to determine the fitting function of each pulse signal segment. On the one hand, the fitting function generated according to the characteristic point is more consistent with the shape of the pulse signal segment, which effectively improves the accuracy of the envelope waveform. On the other hand, using the known function formula to fit the characteristic points can speed up the fitting speed and improve the accuracy of the fitting function, indirectly speed up the analysis speed of the physiotherapeutic instrument, and improve the accuracy of the analysis results. Finally, the fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, so that the user can directly analyze the function and effect of the physiotherapeutic instrument according to the output fitting function and envelope waveform, effectively improving the analysis efficiency of the physiotherapeutic instrument.

[0016] The above description is only an overview of the technical solution of the embodiment of the present application. In order to more clearly understand the technical means of the embodiment of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the embodiment of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The accompanying drawings are only used to illustrate the embodiments and are not to be considered as limiting the present application. In addition, the same reference symbols are used to represent the same components throughout the accompanying drawings. In the accompanying drawings:

[0018] Figure 1 A schematic diagram of a scenario showing a method for outputting a waveform of a pulse signal of a physiotherapy device provided in an embodiment of the present application;

[0019] Figure 2 A schematic flow chart of a method for outputting a waveform of a pulse signal of a physiotherapy device provided in an embodiment of the present application is shown;

[0020] Figure 3 The output schematic diagram of the waveform output method of the pulse signal of the physiotherapy device provided in the embodiment of the present application is shown;

[0021] Figure 4 A schematic diagram showing a display of a pulse signal provided in an embodiment of the present application is shown;

[0022] Figure 5 Another display schematic diagram of a pulse signal provided in an embodiment of the present application is shown;

[0023] Figure 6 A schematic flow chart of a method for outputting a waveform of a pulse signal of a physiotherapy device provided in another embodiment of the present application is shown;

[0024] Figure 7 A schematic diagram of the structure of a waveform output device for a pulse signal of a physiotherapy device provided in an embodiment of the present application is shown;

[0025] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0026] The exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein.

[0027] Physiotherapy devices usually generate pulse signals with different envelope waveforms to simulate the effects of different actions on the human body. For example, a massager can simulate massage actions such as kneading, pressing, tapping, and friction by generating pulse signals with different envelope waveforms. In addition, in order to ensure the effectiveness of the physiotherapy device on the human body, the physiotherapy device usually outputs pulse signals with multiple envelope waveforms alternately, and applies the pulse signals to the human skin to achieve a complete physiotherapy process.

[0028] However, as the complexity of pulse signals continues to increase, it is extremely difficult to analyze envelope waveforms ranging from nanometers to tens of minutes on instruments such as oscilloscopes and logic analyzers. Although, with the development of technology, some tools such as oscilloscope software and audio driver software have been produced, which can move the pulse signal of the physiotherapy device from the instrument to the line for visual display. However, these tools can only display the general shape of the pulse signal and the envelope waveform, and cannot directly output the envelope waveform of the pulse signal. The specific envelope waveform sometimes requires the user to calculate it manually.

[0029] Based on this, the embodiment of the present application provides a waveform output method of a pulse signal of a physical therapy device. First, after obtaining the pulse signal of the physical therapy device, each continuous waveform in the pulse signal is split into a pulse signal segment, and each pulse signal segment is analyzed separately, and at least one peak point in each cycle of the pulse signal segment is used as a characteristic point of the pulse signal segment. At least one characteristic point is obtained from each cycle of the pulse signal segment, so that the fitting function generated according to the characteristic point is more consistent with the waveform of the pulse signal segment, effectively improving the accuracy of envelope waveform detection.

[0030] Then, using the multiple functional formulas pre-stored in the preset function library and the envelope waveform of each functional formula, all the characteristic points of each pulse signal segment are fitted to generate a fitting function for each pulse signal segment, and the envelope waveform of the functional formula corresponding to the fitting function is determined as the envelope waveform of the corresponding pulse signal segment. Based on the functional formulas in the preset function library, all the characteristic points of each pulse signal segment are fitted, which can further improve the accuracy of the fitting function and indirectly improve the accuracy of the analysis results of the physiotherapy instrument. Finally, the fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, which can enable users to more conveniently study the functions and effects of the physiotherapy instrument based on the fitting function and envelope waveform without affecting the analysis results of the physiotherapy instrument, and effectively improve the research efficiency of the physiotherapy instrument.

[0031] Specifically, Figure 1 As shown, Figure 1 A scenario schematic diagram of the waveform output method of the pulse signal of the physiotherapeutic device provided in the embodiment of the present application is shown. The electronic device 1 can be electrically connected to the oscilloscope 2. The physiotherapeutic device 3 generates current to the load 4 in the working mode. The pulse signal of the physiotherapeutic device 3 is restored by detecting the voltage difference between the two ends of the load 4 through the oscilloscope 2. After the oscilloscope 2 captures the pulse signal, it sends the pulse signal to the electronic device 1. After the electronic device 1 obtains the pulse signal, it executes the waveform output method of the pulse signal of the physiotherapeutic device to analyze the pulse signal, and outputs the fitting function and envelope waveform of the pulse signal, so that the user can study the function and effect of the physiotherapeutic device 3.

[0032] Figure 2The flowchart of the waveform output method of the pulse signal of the physiotherapy device provided in the embodiment of the present application is shown, and the method is executed by the electronic device 1. The electronic device 1 can be a terminal (for example, a mobile phone, a tablet, etc.), a server, etc. Figure 2 As shown, the method comprises the following steps:

[0033] Step S110: obtaining a pulse signal of a physical therapy device;

[0034] The pulse signal is all the pulse signals output by the physiotherapy device in a certain mode within a certain time period. The pulse signal can be data pre-stored on the electronic device 1. For example, after the electronic device 1 receives the pulse signal sent by the oscilloscope 2, it generates a csv file to store the pulse signal. It can also be data sent to the electronic device 1 in real time by other devices.

[0035] In addition, in addition to executing the waveform output method of the pulse signal of the physiotherapeutic device, the electronic device 1 can also read the pulse signal and visualize the pulse signal. Specifically, the electronic device 1 first reads the csv file stored thereon through the csv library, and saves the amplitude and time of the pulse signal as structured data through pandas. When the data is subsequently acquired, the list of amplitude and time can be obtained in the form of values; then, the list is put into the drawing library (such as MATLAB's matplotlib.pyplot) in the form of NumPy numerical values, and the pulse signal can be visualized.

[0036] In addition to all the data in the csv file, the pulse signal can also be a pulse signal within a certain period of time in the csv file. For example, onclick is used to obtain the mouse click event on the pulse signal visualization interface, and two positions where the mouse clicks continuously within a preset time are obtained, and the pulse signal between the two positions is intercepted as the pulse signal. Specifically, step S110 may include the following steps S111 to S116:

[0037] Step S111: obtaining a first time and its corresponding first amplitude, a second time and its corresponding second amplitude.

[0038] Among them, the first time, the first amplitude, the second time and the second amplitude can be obtained through a mouse click event. Specifically, the mouse can be used to click on the visualization interface of the pulse signal, and two positions of the mouse clicked continuously within a preset time can be obtained, and the time and amplitude of the first click position are determined as the first time and the first amplitude, and the time and amplitude of the second click position are determined as the second time and the second amplitude. It should be pointed out in particular that if the position where the mouse is clicked is outside the visualization interface of the pulse signal, a warning pop-up window can be popped up to remind the user to click again; if the position where the mouse is clicked is in a blank space in the visualization interface of the pulse signal, the corresponding amplitude can be obtained according to the time of the position.

[0039] In addition, different click events can be set for the left and right buttons of the mouse. For example, the left button of the mouse is used to obtain the first time, the first amplitude, the second time and the second amplitude, and the right button of the mouse is used to cancel the information obtained by the left button. That is, when the left button of the mouse is accidentally clicked and unnecessary time and amplitude are obtained, the currently obtained time and copy can be cleared by clicking the right button of the mouse to re-acquire the first time, the first amplitude, the second time and the second amplitude.

[0040] Step S112: Acquire a pulse signal between the first time and the second time to obtain a pulse signal.

[0041] Among them, the pulse signal between the first time and the second time is intercepted to obtain a pulse signal that needs to be output as a waveform. The pulse signal may include pulse signals of multiple envelope waveforms, or may only include a pulse signal of one envelope waveform, or may only include a partial pulse signal in one envelope waveform.

[0042] Step S113: Calculate the difference between the first time and the second time to obtain the time difference of the pulse signal.

[0043] Step S114: Calculate the difference between the first amplitude and the second amplitude to obtain the amplitude difference of the pulse signal.

[0044] Step S115: Calculate parameter information of the pulse signal, the parameter information including the frequency, peak-to-peak value and pulse width of the pulse signal.

[0045] Step S116: output the time difference, amplitude difference, frequency, peak-to-peak value and pulse width of the pulse signal.

[0046] Among them, Figure 3 As shown, Figure 3The output schematic diagram of the waveform output method of the pulse signal of the physiotherapy device provided in the embodiment of the present application is shown. After the pulse signal is obtained, the basic information of the pulse signal is calculated and output, for example, the time difference (i.e., the time of the pulse signal), the amplitude difference (i.e., the difference between the amplitude of the first point and the amplitude of the last point in the pulse signal), the frequency, the peak-to-peak value (i.e., the difference between the maximum value and the minimum value of the pulse signal), the pulse width (i.e., the length of time that the pulse signal maintains a high level state or a low level state in one cycle), etc. Of course, the parameter information can also include a pulse width trend, a frequency trend, etc.

[0047] In the above steps S111 to S116, by acquiring the first time and the second time and intercepting the pulse signal between the first time and the second time from the complete pulse signal of the physiotherapy instrument, the pulse signal between the first time and the second time is analyzed, so that the user can more conveniently analyze the specific pulse signal. In addition, the time difference, amplitude difference and parameter information of the pulse signal segment can also be calculated and output, so that the user can directly obtain the basic parameters of the pulse signal from the output content, such as frequency, pulse width, peak-to-peak value, etc. The waveform output method of the pulse signal of the physiotherapy instrument has a wider application scenario and better practicality.

[0048] In addition, in order to further improve the practicality of the waveform output method of the pulse signal of the physical therapy instrument, such as Figure 3 As shown, a "select point confirmation" button can also be set on the output interface of the time difference, amplitude difference and parameter information, so that after the electronic device obtains the first time, the first amplitude, the second time and the second amplitude, it first obtains the pulse signal between the first time and the second time, and calculates the time difference, amplitude difference and parameter information of the pulse signal, outputs and displays it to the user. The user then determines whether to further obtain the fitting function, envelope waveform and other information of the pulse signal based on the displayed time difference, amplitude difference and parameter information. Only when the user clicks the "select point confirmation" button, the electronic device will execute the waveform output method of the pulse signal of the physiotherapeutic instrument to obtain the fitting function, envelope waveform and the like of each pulse signal segment in the pulse signal. In this way, it can be avoided that the pulse signal is analyzed every time after the pulse signal is obtained to output the envelope waveform of each pulse signal segment in the pulse signal. When the user only needs to obtain the time difference, amplitude difference and parameter information of the pulse signal, the computing resources of the electronic device can be saved.

[0049] After step S110, step S120 is performed: each continuous waveform in the pulse signal is divided into a pulse signal segment.

[0050] Among them, Figure 4 As shown, Figure 4FIG. 1 shows a schematic diagram of a pulse signal provided in an embodiment of the present application. When the pulse signal is reduced to a certain extent, part of the pulse signal will form an envelope waveform, and the envelope waveform represents the shape formed by a cluster of adjacent pulse signals (such as Figure 4 As shown in the figure, the pulse signal forms three envelope waveforms, i.e. the shape formed by the gray part). When the pulse signals with different envelope waveforms act on the human skin, they can simulate the effects of different physical therapy actions on the human body. Therefore, when analyzing the pulse signal, each continuous waveform in the pulse signal can be split into a pulse signal segment, and each pulse signal segment will form an envelope waveform. The envelope waveform of each pulse signal segment is output in sequence, and the user can directly analyze the pulse signal, thereby realizing the analysis of the physical therapy device.

[0051] Specifically, there is usually a pause of several seconds between two adjacent pulse signal segments in the pulse signal. Therefore, in order to ensure that each pulse signal segment can form an envelope waveform, step S120 may include the following steps S121 to S122:

[0052] Step S121: Determine a pulse signal segment in which the amplitude of the pulse signal is continuously equal to the second preset amplitude and the duration is greater than or equal to the preset time as a pause segment.

[0053] Among them, Figure 4 As shown, there is a pulse signal amplitude (i.e. Figure 4 The voltage in will continue to be equal to the second preset amplitude (for example, Figure 4 There is a pulse signal with an amplitude of 0 between each envelope waveform), and when the duration is greater than a preset time (for example, 0.5 seconds, 1 second, 2 seconds, etc.), this pulse signal is regarded as a pause segment. Figure 5 As shown, Figure 5 Another display schematic diagram of the pulse signal provided in the embodiment of the present application is shown. The amplitude of the pulse signal may fluctuate due to power supply noise, electromagnetic interference, etc., which may cause the amplitude of the pause segment in the pulse signal (i.e. Figure 5 The voltage in the pulse signal) will fluctuate around the second preset amplitude, rather than being equal to the second preset amplitude. Therefore, an error range can also be set according to the second preset amplitude. If the amplitude of a certain pulse signal in the pulse signal continues to be within the error range, it means that the amplitude of this pulse signal continues to be equal to the second preset amplitude. It should be pointed out that if there is no pause segment in the pulse signal, it means that the pulse signal does not need to be split, and the pulse signal can be determined as a pulse signal segment.

[0054] Step S122: Sequentially split the pulse signal before the first pause segment, the pulse signal after the last pause segment, and the pulse signal between all two adjacent pause segments into a pulse signal segment respectively.

[0055] Finally, according to the order of the pause segments in the pulse signal, the pulse signal before the first pause segment, the pulse signal after the last pause segment, and the pulse signal between all two adjacent pause segments are split into a pulse signal segment, so that each pulse signal segment can form an envelope waveform. Figure 4 As shown, when there is a pulse signal with an amplitude continuously equal to the second preset amplitude at the start position or the end position of the pulse signal, this pulse signal can be removed from the pulse signal before splitting the pulse signal.

[0056] Through steps S121 to S122, the pause segments in the pulse signal are first obtained, and then the pulse signal is split according to the sequence and the position of the pause segments. This can quickly and effectively split the pulse signal into multiple pulse signal segments, indirectly improving the waveform output speed of the pulse signal of the physiotherapy device.

[0057] After step S120, step S130 is executed: each pulse signal segment is analyzed to obtain a plurality of characteristic points of each pulse signal segment, wherein the plurality of characteristic points include at least one peak point in each cycle of the pulse signal segment.

[0058] Among them, Figure 4 As shown in the figure, the envelope waveform of each pulse signal segment is the overall shape of the pulse signal after the pulse signal segment is reduced to a certain extent, that is, the shape formed by connecting the peak points in each cycle of the pulse signal segment in sequence. Therefore, by analyzing the pulse signal segment, the peak point in each cycle of the pulse signal segment can be obtained as the characteristic point of the pulse signal segment.

[0059] Specifically, a pulse signal segment is usually data collected by an oscilloscope, mainly one-to-one corresponding amplitude and time. When visualizing a pulse signal segment, time is usually used as the horizontal axis, amplitude is used as the vertical axis, and the data of the pulse signal segment is used as the point in the coordinate axis. These points are connected in sequence to realize the visualization of the pulse signal segment. When analyzing a pulse signal segment, the amplitude of the pulse signal segment is analyzed in sequence. When the amplitudes of three consecutive points are relatively close, one of the points is taken as a feature point; or when the amplitude of the point in the middle of the three consecutive points is greater than the amplitudes of the other two points, or the amplitude of the point in the middle is less than the amplitudes of the other two points, the point in the middle is taken as a feature point.

[0060] Furthermore, after continuous research on physical therapy devices, it was found that when the physical therapy device continuously outputs a pulse signal with a positive amplitude or a pulse signal with a negative amplitude to act on human skin, it not only fails to achieve the physical therapy effect, but may also cause muscle fatigue. Therefore, the pulse signal will alternately output a pulse signal with a positive amplitude and a pulse signal with a negative amplitude at a certain frequency.

[0061] like Figure 5 As shown, in one cycle, the physiotherapy instrument will first output a pulse signal with a negative amplitude and continuously increase the amplitude. When the amplitude reaches a peak value, it will start to continuously reduce the amplitude until the amplitude is 0, and then output a pulse signal with a positive amplitude and continuously increase the amplitude. When the amplitude reaches a peak value, it will start to continuously reduce the amplitude until the amplitude is 0, and repeat the cycle to output the pulse signal. In addition, the absolute values ​​of the peak values ​​of the pulse signal with a negative amplitude and the pulse signal with a positive amplitude are usually very close or even equal, which makes the pulse signal segment form a symmetrical shape when it is reduced to a certain extent. As long as the peak point of the upper part or the peak point of the lower part is fitted, the envelope waveform of the pulse signal segment can be determined.

[0062] Therefore, in order to speed up the waveform output speed of the pulse signal of the physiotherapeutic device, in step S130, the following steps (steps S131 to S138) can be performed for each pulse signal segment:

[0063] Step S131: sequentially determine the first point in the pulse signal segment whose amplitude is greater than or equal to the first preset amplitude as the first sampling point.

[0064] Step S132: determine a point after the first sampling point on the pulse signal segment as a second sampling point, and determine a point after the second sampling point as a third sampling point.

[0065] Step S133: Calculate the difference between the amplitude of the first sampling point and the amplitude of the second sampling point to obtain a first difference.

[0066] Step S134: Calculate the difference between the amplitude of the second sampling point and the amplitude of the second sampling point to obtain a second difference.

[0067] Among them, the pulse signal output by the physiotherapy instrument is mainly a square wave, a sine wave and other waveforms. The amplitude of the peak point of these pulse signals is usually close to the amplitude of the surrounding points, while the amplitude of the points at other positions will be quite different from the adjacent points. Therefore, when obtaining the peak point of the pulse signal segment as a feature point, three consecutive points can be obtained from the pulse signal segment as the first sampling point, the second sampling point and the third sampling point, and the difference between two adjacent sampling points is calculated to obtain the first difference and the second difference. Of course, in order to further shorten the time for obtaining feature points, the period of the pulse signal segment can be determined according to the frequency of the pulse signal segment, and then the sampling interval is determined and the sampling interval must be less than or equal to one-quarter of the period. When the pulse signal segment includes a large amount of data, it is not necessary to analyze each data of the pulse signal segment, which can greatly shorten the time for obtaining feature points.

[0068] Step S135: Determine whether the first difference and the second difference are both within a preset difference range.

[0069] Step S136: If the judgment in step S135 is yes, the second sampling point is determined as a feature point.

[0070] If the first difference and the second difference are both within the preset difference range, it means that the first sampling point, the second sampling point and the third sampling point are all near the peak point, and the second sampling point can be approximately determined as the peak point, that is, the second sampling point is determined as a feature point.

[0071] After step S136, execute step S137: determine the point in the pulse signal segment whose amplitude is equal to the first preset amplitude as a new first sampling point, and jump to the step of determining the next point continuous with the first sampling point on the pulse signal segment as the second sampling point, and determining the next point continuous with the second sampling point as the third sampling point, until the pulse signal segment is traversed, wherein the amplitude of the previous point of the new first sampling point is less than the first preset amplitude, and the amplitude of the next point of the new first sampling point is greater than the first preset amplitude.

[0072] Among them, in order to speed up the waveform output, only one characteristic point can be obtained from each cycle of the pulse signal segment. Therefore, after the second sampling point is determined as the characteristic point, a new first sampling point is obtained from the data of the next cycle. Specifically, when the pulse signal enters the next cycle from one cycle, the amplitude of the pulse signal changes from greater than the first preset amplitude to less than the first preset amplitude, or changes from less than the first preset amplitude to greater than the first preset amplitude (for example, from a positive amplitude to a negative amplitude or from a negative amplitude to a positive amplitude). Based on this, after the second sampling point is determined as the characteristic point, the amplitude of the point behind the characteristic point on the pulse signal segment can be compared with the first preset amplitude, and the point in the pulse signal segment with an amplitude equal to the first preset amplitude is determined as a new first sampling point, and the amplitude of the previous point of the new first sampling point is less than the first preset amplitude, and the amplitude of the next point is greater than the first preset amplitude.

[0073] Of course, feature points can also be obtained from points in the pulse signal segment whose amplitude is less than the first preset amplitude. In this case, after the second sampling point is determined as the feature point, the point whose amplitude is equal to the first preset amplitude can be determined as the new first sampling point, and the amplitude of the previous point of the new first sampling point is greater than the first preset amplitude, and the amplitude of the next point is less than the first preset amplitude.

[0074] Step S138: If the judgment of step S135 is no, the second sampling point is determined as the new first sampling point, and the process jumps to the step of determining the next point after the first sampling point on the pulse signal segment as the second sampling point, and determining the next point after the second sampling point as the third sampling point, until the pulse signal segment is traversed.

[0075] Among them, if at least one of the first difference and the second difference is outside the preset difference range, it means that the peak point in the cycle has not been found, and it is necessary to continue to obtain new first sampling points, second sampling points and third sampling points from the cycle. Specifically, the second sampling point can be determined as the new first sampling point.

[0076] By obtaining only one peak point as a feature point in each cycle of the pulse signal segment through steps S131 to S138, the time for obtaining the feature points can be greatly shortened, and the waveform output speed of the pulse signal of the physiotherapy device can be indirectly improved, thereby accelerating the research speed of the physiotherapy device.

[0077] Furthermore, in order to further improve the accuracy of the feature points, the pulse signal can be filtered before obtaining the feature points. Specifically, for each cycle of the pulse signal, the average amplitude of the points with an amplitude greater than the first preset amplitude in one cycle is first calculated, and a filtering range is generated based on the average value (for example, plus or minus 50% of the average value is used as the filtering range), and the points with amplitudes greater than the first preset amplitude and outside the filtering range are removed. When it is necessary to obtain feature points from points with amplitudes less than the first preset amplitude in a pulse signal segment, the same method can also be used to filter points with amplitudes less than the first preset amplitude in one cycle.

[0078] After step S130, execute step S140: based on the function formula in the preset function library, fit all the characteristic points of each pulse signal segment to generate a fitting function for each pulse signal segment, wherein the preset function library pre-stores multiple function formulas and the envelope waveform of each function formula.

[0079] Among them, currently, multiple characteristic points of the pulse signal segment are fitted, and the generated fitting function usually corresponds to a certain function, but the coefficients in the function are different, for example, the linear function (f(x) = ax + b), the quadratic function (f(x) = ax 2 +bx+c), exponential function (f(x)=ax b ), etc. Therefore, multiple functional formulas and envelope waveforms of the functional formulas can be pre-stored in the preset function library, for example, the envelope waveform of the linear functional formula is a triangular waveform, the envelope waveform of the quadratic functional formula is a parabolic waveform, etc. Based on the functional formulas in the preset function library, fitting all the characteristic points of each pulse signal segment can effectively ensure the accuracy of the fitting function.

[0080] Further, in order to improve the accuracy of the fitting function, the following steps (steps S141 to S143) may be performed on each pulse signal in step S140:

[0081] Step S141: Substitute all feature points of the pulse signal segment into each functional formula in the preset function library, determine the coefficients of each functional formula, and obtain multiple candidate fitting functions corresponding to the pulse signal segment.

[0082] Step S142: Substitute all feature points of the pulse signal segment into each corresponding candidate fitting function to determine the matching degree between each candidate fitting function and the pulse signal segment.

[0083] Among them, first, all the characteristic points of the pulse signal segment are substituted into each function formula in the preset function library, and the coefficients of each function formula are determined through continuous fitting to obtain multiple candidate fitting functions, that is, each function formula corresponds to a candidate fitting function. Then, the matching degree of each candidate fitting function and the pulse signal segment is calculated. Specifically, similarity or error measurement methods such as mean square error, root mean square error, R square, square absolute error, etc. can be used to quantify the difference between the fitting function and the data point. Taking a candidate fitting function as an example, the time of all characteristic points of the pulse signal segment is substituted into the candidate fitting function to obtain the predicted amplitude corresponding to each characteristic point, and then the mean square error, root mean square error, R square or square absolute error and other data between the actual amplitude and the predicted amplitude of all characteristic points are calculated, and the final data is determined as the matching degree between the candidate fitting function and the pulse signal segment.

[0084] Furthermore, in order to improve the accuracy of the fitting function, step S142 may also perform the following steps (steps S142a to S142d) for each candidate fitting function:

[0085] Step S142a: Substitute the time of all feature points of the pulse signal segment into the candidate fitting function to obtain the predicted amplitude corresponding to each feature point.

[0086] Step S142b: If the difference between the actual amplitude of the feature point and the predicted amplitude corresponding to the feature point is within a first preset error range, it is determined that the feature point is consistent with the candidate fitting function.

[0087] Step S142c: Count the number of feature points in all feature points of the pulse signal segment that are consistent with the candidate fitting function.

[0088] Among them, if the difference between the actual amplitude and the predicted amplitude of the feature point is within the first preset error range, it means that the feature point is very close to the candidate fitting function, and then it can be determined that the feature point is consistent with the candidate fitting function. The more feature points in all the feature points of the pulse signal segment are consistent with the candidate fitting function, the more the candidate fitting function fits the pulse signal segment. Therefore, the number of feature points in all the feature points of the pulse signal segment that are consistent with the candidate fitting function can be counted, and the matching degree of the candidate pulse fitting function and the pulse signal segment can be determined based on the number.

[0089] Step S142d: Calculate the ratio between the number of matching feature points and the total number of feature points of the pulse signal segment to obtain the matching degree between the candidate fitting function and the pulse signal segment.

[0090] Among them, by calculating the ratio between the number of consistent feature points and the total number of feature points of the pulse signal segment, the ratio can be used as the matching degree of the candidate fitting function. The larger the ratio, the higher the matching degree between the candidate fitting function and the pulse signal segment. Of course, for the same pulse signal segment, the total number of feature points is the same, so the number of consistent feature points can also be directly used as the matching degree of the candidate fitting function. The more the number of consistent feature points, the higher the matching degree between the candidate fitting function and the pulse signal segment.

[0091] By counting the number of all feature points of the pulse signal segment that match the candidate fitting function through steps S142a to S142d, the matching degree of the candidate fitting function and the pulse signal segment can be determined, which can effectively ensure that the fitting function fits the feature points of the pulse signal segment as closely as possible, and avoid the problem that the mean square error corresponding to the fitting function is small, but the number of matching feature points is relatively small.

[0092] After step S142, step S143 is executed: determining the candidate fitting function with the highest matching degree as the fitting function of the pulse signal segment.

[0093] Through steps S141 to S143, the characteristic points of the pulse signal segment are first substituted into the function formula and the coefficients of the function formula are determined to obtain multiple candidate fitting functions corresponding to the pulse signal segment, and then the matching degree between each candidate fitting function and the pulse signal segment is calculated, and the candidate fitting function with the highest matching degree is determined as the fitting function of the pulse signal segment. Multiple characteristic points of the pulse signal segment are fit based on each function formula in the preset function library, and the candidate fitting function with the highest matching degree is determined as the fitting function of the pulse signal segment. This can avoid the occurrence of accidental events and effectively improve the accuracy of the fitting function.

[0094] After step S140, step S150 is performed: the envelope waveform of the functional formula corresponding to each fitting function is determined as the envelope waveform of the corresponding pulse signal segment.

[0095] Among them, the envelope waveforms of various functional formulas are stored in the preset function library, and the envelope waveform of the functional formula corresponding to the fitting function can be determined as the envelope waveform of the corresponding pulse signal segment. For example, if the functional formula corresponding to the fitting function is a linear functional formula, the envelope waveform of the corresponding pulse signal segment is a triangular waveform; if the functional formula corresponding to the fitting function is a quadratic functional formula, the envelope waveform of the corresponding pulse signal segment is a parabolic waveform. Of course, the envelope waveform of the functional formula can also be displayed using the first waveform, the second waveform, the third waveform, etc.

[0096] Step S160: outputting the fitting function and envelope waveform of each pulse signal segment in the pulse signal in the order of each pulse signal segment.

[0097] The fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, that is, the fitting function and envelope waveform of the first pulse signal segment are output first, and then the fitting function and envelope waveform of the next pulse signal segment are output. As an example, Figure 3 As shown, the pulse signal can be directly output in the form of "waveform No. 1, envelope number 3", and the frequency, peak-to-peak value, envelope time and other data of each pulse signal segment can also be output, so that the user can directly complete the study of each pulse signal segment based on the output content.

[0098] In the above embodiment, first, after the pulse signal of the physiotherapeutic instrument is obtained, each continuous waveform in the pulse signal is split into a pulse signal segment, so that each pulse signal segment can be analyzed separately more conveniently, which is conducive to improving the accuracy of the fitting function and the envelope waveform. Secondly, at least one peak point in each cycle of the pulse signal segment is used as the characteristic point of the pulse signal segment, and all characteristic points of each pulse signal segment are fitted based on the function formula of the preset function library to determine the fitting function of each pulse signal segment. On the one hand, the fitting function generated according to the characteristic point is more consistent with the shape of the pulse signal segment, which effectively improves the accuracy of the envelope waveform. On the other hand, using the known function formula to fit the characteristic points can speed up the fitting speed and improve the accuracy of the fitting function, indirectly speed up the analysis speed of the physiotherapeutic instrument, and improve the accuracy of the analysis results. Finally, the fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, so that the user can directly analyze the function and effect of the physiotherapeutic instrument according to the output fitting function and envelope waveform, effectively improving the analysis efficiency of the physiotherapeutic instrument.

[0099] Furthermore, two adjacent pulse signal segments in the pulse signal segment output by the physical therapy device may be similar pulse signals. Therefore, in order to make the output content more concise and the user can more conveniently analyze the pulse signal of the physical therapy device, such as Figure 6 As shown, Figure 6 A flow chart of a method for outputting a waveform of a pulse signal of a physiotherapy device provided in another embodiment of the present application is shown. Step S160 may include the following steps (steps S161 to S166):

[0100] Step S161: acquiring two adjacent pulse signal segments according to the order of each pulse signal segment in the pulse signal.

[0101] Step S162: Determine whether the envelope waveforms of two adjacent pulse signal segments are similar.

[0102] According to the order of each pulse signal segment in the pulse signal segment, it is determined whether the envelope waveforms of two adjacent pulse signal segments are similar. If they are similar, the fitting functions and envelope waveforms of the two adjacent pulse signal segments can be integrated together for output, and the process jumps to step S163; if they are not similar, the fitting functions and envelope waveforms of the two adjacent pulse signal segments need to be output separately, and the process jumps to step S164.

[0103] Further, in order to ensure the accuracy of the similarity judgment of the envelope waveforms of two adjacent pulse signal segments and avoid the occurrence of accidental events, step S162 may include the following steps (steps S162a to S162i):

[0104] Step S162a: Calculate the error between the coefficient of the fitting function of the first pulse signal segment and the coefficient of the fitting function of the second pulse signal segment in two adjacent pulse signal segments to obtain the coefficient error.

[0105] Among them, it is first calculated whether the two fitting functions of two adjacent pulse signal segments are similar. Specifically, the error between the two can be determined according to the coefficients, for example, the number of coefficients, the position of coefficients, the relationship between coefficients and parameters, etc. Of course, it is also possible to first determine whether the two function formulas corresponding to the two fitting functions of two adjacent pulse signal segments are the same. If they are not the same, a coefficient error outside the second preset error range is directly assigned. If they are the same, the difference, square difference and other data between the coefficients at the same position in the two fitting functions are calculated as the coefficient error.

[0106] Step S162b: If the coefficient error is outside the second preset error range, the envelope waveforms of two adjacent pulse signal segments are not similar.

[0107] Among them, the second preset error range can be determined based on the coefficients of the two fitting functions of two adjacent pulse signal segments. For example, 10% of the coefficients of one of the fitting functions is used as the second preset error range. In addition, when there are multiple coefficients in the fitting function, in order to ensure the accuracy of the similarity judgment, the coefficient error of each coefficient can be calculated separately to obtain multiple coefficient errors, and each coefficient error can be judged separately whether it is outside the corresponding second preset error range. As long as there is a coefficient error outside the second preset error range, it is judged that the envelope waveforms of the two adjacent pulse signal segments are not similar. Of course, the second preset error range corresponding to each coefficient error can be the same range, or the corresponding range can be determined separately according to each coefficient.

[0108] If the coefficient error is within the second preset error range, perform the following steps:

[0109] Step S162c: Substitute the time of all feature points of the previous pulse signal segment in two adjacent pulse signal segments into the fitting function of the previous pulse signal segment to obtain the predicted amplitude corresponding to each feature point of the previous pulse signal segment.

[0110] Step S162d: Calculate the difference between the actual amplitudes of all feature points of the previous pulse signal segment and the corresponding predicted amplitudes to obtain the error of the fitting function of the previous pulse signal segment.

[0111] Step S162e: Substitute the time of all characteristic points of the latter pulse signal segment of two adjacent pulse signal segments into the fitting function of the latter pulse signal segment to obtain the predicted amplitude corresponding to each characteristic point of the latter pulse signal segment.

[0112] Step S162f: Calculate the difference between the actual amplitudes of all feature points of the subsequent pulse signal segment and the corresponding predicted amplitudes to obtain the error of the fitting function of the subsequent pulse signal segment.

[0113] Among them, if the coefficient error is within the second preset error range, the error of the fitting function of each pulse signal segment in two adjacent pulse signal segments is calculated respectively. Specifically, taking the previous pulse signal segment as an example, the time of all the characteristic points of the previous pulse signal segment can be substituted into the fitting function of the previous pulse signal segment to obtain the predicted amplitude corresponding to each characteristic point. Then the difference between the actual amplitude and the predicted amplitude of all the characteristic points of the previous pulse signal segment is calculated to determine the error of the fitting function of the previous pulse signal segment. For example, the difference is used to calculate the mean square error, root mean square error, R square or square absolute error and other data as the error of the fitting function of the previous pulse signal segment. For the latter pulse signal segment, the same method can also be used to calculate the error of the fitting function of the latter pulse signal.

[0114] Step S162g: Calculate the difference between the error of the fitting function of the previous pulse signal segment and the error of the fitting function of the next pulse signal segment to obtain the fitting error.

[0115] Step S162h: If the fitting error is within the third preset error range, the envelope waveforms of two adjacent pulse signal segments are similar.

[0116] Step S162i: If the fitting error is outside the third preset error range, the envelope waveforms of two adjacent pulse signal segments are not similar.

[0117] Among them, if the fitting error between two adjacent pulse signal segments is also very small, it means that the characteristic points of the two adjacent pulse signal segments are also very similar, that is, the envelope waveforms of the two adjacent pulse signal segments are similar. If the fitting error between two adjacent pulse signal segments is relatively large, it means that although the two fitting functions corresponding to the two adjacent pulse signal segments are very close, the characteristic points of the two adjacent pulse signal segments have relatively large differences, and the envelope waveforms formed by the characteristic points will also have large differences, that is, the envelope waveforms of the two adjacent pulse signal segments are not similar.

[0118] Through steps S162a to S162i, it is determined whether the envelope waveforms of two adjacent pulse signal segments are similar. First, it is determined whether the two fitting functions of the two adjacent pulse signal segments are similar, and then, on the premise that the fitting functions are similar, it is calculated whether the feature points are also relatively similar. Only when the differences between the fitting functions and the feature points are relatively small, the envelope waveforms of the two adjacent pulse signal segments are determined to be similar, which can effectively determine the accuracy of the results.

[0119] After step S162, execute step S163: if step S162 is yes, retain any one of the two adjacent pulse signal segments, and increase the number of envelope waveforms of any one of the pulse signal segments by one, and obtain the next two adjacent pulse signal segments according to the order of the pulse signal segments in the pulse signal, wherein the previous pulse signal segment of the next two adjacent pulse signal segments is the retained arbitrary pulse signal segment.

[0120] Among them, when the envelope waveforms of two adjacent pulse signal segments are similar, any one pulse signal segment is retained, and the number is increased by one, so that the two adjacent pulse signal segments are integrated and output together. Then, any one of the retained pulse signal segments is used as the previous pulse signal segment in the next two adjacent pulse signal segments, and the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal, and the step of determining whether the envelope waveforms of the next two adjacent pulse signal segments are similar is repeated, so that all continuous similar pulse signal segments are integrated and output together.

[0121] Step S164: If step S162 is no, then the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal, wherein the first pulse signal segment in the next two adjacent pulse signal segments is the second pulse signal segment in the next two adjacent pulse signal segments.

[0122] Among them, when the envelope waveforms of two adjacent pulse signal segments are not similar, the two adjacent pulse signal segments need to be output separately, and both adjacent pulse signal segments need to be retained. Then, the latter pulse signal segment of the two adjacent pulse signal segments is used as the former pulse signal segment of the next two adjacent pulse signal segments, and the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal.

[0123] After step S163 and step S164, step S165 is executed: determining whether all pulse signal segments in the pulse signal have been traversed.

[0124] If yes, it means that the similarity of all pulse signal segments in the pulse signal segment is monitored, that is, the latter pulse signal segment of the next two adjacent pulse signal segments is empty, and the continuous similar pulse signal segments have been integrated, and the process directly jumps to step S166;

[0125] If not, it means that the latter pulse signal segment between the two adjacent pulse signal segments has not been monitored for similarity, that is, the latter pulse signal segment between the next two adjacent pulse signal segments is not empty. At this time, it is necessary to continue to judge whether the envelope waveforms of the next two adjacent pulse signal segments obtained in step S163 or step S164 are similar, and jump to step S162.

[0126] Step S166: outputting the fitting function, envelope waveform and number of envelope waveforms of each pulse signal segment in the order of each pulse signal segment in the pulse signal.

[0127] Among them, Figure 4 and Figure 3 As shown, after integrating the continuous similar pulse signals in the pulse signal, the fitting function, envelope waveform and number of envelope waveforms of each pulse signal segment after integration are output according to the order of each pulse signal segment in the pulse signal. Figure 4 After testing the similarity of all pulse signal segments of the pulse signal in Figure 4 The envelope waveforms of the three pulse signal segments in are very similar, so Figure 3 As shown, Figure 4 After integrating the three pulse signal segments in, the output is "the first waveform, the envelope number is 3".

[0128] In the above embodiment, by judging whether the envelope waveforms of two adjacent pulse signal segments are similar, and integrating the continuous similar pulse signals in the pulse signal together for output, the output content can be made more concise without affecting the research results of the physical therapy instrument, thereby enabling the user to more conveniently analyze the pulse signal of the physical therapy instrument, and effectively speeding up the research efficiency of the physical therapy instrument.

[0129] Figure 7 The structure diagram of the waveform output device of the pulse signal of the physiotherapy device provided in the embodiment of the present application is shown. Figure 7 As shown, the waveform output device 5 of the pulse signal of the physiotherapy instrument includes: an acquisition module 51, a splitting module 52, an analysis module 53, a fitting module 54, a determination module 55 and an output module 56.

[0130] The acquisition module 51 is used to acquire the pulse signal of the physiotherapy device. The splitting module 52 is used to split each continuous waveform in the pulse signal into a pulse signal segment. The analysis module 53 is used to analyze each pulse signal segment to obtain multiple feature points of each pulse signal segment, wherein the multiple feature points include at least one peak point in each cycle of the pulse signal segment. The fitting module 54 is used to fit all feature points of each pulse signal segment based on the function formula in the preset function library to generate a fitting function for each pulse signal segment, wherein the preset function library pre-stores multiple function formulas and the envelope waveform of each function formula. The determination module 55 is used to determine the envelope waveform of the function formula corresponding to each fitting function as the envelope waveform of the corresponding pulse signal segment. The output module 56 is used to output the fitting function and envelope waveform of each pulse signal segment in the order of each pulse signal segment in the pulse signal.

[0131] In the above embodiment, first, after the pulse signal of the physiotherapeutic instrument is obtained, each continuous waveform in the pulse signal is split into a pulse signal segment, so that each pulse signal segment can be analyzed separately more conveniently, which is conducive to improving the accuracy of the fitting function and the envelope waveform. Secondly, at least one peak point in each cycle of the pulse signal segment is used as the characteristic point of the pulse signal segment, and all characteristic points of each pulse signal segment are fitted based on the function formula of the preset function library to determine the fitting function of each pulse signal segment. On the one hand, the fitting function generated according to the characteristic point is more consistent with the shape of the pulse signal segment, which effectively improves the accuracy of the envelope waveform. On the other hand, using the known function formula to fit the characteristic points can speed up the fitting speed and improve the accuracy of the fitting function, indirectly speed up the analysis speed of the physiotherapeutic instrument, and improve the accuracy of the analysis results. Finally, the fitting function and envelope waveform of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal, so that the user can directly analyze the function and effect of the physiotherapeutic instrument according to the output fitting function and envelope waveform, effectively improving the analysis efficiency of the physiotherapeutic instrument.

[0132] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application is shown, and the specific embodiment of the present application does not limit the specific implementation of the electronic device.

[0133] like Figure 8 As shown, the electronic device 1 may include: a processor (processor) 11 and a memory (memory) 12.

[0134] The memory 12 is used to store a computer program 13. The memory 12 may include a high-speed RAM memory, or may also include a non-volatile memory, such as at least one disk memory. The computer program 13 may include computer executable instructions.

[0135] The processor 11 is used to execute the computer program 13 to implement the waveform output method embodiment of the pulse signal of the physiotherapy device.

[0136] The processor 11 may be a central processing unit (CPU), or an application-specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present application. The one or more processors included in the electronic device 1 may be processors of the same type, such as one or more CPUs; or may be processors of different types, such as one or more CPUs and one or more ASICs.

[0137] An embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the embodiment of the waveform output method of the pulse signal of the above-mentioned physiotherapy device is implemented.

[0138] An embodiment of the present application provides a computer program, which can be executed by a processor to implement the above-mentioned waveform output method embodiment of the physiotherapy device pulse signal.

[0139] An embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the embodiment of the waveform output method of the pulse signal of the above-mentioned physiotherapy device is implemented.

[0140] In several embodiments provided in the present application, if any function is implemented in the form of a software function module / unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, part or all of the technical solution of the present application can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, server or other electronic device) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (RandomAccess Memory, RAM), disk or optical disk and other media that can store computer program code.

[0141] The algorithm or display provided here are not inherently related to any specific computer, virtual system or other equipment. Various general systems can also be used together with the teaching based on this. According to the above description, it is obvious to construct the structure required for this type of system. In addition, the present application embodiment is not directed to any specific programming language yet. It should be understood that various programming languages ​​can be utilized to realize the content of the present application described here, and the above description of specific languages ​​is to disclose the best mode of implementation of the present application.

[0142] It should be noted that the above embodiments illustrate the present application rather than limit the present application, and that those skilled in the art may design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets shall not be constructed as a limitation on the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of multiple such elements. The present application may be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In the claims that list several devices, several units or modules in these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names. The steps in the above embodiments, unless otherwise specified, should not be understood as limitations on the order of execution.

[0143] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A waveform output method of a pulse signal of a physical therapy instrument, characterized in that: The method comprises: Obtain pulse signals from a physical therapy device; Splitting each continuous waveform in the pulse signal into a pulse signal segment; Analyze each pulse signal segment to obtain multiple characteristic points of each pulse signal segment, wherein the multiple characteristic points include at least one peak point in each cycle of the pulse signal segment; Based on the function formula in the preset function library, all the characteristic points of each pulse signal segment are fitted to generate the fitting function of each pulse signal segment, wherein the preset function library pre-stores a plurality of function formulas and the envelope waveform of each function formula; Determine the envelope waveform of the functional formula corresponding to each fitting function as the envelope waveform of the corresponding pulse signal segment; The fitting function and envelope waveform of each pulse signal segment are outputted in the order of each pulse signal segment in the pulse signal.

2. The waveform output method of the pulse signal of the physiotherapy instrument according to claim 1, characterized in that: The step of obtaining the pulse signal of the physical therapy apparatus specifically includes: Obtain a first time and a first amplitude corresponding thereto, a second time and a second amplitude corresponding thereto; Acquire a pulse signal between the first time and the second time to obtain the pulse signal; Calculating the difference between the first time and the second time to obtain the time difference of the pulse signal; Calculating the difference between the first amplitude and the second amplitude to obtain the amplitude difference of the pulse signal; Calculating parameter information of the pulse signal, the parameter information including frequency, peak-to-peak value and pulse width of the pulse signal; The time difference, the amplitude difference, the frequency, the peak-to-peak value and the pulse width of the pulse signal are output.

3. The waveform output method of the pulse signal of the physiotherapy instrument according to claim 1, characterized in that: The method of fitting all characteristic points of each pulse signal segment based on the function formula in the preset function library to generate a fitting function for each pulse signal segment specifically includes: For each pulse signal segment, the following steps are performed: Substituting all feature points of the pulse signal segment into each functional formula in the preset function library, determining the coefficients of each functional formula, and obtaining a plurality of candidate fitting functions corresponding to the pulse signal segment; Substituting all feature points of the pulse signal segment into each candidate fitting function corresponding thereto, and determining a matching degree between each candidate fitting function and the pulse signal segment; The candidate fitting function with the highest matching degree is determined as the fitting function of the pulse signal segment.

4. The waveform output method of the pulse signal of the physical therapy instrument according to claim 3, characterized in that: Substituting all the characteristic points of the pulse signal segment into each candidate fitting function corresponding thereto, and determining the matching degree between each candidate fitting function and the pulse signal segment, specifically includes: For each candidate fitting function, the following steps are performed: Substituting the time of all feature points of the pulse signal segment into the candidate fitting function to obtain the predicted amplitude corresponding to each feature point; If the difference between the actual amplitude of the feature point and the predicted amplitude corresponding to the feature point is within a first preset error range, then it is determined that the feature point is consistent with the candidate fitting function; Counting the number of feature points that are consistent with the candidate fitting function among all feature points of the pulse signal segment; The ratio between the number of the matching feature points and the total number of feature points of the pulse signal segment is calculated to obtain a matching degree between the candidate fitting function and the pulse signal segment.

5. The waveform output method of the pulse signal of the physical therapy instrument according to claim 1, characterized in that: The step of outputting the fitting function and envelope waveform of each pulse signal segment in the pulse signal in the order of each pulse signal segment specifically includes: Acquire two adjacent pulse signal segments according to the order of each pulse signal segment in the pulse signal; Determining whether the envelope waveforms of the two adjacent pulse signal segments are similar; If the envelope waveforms of the two adjacent pulse signal segments are similar, then any one of the two adjacent pulse signal segments is retained, and the number of envelope waveforms of the any one pulse signal segment is increased by one, and the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal, and the step of determining whether the envelope waveforms of the two adjacent pulse signal segments are similar is jumped to until all the pulse signal segments in the pulse signal are traversed, wherein the previous pulse signal segment of the next two adjacent pulse signal segments is the retained any one pulse signal segment; If the envelope waveforms of the two adjacent pulse signal segments are not similar, then the next two adjacent pulse signal segments are obtained according to the order of the pulse signal segments in the pulse signal, and the step of directly jumping to the step of determining whether the envelope waveforms of the two adjacent pulse signal segments are similar is performed until all the pulse signal segments in the pulse signal are traversed, wherein the previous pulse signal segment in the next two adjacent pulse signal segments is the latter pulse signal segment in the two adjacent pulse signal segments; The fitting function, envelope waveform and the number of envelope waveforms of each pulse signal segment are output according to the order of each pulse signal segment in the pulse signal.

6. The waveform output method of the pulse signal of the physical therapy instrument according to claim 5, characterized in that: The determining whether the envelope waveforms of the two adjacent pulse signal segments are similar specifically includes: Calculating the error between the coefficient of the fitting function of the first pulse signal segment and the coefficient of the fitting function of the second pulse signal segment in the two adjacent pulse signal segments to obtain a coefficient error; If the coefficient error is outside the second preset error range, the envelope waveforms of the two adjacent pulse signal segments are not similar; If the coefficient error is within the second preset error range, perform the following steps: Substituting the time of all characteristic points of the previous pulse signal segment of the two adjacent pulse signal segments into the fitting function of the previous pulse signal segment to obtain the predicted amplitude corresponding to each characteristic point of the previous pulse signal segment; Calculating the difference between the actual amplitudes of all feature points of the previous pulse signal segment and the corresponding predicted amplitudes to obtain the error of the fitting function of the previous pulse signal segment; Substituting the time of all characteristic points of the latter pulse signal segment of the two adjacent pulse signal segments into the fitting function of the latter pulse signal segment to obtain the predicted amplitude corresponding to each characteristic point of the latter pulse signal segment; Calculating the difference between the actual amplitudes of all feature points of the latter pulse signal segment and the corresponding predicted amplitudes to obtain the error of the fitting function of the latter pulse signal segment; Calculating the difference between the error of the fitting function of the previous pulse signal segment and the error of the fitting function of the next pulse signal segment to obtain a fitting error; If the fitting error is within a third preset error range, the envelope waveforms of the two adjacent pulse signal segments are similar; If the fitting error is outside the third preset error range, the envelope waveforms of the two adjacent pulse signal segments are not similar.

7. The waveform output method of the pulse signal of the physical therapy instrument according to claim 1, characterized in that: The analysis of each pulse signal segment to obtain multiple characteristic points of each pulse signal segment specifically includes: For each pulse signal segment, perform the following steps respectively: Determine in sequence the first point in the pulse signal segment whose amplitude is greater than or equal to the first preset amplitude as the first sampling point; Determine a point after the first sampling point on the pulse signal segment as a second sampling point, and determine a point after the second sampling point as a third sampling point; Calculating a difference between the amplitude of the first sampling point and the amplitude of the second sampling point to obtain a first difference; Calculate the difference between the amplitude of the second sampling point and the amplitude of the second sampling point to obtain a second difference; Determining whether the first difference and the second difference are both within a preset difference range; If yes, determining the second sampling point as the feature point; Determine a point in the pulse signal segment whose amplitude is equal to the first preset amplitude as a new first sampling point, and jump to the step of determining a subsequent point of the first sampling point on the pulse signal segment as a second sampling point, and determining a subsequent point of the second sampling point as a third sampling point, until the pulse signal segment is traversed, wherein the amplitude of the previous point of the new first sampling point is less than the first preset amplitude, and the amplitude of the subsequent point of the new first sampling point is greater than the first preset amplitude; If not, the second sampling point is determined as the new first sampling point, and the process jumps to the step of determining the next point after the first sampling point on the pulse signal segment as the second sampling point, and determining the next point after the second sampling point as the third sampling point, until the pulse signal segment is traversed.

8. The waveform output method of the pulse signal of the physical therapy instrument according to claim 1, characterized in that: The step of dividing each continuous waveform in the pulse signal into a pulse signal segment specifically includes: Determine a pulse signal segment in the pulse signal whose amplitude is continuously equal to the second preset amplitude and whose duration is greater than or equal to the preset time as a pause segment; The pulse signal before the first pause segment, the pulse signal after the last pause segment, and the pulse signal between all two adjacent pause segments in the pulse signal are respectively divided into a pulse signal segment in sequence.

9. A waveform output device for a pulse signal of a physical therapy instrument, characterized in that: The device comprises: An acquisition module is used to acquire the pulse signal of the physical therapy device; A splitting module, used for splitting each continuous waveform in the pulse signal into a pulse signal segment; An analysis module, used for analyzing each pulse signal segment to obtain a plurality of characteristic points of each pulse signal segment, wherein the plurality of characteristic points include at least one peak point in each cycle of the pulse signal segment; A fitting module, used for fitting all characteristic points of each pulse signal segment based on a function formula in a preset function library to generate a fitting function for each pulse signal segment, wherein the preset function library pre-stores a plurality of function formulas and an envelope waveform of each function formula; A determination module, used to determine the envelope waveform of the functional formula corresponding to each fitting function as the envelope waveform of the corresponding pulse signal segment; The output module is used to output the fitting function and envelope waveform of each pulse signal segment in the pulse signal according to the order of each pulse signal segment in the pulse signal.

10. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the waveform output method of the pulse signal of the physiotherapy device as described in any one of claims 1 to 8.