ChordPro for Yamaha accompaniment

Time to take the wrapping paper off my current development project.

It starts with ChordPro. ChordPro Format is perhaps the most popular notation for rock, pop, soul and folk tunes. A ChordPro format song contains lyrics and chords, usually formatted for easy display and reading. Strummers and plinkers everywhere use ChordPro songs as lead sheets.

It ends with Yamaha Genos, Tyros and PSR accompaniment. Genos — and other recent Yamaha arrangers — play MIDI files containing chords and lyrics. Genos displays either a running score or lyrics (plus chords) during playback.

What is missing is the bridge between ChordPro and Genos. My current project is the bridge. It translates an extended ChordPro file to a MIDI file which is compatible with Genos and other mid- to high-end Yamaha arranger keyboards. So far, I have a prototype up-and-running.

I emphasized the word “extended” because ChordPro format by itself is not sufficient for playback. The format does not have a precise notion of time. ChordPro relies on the musician to interpret the song on the fly. It assumes that the musician has heard the song before and knows when to change chords. As usual with computer stuff, playback needs more precise semantics. That’s where the extensions come into play.

Since there are a gazillion ChordPro songs on the Interwebs, I wanted to play back ChordPro files with as few modifications as possible. Thus, the first rule is “Each notated chord is held for one measure.” Of course, many songs change chords within a measure, too. (Even “Louie, Louie”!) Enter the first extension. A notated chord may have an optional beat count which specifies the number of beats to hold the chord, or more precisely, the number of time divisions (quarter notes or eigth notes) to hold the chord.

As I discovered during testing, existing ChordPro song files have a fair number of warts. Sometime the chord progressions are whack. The files often have random playing directions which ChordPro happily snarfs up as lyric text. ChordPro is very forgiving as it is primarily a formatting representation and tool. The initial goal — playing a ChordPro song with just a few additions — is unrealistic; expect to do some clean-ups.

Plain, unchanging accompaniment is pretty boring after a short while. Therefore, I added annotations for section changes, fills and breaks. Certain ChordPro directives are optional, but strongly recommended: key, tempo, and time signature. Tempo and time signature obviously guide playback speed and the interpretation of chord hold time. The key signature will set the arranger’s score display to the appropriate key.

Stylecode is an extension. It is a decimal number that selects the arranger accompaniment style, .e.g., 60sVintageRock, Oldies R&R, etc. A style name would be more convenient, but then I would need to develop a style name to code database for each arranger. Forget it; keep it simple. Besides, the PSR Tutorial site has such spreadsheets — just look up the style code yourself.

Start_accomp and stop_accomp are extensions, too. Start_accomp should (must) appear after all the basic playback settings are made. When the MIDI file is played back, the arranger will start or stop the accompaniment engine as directed. Start_accomp begins playback from the second measure; the first measure is reserved for set-up.

The translation program does not implement every and all ChordPro directive. It ignores formatting related directives and it doesn’t handle tablature (tab).

Let’s put all of this together and look at an example. Here is a snippet of “It’s Too Late” by Carole King.

