# Morse Code Practice System1

Posted by Sean de Wolski,

Sean's pick this week is Morse Code Practice System by James Willmann.

Howdy! My name is Sean and I am an Application Support Engineer with Mathworks. You may also recognize me as a dog on MATLAB Answers. I am on the MATLAB/MATH Technical Support team and I'm working with Jiro to hopefully become an Application Engineer one day.

### S.O.S.

I really like programming in MATLAB. But even more than that: I love boating!

S.O.S.: dit dit dit | daw daw daw | dit dit dit

This is the international distress signal that was used on the sea until very recently. It is also the only Morse Code I know. Fortunately, I've never had to use it, though we did come close once when we forgot to put in the bilge plug.

In an effort to learn more Morse Code, I turned to the FEX with the hope that someone else had already done this in MATLAB. Sure enough, someone had!

### I LOVE MATLAB!

There are two ways for you to use this App to transmit your message in Morse Code:

• Type it live.
• Have it read from a text file.

You can also adjust the word and code speed and frequency. The letters appear as they are being transmitted so you know what letter you are hearing at any one time.

Let's see it in action:

I can only imagine how jealous someone, who had to use a Telegraph day in and day out 100 years ago, would be of this utility.

### Learning Morse and MATLAB Code

If you would like to learn more Morse Code this is a great App with which to practice. It is also a good way to see some high quality MATLAB programming. The programmatic GUI is well organized and commented making it easy to follow. Specifically, it shows how to receive and manage keyboard input as well as how to use a TIMER to control events.

If you are interested, Wikipedia has plenty of information on Morse Code. Or you could just look at the Code Table and superb documentation that come with this App:

### Suggestions for the Author

James has done an excellent job with this program, but I have two suggestions to make it even better:

1. As I mentioned in the feedback last July: a visual indicator would help those of us who have no experience learn even more quickly.
2. You may notice the warnings with regard to WAVPLAY. WAVPLAY is on its way to being deprecated and is being replaced with AUDIOPLAYER. There are many reasons to move to AUDIOPLAYER including its multiplatform support and built-in options for PlayBlocking, starting, stopping, etc. To temporarily turn off the WAVPLAY warning, you can run:
warning off MATLAB:audiovideo:wavplay:functionToBeRemoved

Do you know Morse Code? Or have you ever had an experience where you needed to transmit S.O.S.?