Digital filtering method for asynchronous communication
By introducing a high- and low-level dual threshold comparison mechanism and a sampling cooling mechanism into the digital filter, the adaptability of the signal sample window is achieved, which solves the problem of poor filtering ability of the digital filter in a high-noise environment and significantly improves the filtering efficiency. Recognition success rate and robustness.
Patent Information
- Application Number
- CN202410789564.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-19
- Publication Date
- 2024-10-01
AI Technical Summary
Existing digital filters have poor filtering capabilities for source signal interference noise in high-noise environments, resulting in poor recognition results.
By introducing a high and low level dual threshold comparison mechanism and a sampling cooling mechanism, the adaptability of the signal sample window is achieved, the counting value of the counter is adjusted to output the filtering recognition result, and the fault tolerance rate and robustness of the filter are improved.
The filter recognition success rate and robustness of the digital filter are significantly improved to meet the signal processing needs in high-noise environments in asynchronous communications.
Smart Images

Figure CN118740113A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of signal processing, and in particular to a digital filtering method for asynchronous communication. Background Art
[0002] A digital filter is an algorithm or device composed of a digital multiplier, an adder, and a delay unit. Its function is to process the digital code of the input discrete signal to achieve the purpose of changing the signal spectrum. In the field of asynchronous communication, the average value is usually calculated based on sampling and sliding average within a certain number of sample windows to complete the noise filtering and signal compensation of digital signals.
[0003] However, when the interference of the input source signal increases or the noise duty cycle is high, the digital filter has poor filtering capability for source signal interference noise due to the constant width of the sample window. Summary of the invention
[0004] The technical problem to be solved by the present invention is to provide a digital filtering method for asynchronous communication in order to overcome the defect that the digital filter in the prior art has poor filtering capability for source signal interference noise.
[0005] The present invention solves the above technical problems through the following technical solutions:
[0006] In a first aspect, the present invention provides a digital filtering method for asynchronous communication, the digital filtering method comprising:
[0007] When the filter is powered on, the count value of the counter is initialized; the count value includes the first count value of the high level counter, the second count value of the low level counter and the third count value of the cooling counter;
[0008] The signal is sampled by a high-frequency clock to obtain a sampled signal; after each signal sampling, the third count value is increased by 1;
[0009] When it is detected that the third count value is greater than the first threshold, determining the level state of the sampling signal;
[0010] When the sampling signal is at a high level, the first count value is increased by 1, and when the sampling signal is at a low level, the second count value is increased by 1;
[0011] When the first count value reaches the second threshold, the first filtering and identifying result is output, or when the second count value reaches the second threshold, the second filtering and identifying result is output.
[0012] Preferably, the digital filtering method further comprises:
[0013] After outputting the first filtering identification result or the second filtering identification result, if the filtering process is not completed, the first count value and the second count value are set to 0 and the third count value is set to 1; if the filtering process is completed, the count value of the counter is initialized again.
[0014] Preferably, the digital filtering method further comprises:
[0015] When it is detected that the third count value is not greater than the first threshold, the process returns to the step of sampling the signal by using the high-frequency clock to obtain the sampled signal.
[0016] Preferably, the initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
[0017] In a second aspect, the present invention provides a digital filtering system for asynchronous communication, the digital filtering system comprising:
[0018] A first initialization module, used to initialize the count value of the counter when the filter is powered on; the count value includes a first count value of the high level counter, a second count value of the low level counter and a third count value of the cooling counter;
[0019] A sampling module, used for sampling a signal through a high-frequency clock to obtain a sampling signal; after each signal sampling, the third count value is increased by 1;
[0020] A first detection module, configured to determine a level state of the sampling signal when detecting that the third count value is greater than a first threshold;
[0021] A counting module, configured to increase the first count value by 1 when the sampling signal is at a high level, and to increase the second count value by 1 when the sampling signal is at a low level;
[0022] The identification module is used to output a first filtering identification result when the first count value reaches a second threshold, or to output a second filtering identification result when the second count value reaches the second threshold.
[0023] Preferably, the digital filtering system further comprises:
[0024] The second initialization module is used to set the first count value and the second count value to 0 and the third count value to 1 after outputting the first filtering identification result or the second filtering identification result, if the filtering process is not completed, and to initialize the count value of the counter again if the filtering process is completed.
[0025] Preferably, the digital filtering system further comprises:
[0026] The second detection module is used to return to the step of sampling the signal by the high-frequency clock to obtain the sampling signal when it is detected that the third count value is not greater than the first threshold.
[0027] Preferably, the initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
[0028] In a third aspect, the present invention provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the digital filtering method for asynchronous communication as described above when executing the computer program.
[0029] In a fourth aspect, the present invention provides a computer-readable storage medium, wherein a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the digital filtering method for asynchronous communication as described above is implemented.
[0030] The positive and progressive effect of the present invention is that by introducing a high and low level dual threshold comparison mechanism and a sampling cooling mechanism of the sampling signal, the adaptability of the signal sample window is achieved, and the fault tolerance and robustness of the filter recognition are significantly improved to meet the digital filtering requirements of the input signal in asynchronous communication. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 Schematic diagram of the flow of the digital filtering method for asynchronous communication according to Embodiment 1 of the present invention.
[0032] Figure 2 This is a module diagram of a digital filtering system for asynchronous communication according to Embodiment 2 of the present invention.
[0033] Figure 3 This is a schematic diagram of the structure of an electronic device for implementing a digital filtering method for asynchronous communication according to Embodiment 3 of the present invention. DETAILED DESCRIPTION
[0034] The present invention is further described below by way of examples, but the present invention is not limited to the scope of the examples.
[0035] Example 1
[0036] The digital filtering method for asynchronous communication of this embodiment is as follows: Figure 1 As shown, by way of example and not limitation, the digital filtering method includes:
[0037] S11, when the filter is powered on, the count value of the counter is initialized; the count value includes the first count value of the high level counter, the second count value of the low level counter and the third count value of the cooling counter;
[0038] S12, sampling the signal by a high-frequency clock to obtain a sampling signal; after each signal sampling, the third count value is increased by 1;
[0039] S131, when it is detected that the third count value is greater than the first threshold, determining the level state of the sampling signal;
[0040] S14, when the sampling signal is at a high level, the first count value is increased by 1, and when the sampling signal is at a low level, the second count value is increased by 1;
[0041] S15. When the first count value reaches the second threshold, the first filtering and identifying result is outputted; or when the second count value reaches the second threshold, the second filtering and identifying result is outputted.
[0042] S16. After outputting the first filtering identification result or the second filtering identification result, if the filtering process is not completed, the first count value and the second count value are set to 0 and the third count value is set to 1. If the filtering process is completed, the count value of the counter is initialized again.
[0043] The initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
[0044] The digital filtering method also includes:
[0045] S132: When it is detected that the third count value is not greater than the first threshold, execute step S12.
[0046] Specifically, when the filter is powered on, the initial value of the first count value of the high level counter is set to 0, the initial value of the second count value of the low level counter is set to 0, and the initial value of the third count value of the cooling counter is set to the sampling rate multiple / 2-1. When the signal is sampled by using an N-fold high frequency clock (N is an even number greater than 2, called the sampling rate multiple) to obtain a sampled signal, the third count value of the cooling counter is increased by 1 after each signal sampling. If the third count value of the cooling counter is greater than the sampling rate multiple / 2-1, the level of the sampling signal is further judged. When the sampling signal is at a high level, the first count value is increased by 1, otherwise when the sampling signal is at a low level, the second count value is increased by 1. When it is detected that the third count value is not greater than the first threshold, the step of sampling the signal by the high frequency clock is returned. Until the first count value of the high level counter reaches the second threshold (for example, the sampling rate multiple / 2), the first filtering identification result is output, or until the second count value of the low level counter reaches the second threshold, the second filtering identification result is output. If the filtering process is not finished, the first count value and the second count value are initialized to 0 and the third count value is set to 1. Regardless of whether the high and low level counters reach the threshold, if the communication process is not finished, the next high frequency sampling is continued until the communication is finished.
[0047] In this embodiment, a digital filtering method for asynchronous communication is provided. A high-level counter, a low-level counter and a cooling counter are used to introduce a high-low level dual threshold comparison mechanism and a sampling cooling mechanism for the sampling signal. Compared with the traditional sliding average filtering algorithm, the adaptability of the sample window is achieved, and the filtering recognition success rate and robustness of the digital filter are significantly improved to meet the digital filtering requirements in asynchronous communication.
[0048] Example 2
[0049] This embodiment provides a digital filtering system for asynchronous communication, such as Figure 2 As shown, by way of example and not limitation, the digital filtering system includes: a first initialization module 210 , a sampling module 220 , a first detection module 231 , a counting module 240 , an identification module 250 and a second initialization module 260 .
[0050] Wherein, the first initialization module 210 is used to initialize the count value of the counter when the filter is powered on; the count value includes the first count value of the high level counter, the second count value of the low level counter and the third count value of the cooling counter;
[0051] The sampling module 220 is used to sample the signal through a high-frequency clock to obtain a sampled signal; after each signal sampling, the third count value is increased by 1;
[0052] The first detection module 231 is used to determine the level state of the sampling signal when it is detected that the third count value is greater than the first threshold;
[0053] The counting module 240 is used to increase the first count value by 1 when the sampling signal is at a high level, and to increase the second count value by 1 when the sampling signal is at a low level;
[0054] The identification module 250 is configured to output a first filtering identification result when the first count value reaches a second threshold, or to output a second filtering identification result when the second count value reaches a second threshold.
[0055] The second initialization module 260 is used to set the first count value and the second count value to 0 and the third count value to 1 after outputting the first filtering recognition result or the second filtering recognition result, if the filtering process is not completed, and to initialize the count value of the counter again if the filtering process is completed.
[0056] The second detection module 232 is configured to return to the step of sampling the signal by the high-frequency clock to obtain the sampled signal when it is detected that the third count value is not greater than the first threshold.
[0057] The initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
[0058] Specifically, when the filter is powered on, the initial value of the first count value of the high level counter is set to 0, the initial value of the second count value of the low level counter is set to 0, and the initial value of the third count value of the cooling counter is set to the sampling rate multiple / 2-1. The first initialization module 210 sets the initial value of the first count value of the high level counter to 0, the initial value of the second count value of the low level counter to 0, and the initial value of the third count value of the cooling counter to the sampling rate multiple / 2-1. The sampling module 220 continues to sample the signal through the high-frequency clock, and after each signal sampling, the third count value of the cooling counter is increased by 1. If the third count value of the cooling counter is greater than the sampling rate multiple / 2-1, the first detection module 231 judges the sampling signal. When the sampling signal is at a high level, the first count value is increased by 1, otherwise when the sampling signal is at a low level, the second count value is increased by 1. When the second detection module 232 detects that the third count value is not greater than the first threshold, it returns to sampling the signal through the high-frequency clock to obtain the sampling signal.
[0059] The identification module 250 outputs the first filtering identification result until the first count value of the high level counter reaches the second threshold value (e.g., sampling rate multiple / 2), or outputs the second filtering identification result until the second count value of the low level counter reaches the second threshold value. The second initialization module 260 initializes the first count value and the second count value to 0 and sets the third count value to 1. Regardless of whether the high and low level counters reach the threshold value, if the communication process is not over, the next high frequency sampling is continued until the communication is over.
[0060] In the present embodiment, a digital filtering system for asynchronous communication is provided. A high-level counter, a low-level counter and a cooling counter are used to introduce a high-low level dual threshold comparison mechanism and a sampling cooling mechanism for the sampling signal. Compared with the traditional sliding average filtering algorithm, the adaptability of the sample window is achieved, and the filtering recognition success rate and robustness of the digital filter are significantly improved to meet the digital filtering requirements in asynchronous communication.
[0061] Example 3
[0062] Figure 3 The electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the digital filtering method for asynchronous communication of the first embodiment is implemented. Figure 3 The electronic device 90 shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0063] like Figure 3 As shown, the electronic device 90 may be in the form of a general-purpose computing device, for example, it may be a server device. The components of the electronic device 90 may include, but are not limited to: at least one processor 91, at least one memory 92, and a bus 93 connecting different system components (including the memory 92 and the processor 91).
[0064] The bus 93 includes a data bus, an address bus, and a control bus.
[0065] The memory 92 may include a volatile memory, such as a random access memory (RAM) 921 and / or a cache memory 922 , and may further include a read-only memory (ROM) 923 .
[0066] The memory 92 may also include a program / utility 925 having a set (at least one) of program modules 924, such program modules 924 including but not limited to: an operating system, one or more application programs, other program modules and program data, each of which or some combination may include an implementation of a network environment.
[0067] The processor 91 executes various functional applications and data processing by running the computer programs stored in the memory 92, such as the digital filtering method for asynchronous communication of the first embodiment of the present invention.
[0068] The electronic device 90 may also communicate with one or more external devices 94 (e.g., keyboards, pointing devices, etc.). Such communication may be performed via an input / output (I / O) interface 95. Furthermore, the model generating device 90 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 96. Figure 3 As shown, the network adapter 96 communicates with other modules of the model-generated device 90 via the bus 93. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the model-generated device 90, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID (disk array) systems, tape drives, and data backup storage systems, etc.
[0069] It should be noted that although several units / modules or sub-units / modules of the electronic device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to an embodiment of the present invention, the features and functions of two or more units / modules described above can be embodied in one unit / module. Conversely, the features and functions of one unit / module described above can be further divided into multiple units / modules to be embodied.
[0070] Example 4
[0071] This embodiment provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the steps in the digital filtering method for asynchronous communication of Embodiment 1 are implemented.
[0072] The readable storage medium may include but is not limited to: a portable disk, a hard disk, a random access memory, a read-only memory, an erasable programmable read-only memory, an optical storage device, a magnetic storage device or any suitable combination of the above.
[0073] In a possible implementation manner, the present invention may also be implemented in the form of a program product, which includes program code. When the program product runs on a terminal device, the program code is used to enable the terminal device to execute the steps in the digital filtering method for asynchronous communication of embodiment 1.
[0074] Among them, the program code for executing the present invention can be written in any combination of one or more programming languages, and the program code can be executed completely on the user device, partially on the user device, as an independent software package, partially on the user device and partially on a remote device, or completely on the remote device.
[0075] Although the specific embodiments of the present invention are described above, it should be understood by those skilled in the art that this is only for illustration and the protection scope of the present invention is defined by the appended claims. Those skilled in the art may make various changes or modifications to these embodiments without departing from the principles and essence of the present invention, but these changes and modifications all fall within the protection scope of the present invention.
Claims
1. A digital filtering method for asynchronous communication, characterized in that: The digital filtering method comprises: When the filter is powered on, the count value of the counter is initialized; the count value includes the first count value of the high level counter, the second count value of the low level counter and the third count value of the cooling counter; The signal is sampled by a high-frequency clock to obtain a sampled signal; after each signal sampling, the third count value is increased by 1; When it is detected that the third count value is greater than the first threshold, determining the level state of the sampling signal; When the sampling signal is at a high level, the first count value is increased by 1, and when the sampling signal is at a low level, the second count value is increased by 1; When the first count value reaches the second threshold, the first filtering and identifying result is output, or when the second count value reaches the second threshold, the second filtering and identifying result is output.
2. The digital filtering method for asynchronous communication according to claim 1, characterized in that: The digital filtering method further comprises: After outputting the first filtering identification result or the second filtering identification result, if the filtering process is not completed, the first count value and the second count value are set to 0 and the third count value is set to 1; if the filtering process is completed, the count value of the counter is initialized again.
3. The digital filtering method for asynchronous communication according to claim 1, characterized in that: The digital filtering method further comprises: When it is detected that the third count value is not greater than the first threshold, the process returns to the step of sampling the signal by using the high-frequency clock to obtain the sampled signal.
4. The digital filtering method for asynchronous communication according to claim 1, characterized in that: The initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
5. A digital filtering system for asynchronous communication, characterized in that: The digital filtering system comprises: A first initialization module, used to initialize the count value of the counter when the filter is powered on; the count value includes a first count value of the high level counter, a second count value of the low level counter and a third count value of the cooling counter; A sampling module, used for sampling a signal through a high-frequency clock to obtain a sampling signal; after each signal sampling, the third count value is increased by 1; A first detection module, configured to determine a level state of the sampling signal when detecting that the third count value is greater than a first threshold; A counting module, configured to increase the first count value by 1 when the sampling signal is at a high level, and to increase the second count value by 1 when the sampling signal is at a low level; The identification module is used to output a first filtering identification result when the first count value reaches a second threshold, or to output a second filtering identification result when the second count value reaches the second threshold.
6. The digital filtering system for asynchronous communication as claimed in claim 5, characterized in that: The digital filtering system further comprises: The second initialization module is used to set the first count value and the second count value to 0 and the third count value to 1 after outputting the first filtering identification result or the second filtering identification result, if the filtering process is not completed, and to initialize the count value of the counter again if the filtering process is completed.
7. The digital filtering system for asynchronous communication as claimed in claim 5, characterized in that: The digital filtering system further comprises: The second detection module is used to return to the step of sampling the signal by the high-frequency clock to obtain the sampling signal when it is detected that the third count value is not greater than the first threshold.
8. The digital filtering system for asynchronous communication as claimed in claim 5, characterized in that: The initial values of the first count value and the second count value are both 0, the initial value of the third count value is the sampling rate multiple / 2, and the first threshold is the sampling rate multiple / 2-1.
9. An electronic device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed by the processor, the digital filtering method for asynchronous communication according to any one of claims 1 to 4 is implemented.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the digital filtering method for asynchronous communication according to any one of claims 1 to 4 is implemented.
Citation Information
Cited By
Asynchronous communication method based on FPGA
CN119921904A
