Strudelify

When You're Twenty-One

Johnny Cash

KeyG majorTempo150 bpm
0:00/0:00
// When You're Twenty-One — Cash Johnny
// 150 bpm, 4/4, key G major. Source: midi.
// Generated by strudelify. One cycle = one bar.
// note: duplicate parts dropped: ch 4 "Steel Gui" acoustic guitar steel (copy of ch 5 "Shamisen" shamisen)
// note: Full arrangement: all 131 bars on a 16-step grid, each part at one level; ghost notes are separate "_soft" parts. Source detail keeps the original performance.
setcpm(150/4)

// Notation: c3@3 lasts 3 steps · ~ is a rest · [c3,e3] is a chord · "a, b" plays two voices at once · [...]/2 spreads a riff over 2 bars.
// A part's distinct bars are riffs (A, B, C...) played in order: edit a riff to change every repeat.

// other · harmonica · "Backup Vo"
const harmonica = note(`<
  ~@35 A B@2 C@2 D@2 E F G@2 C@2 H I J@2 ~@15 A B@2 C@2 D@2 E F G@2 C@2 H I K@2 B@2 C@2 D@2 E F G@2 C@2 H I K@2 B@2 C@2
  D@2 E F G@2 C@2 H I L M B@2 C@2 N@2 ~@9
>`.pickRestart({
  A: "~@8 b4@3 ~ a4@3 ~", B: "[g4@6 ~@2 g4@3 ~ e4@2 g4@6 g4@3 ~ b4@3 ~ a4@3 ~]/2",
  C: "[g4@6 ~@2 g4@3 ~ g4@2 d4@5 ~@5 b4@3 ~ a4@3 ~]/2", D: "[g4@6 ~@2 g4@3 ~ e4@2 g4@5 ~ g4@6 ~@2 g4@3 ~]/2",
  E: "b4@5 a4 c5 b4", F: "g4@6 ~@2 b4@3 ~ a4@3 ~", G: "[g4@6 ~@2 g4@3 ~ e4@2 g4@5 ~ g4@3 ~ b4@3 ~ a4@3 ~]/2",
  H: "g4@6 ~@2 g4@3 ~ g4@3 ~", I: "a4@3 ~ b4@6 ~@2 b4@3 ~", J: "[b4 a4 g4@9 ~@5]/2",
  K: "[b4@2 a4@2 g4@15 ~@5 b4@3 ~ a4@3 ~]/2", L: "b4 a4 g4@6", M: "g4@3 ~@5 b4@3 ~ a4@3 ~",
  N: "[g4@6 ~@2 g4@3 ~ e4@2 g4@5 ~ g4@6 ~@6]/2",
})).s("gm_harmonica").gain(0.41)

// other · harmonica · "Backup Vo" · soft notes
const harmonica_soft = note("<~@121 A B C D@2 E@2 F G H>".pickRestart({
  A: "~@12 g4@3 ~", B: "b4@5 a4 c5 b4", C: "g4@6 ~@2 b4@3 ~ a4@3 ~",
  D: "[g4@6 ~@2 g4@3 ~ e4@2 g4@5 ~ g4@3 ~ b4@3 ~ a4@3 ~]/2", E: "[g4@6 ~@2 g4@3 ~ g4@2 d4@5 ~@5 b4@3 ~ a4@3 ~]/2",
  F: "g4@6 ~@2 g4@3 ~ g4@3 ~", G: "a4@3 ~ b4@6 ~@2 b4@3 ~", H: "b4 a4 g4@6",
})).s("gm_harmonica").gain(0.14)

