A piano keystroke force detection system
By designing a contactless piano keystroke force detection system and using audio analysis technology to measure keystroke force, the existing system affects piano pronunciation and cannot detect multiple pianos, achieving flexible and accurate detection effects.
Patent Information
- Application Number
- CN202411423800.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-12
- Publication Date
- 2025-04-08
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing piano keystroke force detection system is in contact with the piano. The detection process will affect the pronunciation of the piano and cannot flexibly detect multiple pianos.
A contactless piano keystroke force detection system is designed. Through the audio acquisition module, audio division module, velocity detection module and standard calibration module, audio information during piano keystroke, measure keystroke force, and correct parameters through standard calibration module.
It realizes real-time detection of piano keystroke force without affecting piano pronunciation, and the system is flexible and can be used for detection of multiple pianos.
Smart Images

Figure CN119785742A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of electronic digital data processing, and in particular to a piano keystroke force detection system. Background Art
[0002] During piano playing, the force of keystrokes has a major influence on the pronunciation of the piano. In normal piano practice, problems in playing are usually judged by listening, but this method relies on experience. Therefore, a quantitative detection system is needed to detect the keystroke force to assist piano practice and achieve better practice results.
[0003] The foregoing discussion of the background art is intended only to facilitate an understanding of the present invention. This discussion does not acknowledge or admit that any of the material referred to is part of the common general knowledge.
[0004] Many keystroke detection systems have been developed. After a lot of searching and reference, it is found that the existing keystroke detection systems are such as the system disclosed in the publication number CN110491357B. These systems generally include: a piano and a mobile terminal. The piano is provided with a controller and a plurality of photoelectric sensors. The controller is provided with a first wireless communication module. The photoelectric sensors are provided under the piano keys and correspond to the piano keys one by one. Each photoelectric sensor is connected to the controller. The mobile terminal is provided with a second wireless communication module and an application client. The application client is connected to the controller through the first wireless communication module and the second wireless communication module. The application client is provided with a key button, a force adjustment button and a confirmation button. However, the system is in contact with the piano, and the detection process will directly affect the pronunciation of the piano. At the same time, the system is paired with the target piano, and it is impossible to use one detection system to detect multiple pianos, and it does not have the flexibility of detection. Summary of the invention
[0005] The purpose of the present invention is to propose a piano keystroke force detection system in view of the existing deficiencies.
[0006] The present invention adopts the following technical solution:
[0007] A piano keystroke force detection system includes an audio acquisition module, an audio segmentation module, a force detection module and a standard correction module;
[0008] The audio acquisition module is used to collect audio information generated when keystrokes are made, the audio segmentation module is used to segment and extract audio information of each keystroke from the audio information, the force detection module is used to analyze the independent keystroke audio information to measure the corresponding keystroke force, and the standard correction module is used to provide a standard keystroke force and correct the parameters in the force detection module;
[0009] The audio acquisition module includes a microphone acquisition unit and an audio preprocessing unit, wherein the microphone acquisition unit is used to capture audio information at a fixed position, and the audio preprocessing unit is used to perform filtering and denoising on the captured audio information;
[0010] The audio segmentation module includes an event detection unit and a data segmentation unit, wherein the event detection unit is used to identify the start and end of a keystroke event, and the data segmentation unit segments the audio information according to the detected event;
[0011] The force detection module includes a feature extraction unit and a force analysis unit, wherein the feature extraction unit is used to extract feature data of the audio information of each keystroke event, and the force analysis unit calculates the keystroke force of each keystroke event based on the feature data;
[0012] The standard correction module includes a standard striking unit and a correction adjustment unit, wherein the standard striking unit is used to provide a fixed force to strike the piano keys, and the correction adjustment unit is used to perform correction processing on the parameters in the force analysis unit;
[0013] Furthermore, the data segmentation unit includes an event information register, an audio interception processor and an audio purification processor, wherein the event information register is used to store the segmentation information of each keystroke event, the audio interception processor is used to segment the original audio information, and the audio purification processor is used to purify the segmented audio information to obtain independent audio information;
[0014] Furthermore, the audio purification processor calculates the primary independent audio information S1(t) according to the following formula:
[0015]
[0016] Among them, S'(t) is the intercepted original audio information, N is the harmonic order considered, M is the number of independent pre-audio considered, λ i represents the attenuation coefficient of the previous i-th keystroke event, t i Indicates the time interval between the previous i-th keystroke event and the current keystroke event, A i,n represents the initial amplitude of the nth harmonic of the previous i-th keystroke event, f i,n represents the frequency of the nth harmonic of the previous i-th keystroke event;
[0017] The audio purification processor calculates the attenuation coefficient λ according to the primary independent audio information and saves it to the event information register:
[0018]
[0019] Where A0 is the initial amplitude of the fundamental wave, A′ is the amplitude of the fundamental wave sampling point, and Δt is the time interval between the sampling point and the initial amplitude time point;
[0020] The audio purification processor calculates the independent audio information S(t) according to the following formula:
[0021]
[0022] Among them, λ + is the attenuation coefficient of the next keystroke event, t + Indicates the time interval between the next keystroke event and the current keystroke event, A n+ represents the initial amplitude of the nth-order harmonic of the next keystroke event, f n+ represents the frequency of the nth-order harmonic of the next keystroke event, and T is the duration of the current keystroke event;
[0023] Furthermore, the feature extraction unit includes a key recognition processor and an amplitude analysis processor, wherein the key recognition processor is used to recognize the key type, and the amplitude analysis processor is used to analyze and process the amplitude information in the independent audio information;
[0024] The amplitude analysis processor obtains the amplitude information in the independent audio information and calculates the amplitude correlation value P according to the following formula:
[0025]
[0026] Among them, A1(i) represents the i-th amplitude value of the fundamental wave, A n (i) represents the i-th amplitude value of the n-th order harmonic, and L is the number of samples of the fundamental wave;
[0027] Furthermore, the force analysis unit includes a parameter register and a force calculation processor, wherein the parameter register is used to store the force calculation parameters of each key type, and the force calculation processor is used to calculate the keystroke force value;
[0028] The force calculation processor outputs the keystroke force value F according to the following formula:
[0029] F=(α·P c +β)·A 1max ;
[0030] Among them, α and β are strength calculation parameters, c is the correction parameter, A 1max is the maximum amplitude of the fundamental wave.
[0031] The beneficial effects achieved by the present invention are:
[0032] This system collects the audio information of the piano to analyze and detect the piano's keystroke force. It has the characteristics of non-contact and will not affect the piano's pronunciation during the detection process. It is suitable for real-time detection during piano practice. At the same time, the system is fluid and is not bound to a specific piano. It can flexibly detect multiple pianos.
[0033] To further understand the features and technical contents of the present invention, please refer to the following detailed description and drawings of the present invention. However, the drawings provided are only for reference and description and are not intended to limit the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 It is a schematic diagram of the overall structural framework of the present invention;
[0035] Figure 2 This is a schematic diagram of the audio segmentation module of the present invention;
[0036] Figure 3 This is a schematic diagram of the force detection module of the present invention;
[0037] Figure 4 This is a schematic diagram of the event detection unit of the present invention;
[0038] Figure 5 It is a schematic diagram of the data segmentation unit of the present invention. DETAILED DESCRIPTION
[0039] The following is an explanation of the embodiments of the present invention through specific embodiments. Those skilled in the art can understand the advantages and effects of the present invention from the contents disclosed in this specification. The present invention can be implemented or applied through other different specific embodiments, and the details in this specification can also be modified and changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. In addition, the drawings of the present invention are only simple schematic illustrations and are not depicted according to actual sizes. It is stated in advance. The following embodiments will further explain the relevant technical contents of the present invention in detail, but the disclosed contents are not intended to limit the scope of protection of the present invention.
[0040] Embodiment 1.
[0041] This embodiment provides a piano keystroke force detection system, combined with Figure 1 , including an audio acquisition module, an audio segmentation module, a strength detection module and a standard correction module;
[0042] The audio acquisition module is used to collect audio information generated when keystrokes are made, the audio segmentation module is used to segment and extract audio information of each keystroke from the audio information, the force detection module is used to analyze the independent keystroke audio information to measure the corresponding keystroke force, and the standard correction module is used to provide a standard keystroke force and correct the parameters in the force detection module;
[0043] The audio acquisition module includes a microphone acquisition unit and an audio preprocessing unit, wherein the microphone acquisition unit is used to capture audio information at a fixed position, and the audio preprocessing unit is used to perform filtering and denoising on the captured audio information;
[0044] The audio segmentation module includes an event detection unit and a data segmentation unit, wherein the event detection unit is used to identify the start and end of a keystroke event, and the data segmentation unit segments the audio information according to the detected event;
[0045] The force detection module includes a feature extraction unit and a force analysis unit, wherein the feature extraction unit is used to extract feature data of the audio information of each keystroke event, and the force analysis unit calculates the keystroke force of each keystroke event based on the feature data;
[0046] The standard correction module includes a standard striking unit and a correction adjustment unit, wherein the standard striking unit is used to provide a fixed force to strike the piano keys, and the correction adjustment unit is used to perform correction processing on the parameters in the force analysis unit;
[0047] The data segmentation unit includes an event information register, an audio interception processor and an audio purification processor, wherein the event information register is used to store the segmentation information of each keystroke event, the audio interception processor is used to segment the original audio information, and the audio purification processor is used to purify the segmented audio information to obtain independent audio information;
[0048] The audio purification processor calculates the primary independent audio information S1(t) according to the following formula:
[0049]
[0050] Among them, S'(t) is the intercepted original audio information, N is the harmonic order considered, M is the number of independent pre-audio considered, λ i represents the attenuation coefficient of the previous i-th keystroke event, t i Indicates the time interval between the previous i-th keystroke event and the current keystroke event, A i,n represents the initial amplitude of the nth harmonic of the previous i-th keystroke event, f i,n represents the frequency of the nth harmonic of the previous i-th keystroke event;
[0051] The audio purification processor calculates the attenuation coefficient λ according to the primary independent audio information and saves it to the event information register:
[0052]
[0053] Where A0 is the initial amplitude of the fundamental wave, A′ is the amplitude of the fundamental wave sampling point, and Δt is the time interval between the sampling point and the initial amplitude time point;
[0054] The audio purification processor calculates the independent audio information S(t) according to the following formula:
[0055]
[0056] Among them, λ + is the attenuation coefficient of the next keystroke event, t + Indicates the time interval between the next keystroke event and the current keystroke event, A n+ represents the initial amplitude of the nth-order harmonic of the next keystroke event, f n+ represents the frequency of the nth-order harmonic of the next keystroke event, and T is the duration of the current keystroke event;
[0057] The feature extraction unit includes a key recognition processor and an amplitude analysis processor, wherein the key recognition processor is used to identify the key type, and the amplitude analysis processor is used to analyze and process the amplitude information in the independent audio information;
[0058] The amplitude analysis processor obtains the amplitude information in the independent audio information and calculates the amplitude correlation value P according to the following formula:
[0059]
[0060] Among them, A1(i) represents the i-th amplitude value of the fundamental wave, A n (i) represents the i-th amplitude value of the n-th order harmonic, and L is the number of samples of the fundamental wave;
[0061] The force analysis unit includes a parameter register and a force calculation processor, wherein the parameter register is used to store the force calculation parameters of each key type, and the force calculation processor is used to calculate the keystroke force value;
[0062] The force calculation processor outputs the keystroke force value F according to the following formula:
[0063] F=(α·P c +β)·A 1max ;
[0064] Among them, α and β are strength calculation parameters, c is the correction parameter, A 1max is the maximum amplitude of the fundamental wave.
[0065] Embodiment 2.
[0066] This embodiment includes all the contents of the first embodiment, and provides a piano keystroke force detection system, including an audio acquisition module, an audio segmentation module, a force detection module and a standard correction module;
[0067] The audio acquisition module is used to collect audio information generated when keystrokes are made, the audio segmentation module is used to segment and extract audio information of each keystroke from the audio information, the force detection module is used to analyze the independent keystroke audio information to measure the corresponding keystroke force, and the standard correction module is used to provide a standard keystroke force and correct the parameters in the force detection module;
[0068] The audio acquisition module includes a microphone acquisition unit and an audio preprocessing unit, wherein the microphone acquisition unit is used to capture audio information at a fixed position, and the audio preprocessing unit is used to perform filtering and denoising on the captured audio information;
[0069] Combination Figure 2 , the audio segmentation module includes an event detection unit and a data segmentation unit, the event detection unit is used to identify the start and end of a keystroke event, and the data segmentation unit segments the audio information according to the detected event;
[0070] Combination Figure 3 The force detection module includes a feature extraction unit and a force analysis unit, wherein the feature extraction unit is used to extract feature data of the audio information of each keystroke event, and the force analysis unit calculates the keystroke force of each keystroke event based on the feature data;
[0071] The standard correction module includes a standard striking unit and a correction adjustment unit, wherein the standard striking unit is used to provide a fixed force to strike the piano keys, and the correction adjustment unit is used to perform correction processing on the parameters in the force analysis unit;
[0072] The audio preprocessing unit includes a preamplifier processor, a filter, a digital signal conversion processor and a digital filter processor, wherein the preamplifier processor is used to amplify the collected analog signal, the filter is used to filter the analog signal, the digital signal conversion processor is used to convert the analog signal into a digital signal, and the digital filter processor is used to filter the digital signal;
[0073] Combination Figure 4 , the event detection unit includes an energy analysis processor and a harmonic analysis processor, the energy analysis processor is used to detect the start of a keystroke event, and the harmonic analysis processor is used to detect the end of a keystroke event;
[0074] The process of detecting keystroke events by the energy analysis processor comprises the following steps:
[0075] S1, dividing the audio information into multiple short time periods;
[0076] S2, calculating the average amplitude A of the audio information in each short period of time;
[0077] S3, calculate the relative energy in each short period of time;
[0078] E=μ·A 2 ;
[0079] Among them, μ is the relative coefficient;
[0080] S4, calculating the energy difference between two adjacent short time periods, and when the energy difference is greater than the mutation threshold, determining that a keystroke event is detected, and marking the start time of the next short time period as the start of the keystroke event;
[0081] The process of detecting keystroke events by the harmonic analysis processor comprises the following steps:
[0082] S21, obtaining the start time of a keystroke event and the audio information from that time from the energy analysis processor;
[0083] S22, calculating the fundamental wave of the audio information and the corresponding harmonic frequency;
[0084] S23, extract the corresponding harmonics from the audio information, and obtain the harmonic amplitude {xA i};
[0085] S24, detect each harmonic amplitude in sequence, and when the harmonic amplitude satisfies the following formula, xA i The corresponding time point is marked as the end of the keystroke time:
[0086] xA i <ke·xAmax;
[0087] Among them, xAmax is {xA i}, ke is the end coefficient;
[0088] Combination Figure 5 The data segmentation unit includes an event information register, an audio interception processor and an audio purification processor, wherein the event information register is used to store the segmentation information of each keystroke event, the audio interception processor is used to segment the original audio information, and the audio purification processor is used to purify the segmented audio information to obtain independent audio information;
[0089] The segmentation information of the keystroke event includes time information, decay information and independent audio information;
[0090] The audio interception processor segments the original audio according to the time information in the segmentation information;
[0091] The audio purification processor calculates the primary independent audio information S1(t) according to the following formula:
[0092]
[0093] Among them, S'(t) is the intercepted original audio information, N is the harmonic order considered, M is the number of independent pre-audio considered, λ i represents the attenuation coefficient of the previous i-th keystroke event, t i Indicates the time interval between the previous i-th keystroke event and the current keystroke event, A i,n represents the initial amplitude of the nth harmonic of the previous i-th keystroke event, f i,n represents the frequency of the nth harmonic of the previous i-th keystroke event;
[0094] In particular, when n is 1, it refers to the fundamental wave;
[0095] The audio purification processor calculates the attenuation coefficient λ according to the primary independent audio information and saves it to the event information register:
[0096]
[0097] Where A0 is the initial amplitude of the fundamental wave, A′ is the amplitude of the fundamental wave sampling point, and Δt is the time interval between the sampling point and the initial amplitude time point;
[0098] The audio purification processor calculates the independent audio information S(t) according to the following formula:
[0099]
[0100] Among them, λ + is the attenuation coefficient of the next keystroke event, t + Indicates the time interval between the next keystroke event and the current keystroke event, A n+ represents the initial amplitude of the nth-order harmonic of the next keystroke event, f n+ represents the frequency of the nth-order harmonic of the next keystroke event, and T is the duration of the current keystroke event;
[0101] The audio purification processor saves the independent audio information into the event information register;
[0102] The feature extraction unit includes a key recognition processor and an amplitude analysis processor, wherein the key recognition processor is used to recognize the key type, and the amplitude analysis processor is used to analyze and process the amplitude information in the independent audio information;
[0103] The key recognition processor has built-in fundamental frequency intervals of all key types, and sets corresponding type tags according to the intervals where the fundamental frequency in the independent audio information is located;
[0104] The amplitude analysis processor obtains the amplitude information in the independent audio information and calculates the amplitude correlation value P according to the following formula:
[0105]
[0106] Among them, A1(i) represents the i-th amplitude value of the fundamental wave, A n (i) represents the i-th amplitude value of the n-th order harmonic, and L is the number of samples of the fundamental wave;
[0107] The force analysis unit includes a parameter register and a force calculation processor, wherein the parameter register is used to store the force calculation parameters of each key type, and the force calculation processor is used to calculate the keystroke force value;
[0108] The force calculation processor outputs the keystroke force value F according to the following formula:
[0109] F=(α·P c +β)·A 1max ;
[0110] Among them, α and β are strength calculation parameters, c is the correction parameter, A 1max is the maximum amplitude of the fundamental wave;
[0111] The correction adjustment unit includes an adjustment calculation processor and a parameter reset processor, wherein the adjustment calculation processor is used to calculate the adjustment value of the correction parameter, and the parameter reset processor is used to reset the correction parameter and send it to the force analysis unit;
[0112] The adjustment calculation processor calculates the adjustment value Δc according to the following formula:
[0113]
[0114] Among them, F0 is the striking force of the standard striking unit;
[0115] The i and n appearing in the above text are ordinal numbers used to indicate sequence numbers.
[0116] The contents disclosed above are only preferred feasible embodiments of the present invention, and do not limit the protection scope of the present invention. Therefore, all equivalent technical changes made using the contents of the present invention specification and drawings are included in the protection scope of the present invention. In addition, the elements therein can be updated as technology develops.
Claims
1. A piano keystroke force detection system, characterized in that: It includes audio acquisition module, audio segmentation module, strength detection module and standard correction module; The audio acquisition module is used to collect audio information generated when keystrokes are made, the audio segmentation module is used to segment and extract audio information of each keystroke from the audio information, the force detection module is used to analyze the independent keystroke audio information to measure the corresponding keystroke force, and the standard correction module is used to provide a standard keystroke force and correct the parameters in the force detection module; The audio acquisition module includes a microphone acquisition unit and an audio preprocessing unit, wherein the microphone acquisition unit is used to capture audio information at a fixed position, and the audio preprocessing unit is used to perform filtering and denoising on the captured audio information; The audio segmentation module includes an event detection unit and a data segmentation unit, wherein the event detection unit is used to identify the start and end of a keystroke event, and the data segmentation unit segments the audio information according to the detected event; The force detection module includes a feature extraction unit and a force analysis unit, wherein the feature extraction unit is used to extract feature data of the audio information of each keystroke event, and the force analysis unit calculates the keystroke force of each keystroke event based on the feature data; The standard correction module includes a standard striking unit and a correction adjustment unit. The standard striking unit is used to provide a fixed force to strike the piano keys, and the correction adjustment unit is used to perform correction processing on the parameters in the force analysis unit.
2. A piano keystroke force detection system as claimed in claim 1, characterized in that: The data segmentation unit includes an event information register, an audio interception processor and an audio purification processor. The event information register is used to store the segmentation information of each keystroke event, the audio interception processor is used to segment the original audio information, and the audio purification processor is used to purify the segmented audio information to obtain independent audio information.
3. A piano keystroke force detection system as claimed in claim 2, characterized in that: The audio purification processor calculates the primary independent audio information S1(t) according to the following formula: Among them, S'(t) is the intercepted original audio information, N is the harmonic order considered, M is the number of independent pre-audio considered, λ i represents the attenuation coefficient of the previous i-th keystroke event, t i Indicates the time interval between the previous i-th keystroke event and the current keystroke event, A i,n represents the initial amplitude of the nth harmonic of the previous i-th keystroke event, f i,n represents the frequency of the nth harmonic of the previous i-th keystroke event, and t is the time; The audio purification processor calculates the attenuation coefficient λ according to the primary independent audio information and saves it to the event information register: Where A0 is the initial amplitude of the fundamental wave, A′ is the amplitude of the fundamental wave sampling point, and Δt is the time interval between the sampling point and the initial amplitude time point; The audio purification processor calculates the independent audio information S(t) according to the following formula: Among them, λ + is the attenuation coefficient of the next keystroke event, t + Indicates the time interval between the next keystroke event and the current keystroke event, A n+ represents the initial amplitude of the nth harmonic of the next keystroke event, f n+ It represents the frequency of the nth-order harmonic of the next keystroke event, and T is the duration of the current keystroke event.
4. A piano keystroke force detection system as claimed in claim 3, characterized in that: The feature extraction unit includes a key recognition processor and an amplitude analysis processor, wherein the key recognition processor is used to identify the key type, and the amplitude analysis processor is used to analyze and process the amplitude information in the independent audio information; The amplitude analysis processor obtains the amplitude information in the independent audio information and calculates the amplitude correlation value P according to the following formula: Among them, A1(i) represents the i-th amplitude value of the fundamental wave, A n (i) represents the i-th amplitude value of the n-th order harmonic, and L is the number of samples of the fundamental wave.
5. A piano keystroke force detection system as claimed in claim 4, characterized in that: The force analysis unit includes a parameter register and a force calculation processor, wherein the parameter register is used to store the force calculation parameters of each key type, and the force calculation processor is used to calculate the keystroke force value; The force calculation processor outputs the keystroke force value F according to the following formula: F=(α·P c +b)·A 1max ; Among them, α and β are strength calculation parameters, c is the correction parameter, A 1max is the maximum amplitude of the fundamental wave.
Citation Information
Patent Citations
A piano dynamics acquisition calibration system and calibration method
CN110491357B