Chorder, Part III

This post is part of a series of notes and exercises for a summer camp on making musical instruments with Arduino and Pure Data.

Currently our chorder writes messages like this to the serial port:


This looks like a I chord in the C major scale. The 0 means it should stop playing.

We now write a Pure Data patch that interprets these messages and generates the appropriate MIDI commands.


Let’s start by making an abstraction that plays or stops a particular MIDI note. Call it note2. It will behave a lot like note from our pentatouch. Create it in the following way:

  • Add an inlet midi_number for the note’s MIDI number.
  • Feed the MIDI number into the leftmost inlet of a noteout object.
  • Add an inlet state for the note’s state, which will be 0 or 1.
  • Feed the state into a select object that chooses between 0 and 1.
  • Feed the 0 branch into a float 0 object, which will serve as the stopping velocity.
  • Feed the 1 branch into a float 100 object, which will serve as the playing velocity.
  • Feed both velocities into the middle inlet of the noteout object.

Save your abstraction in note2.pd.


With note2 in place, creating the main patch will be much simpler. Follow these steps:

  • Add the devices, open, and close messages as you have done previously.
  • Add a comport 9600 object and wire the messages to it as you have done previously.
  • Feed the outlet of comport to a repack 4 object. Each message has four numbers in it.
  • Feed the outlet of repack into an unpack float float float float object. This separates the message into four individual numbers.
  • Add a note2 object.
  • Feed the first number of the Arduino message to the left inlet of the note2 object.
  • Similarly feed the second number into the left inlet of the note2 object. And the third.
  • Feed the state (the fourth outlet) into the right inlet of the note2 object.

Test your instrument. Touching the clips should produce I, ii, iii, VI, V, vi, and vii chords. Then find some fruit and vegetables to create your inputs.


After you get your chorder working, answer the following questions on a piece of scratch paper.

  1. Investigate some chord progressions in the major scale commonly found in popular music. Identify one whose sound pleases you.
  2. Experiment with your own chord progressions. What’s one you like? Compose a short, repeating progression and be prepared to play it for the group.


Leave a Reply

Your email address will not be published. Required fields are marked *