// chords · piano
const piano = note("<A@2 B@8 C@8 D@2 E@7 F@4 G@8 H@8 I@8 J@8 K@8 L@8 M@8 N@8 M@8 N@8 O@4 P@7 ~@9>".pickRestart({
  A: "[[g3,b3]@5 [g3,b3] [a3,c4] [a#3,c#4]]/2", // G Am A#m
  B: "[[b3,d4]@5 [d4,b4] [c#4,a#4] [c4,a4]@2 [b3,d4]@2 [b3,d4]@2 [b3,d4]@2 [b3,d4]@2 [c4,e4]@2 [c4,e4]@2 [e3,g3]@2 [c4,e4]@2 [b3,d4]@2 [b3,d4]@2 [d4,g4]@2 [d4,g4]]/8", // Bm G F# F Bm C Em C …
  C: "[~@2 [c4,f#4]@4 [c4,f#4]@4 [d4,f#4,b4]@4 [c4,f#4,a4]@4 [b3,d4]@4 [b3,d4]@4 [b3,d4]@4 [b3,d4]@4 [c4,e4]@4 [c4,e4]@4 [e3,g3]@4 [e3,g3]@4 [b3,d4]@4 [b3,d4]@4 [c4,f#4]@4 [c4,d4] [b3,d4]]/8", // Cdim Bm F#dim Bm C Em Bm Cdim …
  D: "[~@2 [b3,d4]@4 [b3,d4]@3 d4 [b4,d5]@2 c5 b4 a4@2]/2", // Bm
  E: "[g4 [b3,d4]@2 [b3,d4]@2 [b3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@121 A@8 B@2>".pickRestart({
  A: "[~@3 [c4,e4]@2 [d4,g4]@2 [d4,g4]@2 [d4,g4]@2 [d4,g4]@2 [c4,e4]@2 [c4,e4]@2 [c4,e4]@2 [c4,e4]@2 [b3,d4]@2 [b3,d4]@2 [g3,b3]@2 [b3,d4]@2 [c4,e4]@2 [c4,e4]]/8", // C G5 C Bm G Bm C
  B: "[~ [d4,f#4]@2 [d4,f#4]@2 [b3,d4]@2 [b3,d4]]/2", // D Bm
})).s("gm_piano").gain(0.12)

// bass · synth bass 2 · "Bass"
const bass = note(`<
  A@3 B A C D E A C F G A C D H I J A B A C D E A C F G A C D H I J A K D H A K D H A K D H A K H G A B A C D E A C F G
  A C D H I J A K D H A K D H A K D H A K H G A B D H A K D H A K D H A K H G A B D H A K D H A K D H A K H G A B D H A
  K D L ~@9
>`.pickRestart({
  A: "g2@3 ~ d2@3 ~", B: "g2@3 ~ d2@3 ~ e2@3 ~ f#2@3 ~", C: "g2@6 ~@2 a2@3 ~ b2@3 ~", D: "c3@3 ~ g2@3 ~",
  E: "c3@6 ~@2 b2@3 ~ a2@3 ~", F: "d3@3 ~ a2@3 ~", G: "d3@3 ~ d2@3 ~", H: "c3@3 ~ c3@3 ~", I: "g2@3 ~ g2@3 ~",
  J: "d2@3 ~ d2@3 ~", K: "g2@3 ~ g2@3 ~ a2@3 ~ b2@3 ~", L: "c3@3 ~@5",
})).s("gm_synth_bass_2").gain(0.42)

// bass · synth bass 2 · "Bass" · soft notes
const bass_soft = note("<~@121 A B C D E B C E F B>".pickRestart({
  A: "~@4 c3@3 ~", B: "g2@3 ~ d2@3 ~", C: "g2@3 ~ g2@3 ~ a2@3 ~ b2@3 ~", D: "c3@3 ~ g2@3 ~", E: "c3@3 ~ c3@3 ~",
  F: "d3@3 ~ d2@3 ~",
})).s("gm_synth_bass_2").gain(0.14)

// chords · shamisen
const shamisen = note(`<
  A@6 B C D E F G D@2 B H D I D J A@2 B C D E F G D@2 B H D K D@2 L@2 M N L@2 O@2 L@2 M P L Q M@2 A@2 B C D E F G D@2 B
  H D K D@2 L@2 M N L@2 O@2 L@2 M P L Q M@2 L@2 M N L@2 O@2 L@2 M P L Q M@2 L@2 M N L@2 O@2 L@2 M P L Q M@2 L@2 M N L R
  ~@9
>`.pickRestart({
  A: "[b3,d4]!4, g4 ~@3 g4 ~@3", B: "[c4,e4,g4] [c4,e4] [c4,e4,g4] [c4,e4]", C: "[c4,e4,g4] [e3,g3] [c4,e4,g4] [c4,e4]",
  D: "[b3,d4,g4] [b3,d4] [b3,d4,g4] [b3,d4]", E: "[d4,g4,b4] [d4,g4] [d4,g4,b4] [d4,g4]",
  F: "[c4,f#4,a4] [c4,f#4] [c4,f#4,a4] [c4,f#4]", G: "[c4,f#4,a4] [f#4,a4] [f#4,a4,d5] [c4,f#4]",
  H: "[c4,e4,g4] [e3,g3] [e3,g3,c4] [e3,g3]", I: "[b3,d4,g4] [c4,f#4] [b3,c4,g4] [b3,d4]",
  J: "[b3,d4,g4] [b3,d4] [c4,f#4,a4] [c4,f#4]", K: "[d4,f#4,a4] [d4,f#4] [d4,f#4,a4] [c4,f#4]",
  L: "[c4,e4,g4] [c4,e4]!3 [c4,e4,g4] [c4,e4]!3", M: "[b3,d4,g4] [b3,d4]!3 [b3,d4,g4] [b3,d4]!3",
  N: "[g3,b3,e4] [g3,b3]!3 [g3,b3,e4] [g3,b3] [b3,d4]!2", O: "[d4,g4,b4] [d4,g4]!3 [d4,g4,b4] [d4,g4]!3",
  P: "[g3,b3,e4] [g3,b3]!3 [g3,b3,e4] [g3,b3]!3", Q: "[c4,e4,a4] [c4,e4] [d4,f#4]!2 [d4,f#4,b4] [d4,f#4]!3",
  R: "[c4,e4,g4] [c4,e4]!3 ~@4", // C
})).s("gm_shamisen").gain(0.12)

// chords · shamisen · soft notes
const shamisen_soft = note("<~@121 A B@2 C@2 D E C F D>".pickRestart({
  A: "~@4 [c4,e4,g4] [c4,e4]!3", B: "[d4,g4,b4] [d4,g4]!3 [d4,g4,b4] [d4,g4]!3",
  C: "[c4,e4,g4] [c4,e4]!3 [c4,e4,g4] [c4,e4]!3", D: "[b3,d4,g4] [b3,d4]!3 [b3,d4,g4] [b3,d4]!3",
  E: "[g3,b3,e4] [g3,b3]!3 [g3,b3,e4] [g3,b3]!3", F: "[c4,e4,a4] [c4,e4] [d4,f#4]!2 [d4,f#4,b4] [d4,f#4]!3",
})).s("gm_shamisen").gain(0.04)

// drums · kick
const kick = s("bd").struct("<A@35 B A@7 B A@23 B A@7 B A@7 B A@7 B A@7 B A@7 B A@7 B A@5 C ~ D ~@7>".pickRestart({
  A: "x!2", B: "x ~@3 x!2 ~@2", C: "x", D: "~@5 x ~@2",
})).gain(0.48)

// drums · kick · soft notes
const kick_soft = s("bd").struct("<~@121 [~ x] [x!2]!9>").gain(0.16)

// drums · rim
const rim = s("rim").struct("<[~ x ~ x]!35 [~ x ~@2] ~@16 [~ x ~ x]!15 [~ x ~@2] ~@63>").gain(0.56)

// drums · snare
const snare = s("sd").struct("<~@36 A@7 B A@8 ~@16 A@7 B A@7 B A@7 B A@7 B A@7 B A@7 B A@5 C ~@9>".pickRestart({
  A: "~ x ~ x", B: "~@2 x ~@3 x!2", C: "~ x ~@2",
})).gain(0.48)

// drums · snare · soft notes
const snare_soft = s("sd").struct("<~@121 [~@3 x] [~ x ~ x] [~@2 x ~@3 x!2] [~ x ~ x]!7>").gain(0.16)

// drums · hihat
const hihat = s("hh").struct("<A@43 B A@31 B A@7 B A@7 B A@7 B A@7 B A@7 B A@5 C ~@9>".pickRestart({
  A: "x!8", B: "x!7 ~", C: "x!2 ~@6",
})).gain(0.72)

// drums · hihat · soft notes
const hihat_soft = s("hh").struct("<~@121 [~@2 x!6] [x!8] [x!7 ~] [x!8]!7>").gain(0.24)

// drums · mid tom
const mid_tom = s("mt").struct("<~@35 [~@7 x] ~@31 [~@7 x] ~@63>").gain(0.8)

// drums · high tom
const high_tom = s("ht").struct("<~@35 [~@3 x] ~@31 [~@3 x] ~@63>").gain(0.8)

// drums · ride
const ride = s("rd").struct("<A@4 ~@32 A@7 B A@8 ~@16 A@7 B A@7 B A@7 B A@7 B A@7 B A@7 B A@5 ~@10>".pickRestart({
  A: "~ x ~ x", B: "~@2 x ~@3 x!2",
})).gain(0.64)

// drums · ride · soft notes
const ride_soft = s("rd").struct("<~@121 [~ x ~ x]!2 [~@2 x ~@3 x!2] [~ x ~ x]!7>").gain(0.24)

// drums · crash
const crash = s("cr").struct("<~@36 A ~@7 A ~@23 A ~@7 A ~@7 A ~@7 A ~@7 A ~@7 A ~@7 A ~@7 A ~@6>".pickRestart({
  A: "x",
})).gain(0.56)

stack(
  harmonica, harmonica_soft, piano, piano_soft, bass, bass_soft, shamisen, shamisen_soft, kick, kick_soft, rim, snare,
  snare_soft, hihat, hihat_soft, mid_tom, high_tom, ride, ride_soft, crash
)

More by Johnny Cash