Psycho Killer by Talking Heads

Psycho Killer by Talking Heads (Piano Cover)
#https://www.youtube.com/watch?v=PZ6m_bKvbqI
#https://www.songsterr.com/a/wsa/talking-heads-psycho-killer-drum-tab-s55473t3

#Coded by Sergio
use_bpm 120

in_thread do
loop do
cue :PsK
sleep 1
end
end

Metronomo

m = (line 0, 114, steps: 114) # numeración del compás 4 por 4

in_thread do
sync :PsK
114.times do
puts inc m.tick # valor incremental de la variable “m”
puts “A
sleep 1
puts “B
sleep 1
puts “C
sleep 1
puts “D
sleep 1
end
end

Metronomo

####### Inicio DEFINICIONES TAMBORES#######

define :compás_5 do
sync :PsK
puts “C_5 TMB C_5 TMB C_5 TMB”
at [1, 2, 3, 4],[{:amp=>0.2, pan: -1}, {:amp=> 0.2, pan: 0},{:amp=>0.2, pan: 1}, {:amp=> 0.2, pan: 0}] do |p|
sample :drum_bass_soft, p
end
sleep 1
end

define :compás_12 do
sync :PsK
at [3] do
use_sample_defaults amp: 0.1, pan: -0.5
sample :drum_cymbal_hard
use_sample_defaults amp: 0.1, pan: 0.5
sample :drum_snare_hard
end
end

define :compás_13 do
sync :PsK
puts “C_13 TMB C_13 TMB C_13 TMB”
use_sample_defaults amp: 0.1, pan: 0.5
at [0,1,2,3] do
sample :drum_cymbal_closed
end
at [1,3] do
sample :drum_snare_hard
end
end

define :compás_21 do
sync :PsK
puts “C_21 TMB Psycho Killer TMB”
at [0] do
sample :drum_cymbal_hard
end
at [1,2,3] do
sample :drum_snare_hard
sample :drum_cymbal_closed
end
end

define :compás_22 do
sync :PsK
puts “C_22 TMB C_22 TMB C_22 TMB”
at [0,1,2,3] do
sample :drum_snare_hard
sample :drum_cymbal_closed
end
end

define :compás_39 do
sync :PsK
puts “C_39 TMB C_39 TMB C_39 TMB”
at [0] do
sample :drum_cymbal_hard
end
at [1, 3] do
sample :drum_snare_hard
end
at [1,2,3] do
sample :drum_cymbal_closed
end
end

define :compás_112 do
in_thread do
sync :PsK
puts “C_112 TMB C_112 TMB C_112 TMB”
at [3] do
sample :drum_cymbal_hard
end
at [1,3] do
sample :drum_snare_hard
end
at [1,2,3] do
sample :drum_cymbal_closed
end
end
end

define :compás_13_20 do
8.times do
compás_13
end
end

define :compás_25_28 do
3.times do
compás_21
end
compás_22
end

define :compás_93 do
3.times do
compás_21
end
compás_22
end #96
####### FIN DEFINICIONES TAMBORES#######

####### Inicio TAMBORES#######
in_thread do
sync :PsK
in_thread do
wait 44
114.times do
compás_5
end
end
wait (11
4)
compás_12
compás_13_20
2.times do
compás_21
compás_22
end
2.times do #25
compás_25_28
end #36
2.times do #37
compás_21
end
compás_39
11.times do
compás_13
end #50
2.times do #51
compás_21
compás_22
end#54
4.times do
compás_25_28 #55
end #70
6.times do #71
compás_22
end #76
2.times do #77
compás_21
compás_22
end #80
compás_39 #80
7.times do
compás_13
end #88
2.times do
compás_21 #89
compás_22
end #92
3.times do
compás_93
end #104
2.times do
compás_21 #105
end #106
compás_39 #107
3.times do
compás_13
end #110
compás_39 #111
compás_112
3.times do #114
compás_22
end #116
2.times do #117
compás_13
end
end
####### Fin TAMBORES#######

Looks interesting @Smoreno!
It seems that there’s a few things that still need doing to get it working, based on just copying and pasting the above code.
Pasting the above code into Sonic Pi and running as is doesn’t work for me for a few reasons - the quotes around the puts strings you print out are ‘fancy quotes’, and Sonic Pi does not interpret them correctly - (if you replace those with " then they are).
Also, I’m guessing that Metronomo is possibly just a comment in the code? the forum here interpreted it as a formatted heading, and when pasted into Sonic Pi it’s treated like a variable or function name - so what is needed I think is to stop the forum here from thinking Metronomo is a heading. The way to do this is to have an extra line above and below your code snippet, and place three back-ticks on both these lines: ```. This treats anything between those lines strictly as a code snippet, with handy syntax highlighting :slight_smile:

hi @ethancrawford,

i think this should be more visible when people get member ; how many times do we write these lines ? So where is the welcome guide ?

1 Like

Sounds like a good idea, I’ll create a pinned post :slight_smile:

oups there is already this :

Yes, I saw that too! Going to edit it to hopefully make formatting a little more obvious :slight_smile:

Actually I think there is already one (see heading “Code blocks”).

In my experience this is a question candidate for the FAQ. But I believe this won’t help because FAQ are usually not the same as FRQaA (frequently read questions and answers).

:wink:

I help myself and have a bookmarked link which I can post like here