% Example: Load an audio file (.WAV format), then 
% export to a .CSV file for use by the Agilent 33120A
% Arbitrary Waveform Generator.

% Load the audio file
[x fs bits] = wavread('curly.wav');

% Listen to the signal
sound(x,fs)

% Save to .CSV file
save audio_csv.csv -ascii x

% Calculate the 33120A frequency setting
fs/length(x)


