1. Technical Field
The present disclosure relates to testing device and method, and more particularly to a testing device and a non transitory storage medium capable of testing timbre of a disc player, and a method for testing timbre of a disc player.
2. Description of Related Art
Disc player need to be tested before leaving the factory, and conventional method for testing timbre of the disc player includes the following steps: inserting a disc in the disc player; watching the left and right sound tract signal via an oscilloscope; and then, determining whether the signal output by the oscilloscope is a sine wave. However, this method is expensive due to the cost of the oscilloscope.
Therefore, there is room for improvement in the art.
Many aspects of the embodiments can be better understood with reference to the following drawings. The components in the drawings are not necessarily drawn to scale, the emphasis instead being placed upon clearly illustrating the principles of the embodiments. Moreover, in the drawings, like reference numerals designate corresponding parts throughout the several views.
The disclosure is illustrated by way of example and not by way of limitation in the figures of the accompanying drawings in which like references indicate similar elements. It should be noted that references to “an” or “one” embodiment in this disclosure are not necessarily to the same embodiment, and such references mean “at least one.”
In general, the word “module,” as used herein, refers to logic embodied in hardware or firmware, or to a collection of software instructions, written in a programming language, for example, Java, C, or assembly. One or more software instructions in the modules may be embedded in firmware, such as in an EPROM. Modules may comprise connected logic units, such as gates and flip-flops, and may comprise programmable units, such as programmable gate arrays or processors. The modules described herein may be implemented as either software and/or hardware modules and may be stored in any type of computer-readable medium or other computer storage system. Embodiments of the present disclosure will be described with reference to the drawings.
The storing module 11 stores a number of timbre parameters. The timbre parameters include at least a frequency parameter, a volume parameter, and an SNR(signal-to-noise ratio) parameter. Each timbre parameter has a standard value. In this embodiment, each timbre parameter includes a first standard value corresponding to the left sound track and a second standard value corresponding to the right sound track. The first and second standard values may be the same, or different from each other. Each frequency parameter, each volume parameter and each SNR parameter all further include a number of values corresponding to different sound track respectively, such as left sound track and right sound track.
The receiving module 12 receives audio signals from the disc player, wherein the audio signals may be output from left sound track and right sound track of the disc player.
The obtaining module 13 analyses the audio signals to obtain a test value of each timbre parameter. In detail, the obtaining module 13 generates at least one audio file according to the audio signals. The audio file in this embodiment may be a WAVE file. The obtaining module 13 transforms the audio file using Fast Fourier Transform (time-frequency transformation) to obtain the test value of each timbre parameter for evaluating the timbre of the disc player.
The determining module 14 determines whether the timbre of the disc player is qualified based on the test value of each timbre parameter. When the timbre of the disc player is qualified, the controlling module 16 controls the display module 15 to display a message for informing the testing personnel that the disc player is qualified. When the timbre of the disc player is unqualified, the controlling module 16 controls the display module 15 to display a message for informing the testing personnel that the disc player is unqualified.
In this embodiment, when a difference value between the test value of each timbre parameter and the corresponding standard value falls within a predetermined range, the determining module 14 determines that the timbre of the disc player is qualified. When a difference value between the test value of each timbre parameter and the corresponding standard value does not fall within a predetermined range, the determining module 14 determines that the timbre of the disc player is unqualified. Each difference value c in this embodiment may be calculated by an equation: c=|a−b|/b×100%, wherein “a” represents the test value of each timbre parameter, and “b” represents each standard value of each timbre parameter.
In other embodiments, when the test value of each timbre parameter is less than or equal to the corresponding standard value, the determining module 14 determines the timbre of the disc player is qualified. When the test value of each timbre parameter is greater than the corresponding standard value, the determining module 14 determines the timbre of the disc player is unqualified.
The controlling module 16 controls the display module 15 to display the test value for informing the state of the disc player. The display module 15 may be a display screen integrated within the testing device 10, or may be a display electrically connected to the testing device 10.
In step S201, the storing module 11 stores a number of timbre parameters. The timbre parameters include at least a frequency parameter, a volume parameter, and a signal-to-noise ratio (SNR) parameter. In this embodiment, each timbre parameter includes a first standard value corresponding to the left sound track and a second standard value corresponding to the right sound track. The first and second standard values may be the same, or different from each other. Each frequency parameter, each volume parameter and each SNR parameter all further include different sound tracks, such as left sound track and right sound track.
In step S202, the receiving module 12 receives audio signals from the disc player, wherein the audio signals may be output from left sound track and right sound track of the disc player.
In step S203, the obtaining module 13 analyses the audio signals to obtain a test value of each timbre parameter. In detail, the obtaining module 13 generates at least one audio file according to the audio signals. The audio file in this embodiment may be a WAVE file. The obtaining module 13 transforms the audio file using Fast Fourier Transform (time-frequency transformation), and obtains the test value of each timbre parameter for evaluating the timbre of the disc player.
In step S204, the determining module 14 determines whether the timbre of the disc player is qualified based on the test value of each timbre parameter. When the timbre of the disc player is qualified, step S205 is implemented. When the timbre of the disc player is unqualified, step S206 is implemented.
In this embodiment, when a difference value between each test value of each timbre parameter and the corresponding standard value falls within a predetermined range, the determining module determines that the timbre of the disc player is qualified. When a difference value between each test value of each timbre parameter and the corresponding standard value does not fall within a predetermined range, the determining module 14 determines that the timbre of the disc player is unqualified. Each difference value c in this embodiment may be express by the equation: c=|a−b|/b×100%. In the equation, the “a” represents each test value of each timbre parameter, the “b” represents each standard value of each timbre parameter.
In other embodiments, when each test value of each timbre parameter is less than or equal to the corresponding standard value, the determining module 14 determines the timbre of the disc player is qualified. When each test value of each timbre parameter is more than the corresponding standard value, the determining module 14 determines the timbre of the disc player is unqualified.
In step S205, the controlling module 12 controls the display module 15 to display a message for informing the testing personnel that the disc player is qualified and the test value of each timbre parameter.
In step S206, the controlling module 12 controls the display module 15 to display a message for informing the testing personnel that the disc player is unqualified and the test value of each timbre parameter.
Although information as to, and advantages of, the present embodiments have been set forth in the foregoing description, together with details of the structures and functions of the present embodiments, the disclosure is illustrative only; and changes may be made in detail, especially in the matters of shape, size, and arrangement of parts within the principles of the present embodiments to the full extent indicated by the broad general meaning of the terms in which the appended claims are expressed.
Number | Date | Country | Kind |
---|---|---|---|
2012103120379 | Aug 2012 | CN | national |