MSP430 touchscreen piano

msp430-touchscreen-piano

[Rohit Gupta] wrote in to share this touchscreen piano project he built around the TI Launchpad. It provided a way for him to explore using a resistive digitizer found on a lot of mobile devices. These are simply stuck to the top of LCD screens and replacements are inexpensive, but salvaging one from old hardware is an option as well.

The first thing he did was to test the four outputs of the digitizer with his multimeter. Logging the changing resistance will help make sure you’re reading the correct wires and are able to zero in the settings before you start coding. [Rohit] uses the ADC on the MSP430 chip to read from the screen. He went with the algorithm from one of TI’s app notes to convert the readings in to X and Y coordinates.

He separated the screen into seven columns, each generating a different tone. Touching higher or lower on that column will alter the pitch of the note produced. You can hear an example of this in the demo after the jump.

Comments

  1. J says:

    Nothing too exiting to be honest.

  2. echodelta says:

    I was expecting octaves on the Y axis. I heard once a raga scale with 11 notes in the octave.

  3. fartface says:

    This can be converted into a KAOSS pad quite easily.

    • Greenaum says:

      You’d need a shitload more RAM, CPU power, ROM and software. And some twiddly knobs, about half a dozen. And quite a few buttons. But mostly the shitload of software and the computer to run it on. Oh, and a grid of LEDs.

      Are you sure you weren’t thinking of a Stylophone?

  4. TRON says:

    Speakers are inductive loads. Please add a flyback diode to the speaker to prevent damaging the MSP430 on the launchpad.

    • Greenaum says:

      How would that work!? You’d destroy half the signal! And you’d be shorting the output amp. Speakers don’t switch on and off sharply like relays. They’re also usually AC-coupled, or bridge driven. You don’t usually put flyback diodes over inductors, either.

      • TRON says:

        From what I can tell here, he is driving the speaker using a square wave. Voltages should not go negative with respect to your ground plane then. Speakers have a really low resistance. The voltage accross an inductor is given by V = L di/dt. The moment your current drops to 0, you will see a negative spike buildup in the voltage. Unless his speaker ther has extra circuitry, he will be feeding that straight back into the MSP430. It’s a bad idea already driving the speaker directly from the ’430 and not an op-amp/transistor. It’s even worse to feed it such a large voltage spike.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s