Nice little useful program for training your morse skills:)
I updated the code a little, if anyone is interested... (feel free to add it to the original):
To have smaller spaces between letters, change line 33 from lsp = wav(6176:23022); to lsp = wav(6176:16022);
To add danish letters æ,ø,å (can be done for any additional signs, and I probably will later), add
AE = [Dit;ssp;Dah;ssp;Dit;ssp;Dah]; % danish Æ .-.-
OE = [Dah;ssp;Dah;ssp;Dah;ssp;Dit]; % danish Ø ---.
AA = [Dit;ssp;Dah;ssp;Dah;ssp;Dit;ssp;Dah]; % danish Å .--.-
and change
vars ={'period','comma','question','slash_'}; to
vars ={'period','comma','question','slash_','AE','OE','AA'};
and change
elseif ismember(text(i),'.,?/')
x = findstr(text(i),'.,?/');
to
elseif ismember(text(i),'.,?/ÆØÅ')
x = findstr(text(i),'.,?/ÆØÅ');
to modify the speed, a resampling is added in the last part (just after the loop):
morsecode=resample(morsecode,Fs,15000); % resample to Fs/15000
if the numberused is higher than Fs, the speed will be higher, if it is lower, the speed will be lower...