Greetings. I've recently completed my first project using a Value Line MSP430G2211 chip that came with my LaunchPad. It is a Morse code iambic keyer.
Background. To send high speed Morse code, amateur radio operators use a set of "paddles" and an electronic keyer. Morse paddles are really just two switches set up for use between the thumb and forefinger and are closed by squeezing. When the left paddle is closed, the electronic keyer sends a series of "dits." When the right paddle is closed a series of "dahs" is sent. When both are closed together, the keyer sends alternating dits and dahs, dit-dah-dit-dah-dit-dah-... (or the dah comes first,). Dits are one "element" long followed by an element of silence. Dahs are three elements long, followed by one element of silence. When they alternate the sound resembles iambic pentameter from poetry, hence the name. By "send" I mean that the keyer's output closes a circuit which causes a transmitter to send a radio frequency carrier. Morse code just turns this carrier on and off in certain patterns (but with suitable smoothness for changes in the amplitude to keep bandwidth small).
Speed in Morse code is measured in Words per Minute (WPM). The standard word is PARIS and the space following it. Skipping even more boring details, the length of one element in milliseconds is given by the equation Element length (ms) = 1200 / WPM.
I have built several simple keyers (no fancy features, just sending speed change capability) using PIC or Atmel chips, so it was natural for me to try a keyer with the MSP430G2211 that came with my LaunchPad. I did this after reading the first few chapters of John Davies' book. What was really new for me (other than learning another assembly language) was the low power capabilities of the MSP430 line. I was able not only to put the MCU to sleep between sending sessions, but by using a Timer A interrupt for up mode I could induce sleep while sending the dits and dahs, waking only for transitions. The consequence was that current consumption was 0.7 microamps in idle and 84 microamps when a single paddle was closed (and about double that when both are closed in iambic mode). With one hour a day of Morse code contacts on the air, I expect my CR2032 button cell powering the unit to last about 18 years. I am impressed.
Basic design decisions: 32768 Hz clock crystal for ACLK for accurate Morse timing, DCO calibrated at 1 MHz for normal operations, Timer A from ACLK/1. Used LPM3 so ACLK remains active during sleep. (The oscillator does not awake quickly enough if I go to LPM4.) Uses pin change ISR for waking from idle periods and uses Timer A interrupt to wake after sending (or not sending) for an element of time.
The basic algorithm is to check for a paddle closure and set a flag accordingly. (The program calls the flag a buffer, but this is a misnomer.) Then if the the corresponding flag is set a dit or dah is sent and the paddles are checked again. Using the flags eliminates debounce and multiple closure problems.
If you are interested in this project or would consider constructive criticism of my use of MSP430 features, you can find a zip file under FILES in my personal profile which contains the assembly code, a schematic, and a pdf file with a bit more discussion.
Best regards to all.
PS. This is obviously a hobbyist project. No insult is intended to you professional engineers out there on this forum. It just seems to me that TI is trying to capture some of the microcontroller hobbyist and student market with the LaunchPad, and this is a consequence of that. My next project is a little development board which fits on top of the LaunchPad and contains a 20-pin ZIF socket, a socket for a crystal or ceramic resonator, and several pushbuttons and LEDs connected to headers.