Skip to content

Instantly share code, notes, and snippets.

@jimnanney
Created November 23, 2015 02:09
Show Gist options
  • Save jimnanney/13871ac7626b3091f5a3 to your computer and use it in GitHub Desktop.
Save jimnanney/13871ac7626b3091f5a3 to your computer and use it in GitHub Desktop.
Sonic Pi - Blue Monday
define :mydrums do
2.times do
sample :drum_heavy_kick
sleep 0.5
end
8.times do
sample :drum_heavy_kick
sleep 0.125
end
4.times do
sample :drum_heavy_kick
sleep 0.5
end
end
define :mysynths do
with_fx :reverb do
with_synth :dsaw do
with_synth_defaults attack: 0.01, amp: 0.5, release: 0.5 do
notes = [:F, :C, :D, :D, :G, :C, :D, :D]
notes.each do |n|
2.times do
play note(n, octave: 2)
sleep 0.25
play note(n, octave: 3)
sleep 0.25
end
end
end
end
end
end
live_loop :bassline do
mydrums
end
sleep 8
live_loop :synth_notes do
mysynths
end
@jimnanney
Copy link
Author

Stolen parts from This youtube video and adapted a bit.

https://www.youtube.com/watch?v=A_H6k2tcFvg

Found notes to use from this youtube:

https://www.youtube.com/watch?v=_sRUPLVS_Gg

@jimnanney
Copy link
Author

Now I feel like an idiot, in the help there are examples and this song is included, and done much better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment