How to record audio with MATLAB?
Record Microphone Input
You must first connect a microphone to your system. Create an audiorecorder object with default properties named recObj for recording audio input. audiorecorder creates an 8000 Hz, 8-bit, 1-channel audiorecorder object. Record your voice for 5 seconds.
How do I run a WAV file in MATLAB?
Write an Audio File
Write a WAVE ( . wav ) file in the current folder. Read the data back into MATLAB using audioread . [y,Fs] = audioread(filename);
How to use Wavread in MATLAB?
To activate the Import Wizard, select Import Data from the File menu. wavread supports multichannel data, with up to 32 bits per sample, and supports reading 24- and 32-bit . wav files. y = wavread('filename') loads a WAVE file specified by the string filename , returning the sampled data in y .