Patent ID: 8751030

Claim:
An operating method of an audio player, the audio player comprising a storage unit that stores a plurality of audio files, an input device, a detection circuit, a processor and an output device, the method comprising: building a plurality of music type modes to respectively correspond to different environments and distributing one or more of the audio files to each of the music type modes via the input device; switching to an automatic switching mode of the audio player via the input device; sampling noise of a local environment of the audio player and generating a detection signal by the detection circuit according to the sampled noise, the detection signal representing environmental noise of one of the different environments, the detection signal comprising a magnitude and a variation rate, which cooperatively represent a waveform of the detection signal; storing a first reference value and a second reference value in the storage unit, the first and second reference values cooperatively representing a reference waveform; selecting one of the music type modes according to the detection signal using the processor to analyze the detection signal to obtain a first and a second detection values respectively corresponding to the magnitude and the variation rate, and comparing the first and second detection values with the first and second reference values, respectively; in the event that the first detection value is less than the first reference value and the second detection value is less than the second reference value, a first music type mode corresponding to a very quiet environment is selected; in the event that the first detection value is greater than the first reference value and the second detection value is less than the second reference value, a second music type mode corresponding to a moderately quiet environment is selected; in the event that the first detection value is less than the first reference value and the second detection value is greater than the second reference value, a third music type mode corresponding to a moderately noisy environment is selected; and in the event that the first detection value is greater than the first reference value and the second detection value is greater than the second reference value, a fourth music type mode corresponding to a very noisy environment is selected; determining whether the audio files comprise one or more audio files having identities corresponding to the selected music type mode, and finding from the storage unit one or more of the audio files distributed to the selected music type mode by the processor if the audio files comprise one or more audio files having identities corresponding to the selected music type mode; and outputting data of the audio files which are distributed to the selected music type mode by the output device.