-
1Introduction
As RTL8722DM MINI has a built-in microphone on the board, there is no need for any external microphone. Copy a sample wav file into the MicroSD card for demo. (In this example, the sample name is “Test_Audio_48khz_16bit_stereo.wav”. ) Then insert the MicroSD card into the adapter at the back of the board.
-
2​Example 01 PlaybackWavFile
Open the example, “Files” -> “Examples” -> “AmebaAudioCodec” -> “PlaybackWavFile”.
Upload the code and press the reset button on Ameba once the upload is finished.
Insert earphones/speakers into the onboard jack for playing the sample sound. -
3Example 02 RecordWavFile
Open the example, “Files” -> “Examples” -> “AmebaAudioCodec” -> “RecordWavFile”.
Define a GPIO/button(Input high to active) for “RECORDBTN”. Define the “filename[]” for the name of the storge wav file. In this example, the name is “Test_Recording_48khz_16bit_mono.wav”.
Upload the code and press the reset button on Ameba once the upload is finished.
Input high to “RECORDBTN”, then record voice by the onboard mic. When the input is low the record stops. The recorded voice will be stored in “Test_Recording_48khz_16bit_mono.wav” located on a MicroSD card. -
4Example 03 RecordPlaybackWav
Open the example, “Files” -> “Examples” -> “AmebaAudioCodec” -> “RecordPlaybackWav”.
This example is a combination of Example01 and Example02. You can record by Example02 then play it by jack as the method of Example01.
Define a GPIO/button(Input high to active) for “RECORDBTN”. Define the “filename[]” for name of the storge wav file. In this example, the name is “Test_Recording_48khz_16bit_mono.wav”.
Upload the code and press the reset button on Ameba once the upload is finished.
Input high to “RECORDBTN”, then record voice by the onboard mic. When the input is low the record stops. The recorded voice will be stored in “Test_Recording_48khz_16bit_mono.wav” located on a MicroSD card.
Insert earphones/speakers into the onboard jack for playing the sample sound.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.