{t: It's Too Late } 
{key: Am}
{artist:Carole King}
{time: 4/4}
{tempo: 104}
# Style: Cool8Beat
{stylecode: 5635}
{start_accomp}

[Am7][*IA]
# Introduction (intro riff)
[Am7][*MA] [D6] [Am7] [D6]

{c: Verse 1}
[Am7] Stayed in bed all morning just to [D6] pass the time.
[Am7] There's something wrong here there can [D6] be no denying.
[Am7] One of us is changing
Or [Gm7] maybe we've just stopped [Fmaj7] trying. [Fmaj7][*FA]

{start_of_chorus}
And it's too [Bbmaj7][*MB] late baby now [Fmaj7] it's too late
Though we [Bbmaj7] really did try to [Fmaj7] make it.
[Bbmaj7] Something inside has [Fmaj7] died
And I can't hide [Dm7] and I just can't [Esus4:2][*FB] fake it.[E7#9:2]
{end_of_chorus}

Lines beginning with ‘#’ are comments. Lines beginning with ‘{‘ are directives. Each directive must have a closing ‘}’ and consist of one line only. My translation tool supports the following simple directives:

  • title (or ‘t’): Song title
  • key: Song key
  • artist: Performing artist
  • composer: Song composer
  • copyright: Copyright information
  • comment (or ‘c’): Comment to be ignored
  • time: Time signature
  • tempo: Song tempo in BPM
  • stylecode: Yamaha style code (a decimal number)
  • start_accomp, stop_accomp: Starts and stops the accompaniment

As I mentioned, time, tempo and stylecode are optional, but necessary — unless you are willing to roll with the defaults. Start_accomp must be the final directive before the first chord and lyric in the song. Start_accomp generates the magic message needed to start accompaniment.

Chords look like regular ChordPro chords. Chord names are surrounded by square brackets, e.g., “[Am7]”. Nothing looks amiss until the end of the chorus, e.g., “[Esus4:2]” and “[E7#9:2]”. “:2” is a beat count. Each chord is held for two quarter notes — quarter notes because the number of divisions per bar (the “denominator”) of the time signature is four. It’s our job to make sure that the counts add up to a full measure in order to keep everything synchronized to measures.

The translation program (yet unnamed!) is very forgiving when it comes to chord spelling. However, it only recognizes and generates the 34 Yamaha chord types which are supported by Yamaha arrangers:

    Maj        7        min        minMaj      aug      dim 
Maj6 7sus4 min6 minMaj7 aug7 dim7
Maj7 7b5 min7 minMaj7-9
Maj7#11 7-9 min7b5
Maj9 7#11 min9
Maj7-9 7-13 min7-9
Maj6-9 7b9 min7-11
7aug 7aug
8
5
sus2
sus4

If the chord is not recognized, you will get a major or minor triad.

ChordPro allows annotations, that is, constructs beginning with “[*” and ending with “]”. Annotations ordinarily are playing instructions that are displayed in a pretty-printed ChordPro song. Annotations are extended with accompaniment section control commands:

  • Introduction: [*IA] [*IB] [*IC] [*ID]
  • Main section: [*MA] [*MB] [*MC] [*MD]
  • Fill in: [*FA] [*FB] [*FC] [*FD]
  • Break: [*BR]
  • Ending: [*EA] [*EB] [*EC] [*ED]

A section control command usually follows a chord and takes effect at the same time as the chord change.

ChordPro supports paired formatting directives like:

    {start_of_chorus} 
...
{end_of_chorus}

I am currently experimenting with these directives to control lyric and chord formatting. Yamaha’s lyric display allows line breaks and page breaks. Start of chorus (abbreviated “{soc}”) generates a page break. I added a new directive pair for handling long instrumental breaks, e.g.,

    {start_of_instrumental} 
[Cmaj7][*MC] [Fmaj7] [Fmaj7] [Am7] [Gm7] [Fmaj7]
[Dm7] [Esus4:2][*FC] [E7#9:2]
{end_of_instrumental}

Yamaha’s lyric display runs chords together when no lyric text is present. The new directive provides some separation between chords by generating filler lyric text (dashes, to be exact).

That’s the story. Testing continues. I will make the Java source code available as soon as possible. So far, so good. The concept works.

Copyright © 2021 Paul J. Drongowski

Chord Tracker revealed

I am using the Yamaha Chord Tracker app to figure out the chords to some tunes. Chord Tracker analyzes the music in an MP3/audio file and displays a chord chart. This is great for learning new tunes and working out arrangements.

Chord Tracker can do much, much more! Yamaha really needs to produce a manual for this app to reveal all of these functions. Here are some useful tips including how to send a MIDI file for a transcribed song to your Yamaha PSR/Tyros arranger for playback.

First off, you can change the chords in the chord chart. If you don’t like a chord, just tap the chord and select a new one. Chord Tracker does a pretty decent job of identifying chords in “simple” music. For example, it did a great job with Hot Chocolate’s “Every 1’s A Winner.” (My guilty pleasure.) It didn’t do such a good job with Groovy Waters downtempo “Wicked Game.” The jazz chords (Dm/Eb, come on, man) threw Chord Tracker off. No problem, just edit the chord chart.

Here’s a crazy idea. Use a DAW to produce a three minute song with one or two chords at the beginning. Transcribe the song with Chord Tracker. When you need to create a new song from scratch, edit the new chords. Presto, a chord chart editor.

Next, you can send the chord progression to your PSR/Tyros. The Yamaha web site touts wireless connection, but you can send the song file via wired USB. I transferred the chord progression to my S950 using the Apple Camera Connection kit. (My iPad is a gen 4 running iOS9, BTW.)

The Yamaha web page for Chord Tracker states that Chord Tracker is compatible with the currently listed “Related Products.” That is true. However, Chord Tracker worked successfully with the S950 (not listed). So, even though you don’t own the latest and greatest, please give this capability a try.

On the iPad side, you need to establish a connection from Chord Tracker to your keyboard. Plug in the Camera Connection Kit and USB cable first. Then select your instrument in the Connection box on Chord Tracker’s main screen.

Choose an audio song to transcribe to a chord chart and turn Chord Tracker loose. Once you have a chord chart, tap the upload icon, i.e., that square box with an arrow shooting upward. Then tap the “Send to Instrument” button. Chord Tracker pops up a dialog in which you can enter/change the name of the song file to be created on the arranger workstation. Tap SEND and Chord Tracker sends the song file to the arranger.

Chord Tracker stores the song file in the arranger’s internal drive. It creates a directory named “ChordTracker” and stores the song file in this directory. Any other song file that you create this way is stored in the “ChordTracker” directory.

Press the SONG SELECT button on the arranger to find and select the song file. Navigate to the USER tab of the internal drive and then press the corresponding button for the “ChordTracker” directory. Then press the corresponding button for the song file itself, e.g., “every1s”, which is the name that I gave to the “Every 1’s A Winner” song file.

Press the play button. The arranger will play back the song using the currently selected style and section. Now have fun changing the style, section, tempo and so forth. You can change the style, section, etc. in real time while the song plays, making it easy to tune the song to your sonic wishes.

Of course, you can dive into SONG CREATOR and tweak away. The System Exclusive TAB reveals much of the magic behind the scenes.

Chord Tracker generates three MIDI metadata records for time signature, key signature and tempo, followed by three System Exclusive messages:

    F0 7E 7F 09 01 F7             GM reset
    F0 43 10 4C 00 00 7E 00 F7    XG system ON
    F0 43 60 7A F7                Accompaniment start

The preamble is followed by a slew of Yamaha System Exclusive messages for the chord changes:

    F0 43 7E 02 34 00 34 7F F7    Chord control (F maj/F)
    F0 43 7E 00 08 7F F7          Section control (MAIN A ON)
    F0 43 7E 02 23 00 23 7F F7    Chord control (Eb maj/Eb)

Chord Tracker does not generate the Yamaha proprietary CdS1 chunk in the MIDI file. All playback is controlled by metadata and System Exclusive messages.

We can expect to see more of these kinds of features from Yamaha. They have a US patent (number 9,142,203) for a formatted chord chart and accompaniment generator. The generator is driven by a simple, free form text chord chart.

All site content is Copyright © P.J. Drongowski unless otherwise indicated.