What are you working on currently?

What are you working on currently?

Here are what’s in my tabs. Feel free to use, comment and change.

Tab0 0:00 Big reverb with clicky sounds and fm saw bass
Tab1 0:47 Lead melody setup
Tab2 1:34 Evening sketch - slow groove bpm 88
Tab3 2:21 Blues
Tab4 2:45 Fast saw with moving top
Tab5 3:12 Fast synth
Tab6 4:05 OSC from Sonic Pi to VVVV take 2

Tab 0

# 221020 2242 big reverb with clicky sounds and fm saw bass
# saved 221020
# Created by https://linktr.ee/relaxnow
# YT https://youtu.be/pjR76imgapk Preview of Sonic Pi tabs 1-6

# Warning: "Timing warning: runnnig slightly behind"
# (https://in-thread.sonic-pi.net/t/time-error-with-higher-tempo-some-advices/4144/19) => it's a fx reverb thing


live_loop :time, delay: 0.01 do
  sleep 1
end

with_fx :level, amp: 4 do
  with_fx :reverb do  # small reverb
    
    / Bass /
    
    with_fx :ixi_techno do
      live_loop :bass1, sync: :time do
        # stop
        tick                # my_array
        n0 = [nil]          # 0
        n1 = [:c2,]         # 1
        n2 = [:c2,:c3]      # 2
        n3 = [:c2,:c3,:c4]  # 3
        my_array = 0
        a=64
        my_array = knit(0,a, 1,a, 2,a, 3,a).look
        my_array_n = knit(0,a/2, -3,a/2, -5,a/2, -3,a/2).look
        b=range(70,120,step: 1).look
        my_cutoff = knit(b,a, b,a, b,a, b,a).look
        notes = [n0,n1, n2, n3][my_array]
        
        synth :fm, note: notes.look-my_array_n, release: 0.15, cutoff: my_cutoff, amp: 0.4, pan: -0.75 if bools(1,0,1,0,1,1,0,1,0,1,0,0).look
        synth :saw, note: notes.look-my_array_n+12, release: 0.1, cutoff: my_cutoff, amp: 0.4, pan: 0.75 if bools(1,0,1,0,1,1,0,1,0,1,0,0).look
        sleep 0.125
      end
    end
  end #end reverb
  
  
  with_fx :reverb, room: 0.9 do   # big reverb
    
    / Clicky stuff /
    
    with_fx :distortion do
      live_loop :pluck1, sync: :time do
        #stop
        #sleep 8
        4.times do
          tick
          use_random_seed knit(10,1, 12,1).look
          n = scale(:c4, :minor_pentatonic)
          8.times do
            tick
            co = range(-0.6,-0.1, step: 0.015).mirror.look
            synth :pluck, note: n.take(3).choose, release: 0.25, amp: 0.25, coef: co if bools(1,0,1,1,0).look
            sleep 0.125
          end
        end
        
        sleep 0.125*8*4
      end
    end
    
    live_loop :clicky, sync: :time do
      #stop
      tick
      sample :elec_plip, rate: [1,2,4,8].choose, pan: rrand(-1,1) if bools(0,1,1,1).look if one_in(2)
      sleep 0.125
    end
    
    
    / Drums /
    
    live_loop :kick, sync: :time do
      sample :bd_fat, amp: 4
      sleep 5
    end
    live_loop :snare do
      sleep 1
      sample :elec_tick, cutoff: 100, amp: 1, rate: 2
      sleep 3
      synth :cnoise, note: :c3, release: rrand(0.01,0.1), amp: rrand(0.4,0.6)
      sleep 1
    end
    
    
  end #end big reverb
  
end

Tab 1

# 221019 lead melody setup
# Saved 221020 2312
# Created by https://linktr.ee/relaxnow

use_bpm 88

live_loop :time, delay: 0.01 do
  sleep 1
end


with_fx :level, amp: 4 do
  with_fx :reverb  do
    
    
    
    live_loop :chords, sync: :time do
      tick
      use_synth :saw
      use_synth_defaults release: rrand(0.1,0.3), cutoff: range(120,70,steps: -0.5).look
      
      root =:c2
      repeat=16*2
      c=1
      
      a=knit(0,repeat, c,repeat).look
      b=knit(3,repeat/2, 2,repeat/2, 3,repeat/2, 5,repeat/2).look
      
      / Create variation by changing "b" manually (stop ":arp1" else it's hard to hear) /
      #b=5  # 5 3 1 0 8 7
      
      
      play root+a, pan: 0.5 if bools(1,1,1,1,0,0,1,1,1,1,1,0).look
      play root+12+a, pan: -0.5 if bools(1,1,1,1,0,0,1,1,1,1,1,0).look
      play root+24+b if bools(1,0,0, 1,0,0, 1,0,0, 1,0,1) .look
      sleep 0.25
    end
    
    
    live_loop :mel1 do
      tick
      use_synth :saw
      use_synth_defaults release: 2#, cutoff: range(70,120,steps: 1).look
      
      / Manual melody selector /
      part = 1  # play 1      (then 0   0 NB still needs work, not use currently)
      
      # part 1
      mel2 =   [:g4,:c5, :c5,:g4,:gs4, :f4,  :g4,:c5, :c5,:g4,:gs4, :cs5]
      sleep2 = [2,   4,   1,  1,  2,    6,    2,   4,   1,  1,  2,    6]
      # part 0 (still needs work)
      mel1 = [:d5,:c5, :ds5, :f5, :g5, :gs5]
      sleep1 = [2, 4, 1,  1, 2,   6]
      
      
      mel =[mel1, mel2][part]
      my_sleep = [sleep1, sleep2][part]
      
      play mel.look, amp: 0.5
      sleep my_sleep.look
    end
    
    
    live_loop :arp1, sync: :time do
      #stop
      tick
      use_synth :saw
      use_synth_defaults release: 0.125
      
      mel1 = [:c5,:c5, :g5, :g5, :c4, :c4]
      sleep1 = [0.25]# [2, 4, 1,  1, 2,   6]
      
      mel2 =   [:g4,:c5, :c5,:g4,:gs4, :f4]
      sleep2 = [0.25]#[2,   4,   1,  1,  2,    6]
      
      a = 64*2
      part = knit(0,a, 1,a).look
      
      mel =[mel1, mel2][part]
      my_sleep = [sleep1, sleep2][part]
      
      play mel.look+0, amp: 1, on: knit(false,a/2, true,a*2).look # # "on:" if you want it to start without pause in beginning
      sleep my_sleep.look
    end
    
  end
  
  live_loop :kick1, sync: :time do
    16.times do
      sample :bd_haus, cutoff: rrand(85,95), amp: 4
      sleep 1
    end
    sleep 16
  end
  
  
end

Tab 2


# 221011 0056 Evening sketch - slow groove bpm 88
# 221011 0056 saved
# Posted in https://in-thread.sonic-pi.net/t/evening-sketch-slow-groove-bpm-88/7173
# Created by https://linktr.ee/relaxnow

use_bpm 88

live_loop :time, delay: 0.01 do
  sleep 1
end




live_loop :metronom, sync: :time do
  tick
  sample :elec_beep, finish: rrand(0.025,0.032), pan: rrand(0.5,-0.5), amp: rrand(0.5,1) if spread(3,5).look
  sleep 0.25
end


with_fx :reverb, room: 0.99 do
  
  s1 ="C:/Users/1234/Downloads/mixkit-glitchy-sci-fi-robotic-voices-279.wav"  # external sample
  live_loop :slicess, sync: :time do
    #stop
    tick
    sample s1,  amp: 4, slice: range(0,15,step: 1).look, finish: 0.5, rate: 8, pan: rrand(-1,1) if one_in(4) and bools(0,0,1).look
    puts range(0,15,step: 1).look
    sleep 0.25
  end
  
  
  live_loop :piano1, sync: :time do
    use_synth :piano
    n = :fs1-0
    tick
    play n, release: 4
    play n+12, release: 4, amp: [2,0,0,0].look, pan: rrand(0.25,-0.25)
    sleep 6
    sample :bd_mehackit, rate: 4
    sleep 2
  end
  
  
  live_loop :sweep1 do
    tick
    sample :elec_ping, amp: (line 0, 1, inclusive: true, steps: 24).mirror().look, rpitch: knit(-12,24*2, -3, 24, 0, 24).look#, finish: rrand(0.025,0.032),
    sleep 0.25
  end
  
  
  live_loop :sampl1 do
    
    16.times do
      tick
      sample :glitch_robot2, beat_stretch: 4, rate: 12, start: 0.1, finish: 0.04 if spread(5,7).look
      sleep 0.25
    end
    sleep 4#0.5
    16.times do
      tick
      sample [:glitch_robot1,:glitch_robot2].choose, beat_stretch: 4, rate: 6, start: 0.1, finish: 0.04 if spread(5,7).look
      sleep 0.25
    end
    sleep 4#0.5
    sleep [2,4,6].choose
    
  end
  
end #end reverb

with_fx :panslicer do
  live_loop :bass1, sync: :time do
    use_synth :saw
    tick
    a = 64
    c = knit(65,a, 75,a, 85,a, 95,a, 105,a, 125,a).mirror.look
    r = knit(0.2,a, 0.3,a, 0.4,a, 0.2,a, 0.3,a, 0.4,a).mirror.look
    play knit(:fs2,31, :fs2+3+12,1).look, cutoff: c, release: r if bools(1,0,0,1,0,0,1,0,0,1,1,0).look
    sleep 0.25
  end
end

live_loop :kick, sync: :time do
  sample :bd_haus, cutoff: 70, amp: 3
  sample :bd_fat, amp: 3
  sleep 1
  4.times do
    sample :bd_haus, cutoff: 70, amp: 1.5
    sleep 1
  end
  sleep 3
end

Tab 3

# blues like progression


use_bpm 88

live_loop :time, delay: 0.01 do
  sleep 1
end


with_fx :reverb do
  
  # with_fx :level, amp: 4 do
  
  live_loop :blues_chords, sync: :time do
    tick
    a=32
    my_root = knit(1,a, 2,a/2, 1,a/2, 3,a/2, 2,a/2, 1,a/2, 3,a/2).look
    
    case my_root
    when 0
      stop
    when 1
      root = :c2
    when 2
      root = :f2
    when 3
      root = :g2
    end
    
    
    use_synth  :saw
    use_synth_defaults cutoff: range(85,115, steps: 1).look
    
    play root, release: 0.4, amp: 4 if bools(1,0,0,1,1,0,0,0).look
    play root+24, release: 0.2, amp: 4 if bools(0,1,1,0,1,1).look
    play root+24+3, release: 0.2, amp: 4 if bools(0,0,1).look
    play root+24+5, release: 0.2, amp: 4 if bools(0,1,0,0).look
    sleep 0.25
  end
  
end #end reverb
#end #end level

Tab 4

# Fast saw with moving top

use_bpm 99

live_loop :time, delay: 0.01 do
  sleep 1
end

with_fx :level, amp: 2 do
  
  live_loop :synth1, sync: :time do
    use_synth :saw #:saw #:dsaw
    use_synth_defaults release: rrand(0.2,0.4), cutoff: rrand(70,120)
    tick
    root = :f2
    
    play root+0 if bools(1,1,1,1,1,1,0,1).look
    play root+12 if bools(0,0,1).look
    play root+12+5 if bools(0,0,0,0,1).look
    #play root+12+[5,3,7].choose+12 if bools(0,1,0,0,0,1).look
    play root+12+knit(5,24, 3,24).look+12 if bools(0,1,0,0,0,1).look
    play root+12+knit(5,24, 3,24, 5,24, 3,24, 7,24, 5,24).look+12+12 if bools(0,1,0,0,0,1,0).look
    sleep 0.25
  end
  
end

Tab 5

# 221020 fast synth
# Created by https://linktr.ee/relaxnow


with_fx :level, amp: 4 do
  
  with_fx :reverb, room: 0.6 do
    live_loop :bass1 do
      use_synth :saw
      use_synth_defaults release: 0.1
      tick
      
      play :c2 if bools(1,1,0,0,0,1,0,0,0,0).look
      play :c4 if bools(0,1,1,0,0,1).look
      play :c5 if bools(1,0,0,1,0,1,0).look
      play [:c5,:ds5,:g5].look if bools(0,1,0,0,1).look                # arp
      #play [:c5,:ds5,:g5] if bools(0,1,0,0,1).look                     # chord
      #play [:c5,:ds5,:g5].reverse.look if bools(1,0,1,0,0,1,0,0).look  # arp reverse
      sleep 0.125
      
    end
    
    live_loop :kick do
      #stop
      
      5.times do
        sample :bd_haus, cutoff: 85 #if bools(1,0,0,1,0,1,0).look
        sleep 0.5
      end
      sleep 0.5*3
      
      6.times do
        sample :bd_haus, cutoff: 95 #if bools(1,0,0,1,0,1,0).look
        sleep 0.5
      end
      sleep 0.5*2
    end
    
  end
end

Tab 6

# 221016 2116 OSC from Sonic Pi to VVVV take 2
# backup 221016
# YT https://youtu.be/KLqvDBgyGLc
# Created by https://linktr.ee/relaxnow

use_osc "localhost", 5510

use_bpm 77

live_loop :time do
  sleep 1
end

with_fx :level, amp: 4 do
  
  live_loop :metronem, sync: :time do
    sample :elec_flip, rate: 4
    sleep 1
  end
  
  with_fx :reverb, room: 0.9 do
    
    live_loop :piano do
      #stop
      tick
      use_synth :piano
      use_synth_defaults #release: 3
      play :f2
      play :f1
      sleep 4
    end
    
    live_loop :chords  do
      #stop
      tick
      use_synth :piano
      use_synth_defaults release: 0.4
      n1 = [:f4, :c5,:f5]
      n2 = [:f4, :c5,:g5]
      n3 = [:f4, :c5,:gs5]
      a = 16
      notes = knit(n1,a, n2,a, n3,a/2)
      play notes.look if bools(1,0,0,1,0,1,1,0,0,0,0,).look
      sleep 0.25
    end
    
    with_fx :ping_pong do
      live_loop :mel1, sync: :time do
        sample :elec_plip, rate: rrand(1,4), amp: rrand(2,4), pan: rrand(-1,1)
        sleep 5
      end
    end
    
  end
  
  live_loop :kick1 do
    
    5.times do
      tick
      sample :bd_haus, cutoff: 85, amp: bools(4,0,1,0,1).look if spread(3,5).look
      sample :elec_bell, cutoff: 85, amp: bools(0,1,0,1,0).look, finish: rrand(0.1,0.3), rate: [2,4,8].choose #if spread(3,5).look
      puts  osc "/vars/spA",1 if spread(3,5).look
      puts  osc "/vars/spB",1 if bools(0,1,0,1,0).look
      #puts "spA = ", scale(:c4, :minor_pentatonic).shuffle.take(3).tick if spread(5,7).tick
      #  sample :sn_dolf, cutoff: 85 if spread(5,7).look
      #  puts  osc "/vars/spB",1 if spread(5,7).look
      
      sleep 0.25
    end
    7.times do
      tick
      sample :bd_haus, cutoff: 115 if spread(5,7).look
      puts  osc "/vars/spA",1 if spread(5,7).look
      #puts "spA = ", scale(:c4, :minor_pentatonic).shuffle.take(3).tick if spread(5,7).tick
      #  sample :sn_dolf, cutoff: 85 if spread(5,7).look
      #  puts  osc "/vars/spB",1 if spread(5,7).look
      
      sleep 0.25
    end
    
    # osc "/vars/spA",0
    # osc "/vars/spB",0
  end
end

1 Like

https://youtu.be/McZtkIB5UcY

1 Like
4 Likes

Hi,

I just finished this one today.
It’s acoustic guitar samples and effects.

Edit - I refactored the code…

# Title: Modesta
# Artist: L.Bridge
# Date: 25-Oct-2022
# License: cc-by
# Sonic Pi v4.3 (Win 10)

# Settings
use_bpm 125
bar_length = 4
use_random_seed 14553
swing = (ring 0.01, -0.01)
sample_folder = "../BRAZILIAN_GUITARS/125 BPM/125 BELEM/"

# Functions
define :bar do |length = 8|
  sleep bar_length * length
end

define :sleep_with_swing do |sleep_duration|
  sleep sleep_duration + swing.look
end

# Loops
define :g_bass do |length = 8, pattern = 1|
  in_thread do
    s = sample_folder + "BGB_125_Em_Belem_Bass.wav"
    slices = (line 0, pattern, steps: 4, inclusive: true)

    ((bar_length * length)).times do ; tick
      sample s,
        amp: rrand(1, 1.2),
        pan: -0.2,
        slice: slices.look,
        num_slices: 32,
        release: 1
      
      sleep_with_swing 1
    end
  end
end

define :g_mids do |length = 8, pattern = 1|
  in_thread do
    s = sample_folder + "BGB_125_Em_Belem_Rhythm_Guitar.wav"
    slices = (line 0, pattern, steps: 4, inclusive: true)
    
    ((bar_length * length)).times do ; tick
      sample s,
        amp: rrand(1, 1.2),
        pan: 0.2,
        slice: slices.look,
        num_slices: 32,
        release: 1
      
      sleep_with_swing 1
    end
  end
end

define :g_lead do |length = 8, pattern = 1|
  in_thread do
    s = sample_folder + "BGB_125_Em_Belem_Lead_Guitar.wav"
    slices = (line 0, pattern, steps: 4, inclusive: true)
    
    ((bar_length * length)).times do ; tick
      sample s,
        amp: rrand(1, 1.2),
        pan: 0.5,
        slice: slices.look,
        num_slices: 32,
        release: 1
      
      sleep_with_swing 1
    end
  end
end

# Structure
part = 1

2.times do
  with_fx :echo, phase: 2, decay: 4, mix: 0 do |_echo|
    with_fx :whammy, grainsize: 4, deltime: 0.0625, mix: 0 do |_whammy|
      control _whammy, mix: 0.85 if part == 2
      g_bass(1,2) ; g_mids(1,4) ; bar(1)
      g_bass(1,3) ; g_mids(1,5) ; bar(1)
      g_bass(2,3) ; g_mids(2,7) ; bar(2)
      g_bass(2,5) ; g_mids(2,9) ; bar(2)
      g_bass(1,7) ; g_mids(1,11) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      
      g_bass(1,2) ; g_mids(1,4) ; bar(1)
      g_bass(1,3) ; g_mids(1,5) ; bar(1)
      g_bass(2,3) ; g_mids(2,7) ; bar(2)
      g_bass(2,5) ; g_mids(2,9) ; bar(2)
      g_bass(1,7) ; g_mids(1,11) ; g_lead(1,8) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      
      control _echo, mix: 1 if part == 2
      control _whammy, mix: 0.15 if part == 1
      g_bass(2,3) ; g_mids(2,7) ; bar(2)
      g_bass(2,5) ; g_mids(2,9) ; bar(2)
      g_bass(1,7) ; g_mids(1,11) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      g_bass(1,2) ; g_mids(1,4) ; g_lead(1,4) ; bar(1)
      g_bass(1,3) ; g_mids(1,5) ; g_lead(1,6) ; bar(1)
      
      g_bass(1,1) ; g_mids(1,2) ; bar(1)
      g_bass(1,2) ; g_mids(1,3) ; bar(1)
      g_bass(1,7) ; g_mids(1,11) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      g_bass(2,7) ; g_mids(2,11) ; g_lead(2,8) ; bar(2)
      g_bass(1,9) ; g_mids(1,13) ; g_lead(1,13) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      
      control _whammy, mix: 0.3 if part == 1
      g_bass(2,1) ; g_mids(2,2) ; bar(2)
      g_bass(1,7) ; g_mids(1,11) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
      g_bass(2,7) ; g_mids(2,11) ; g_lead(2,8) ; bar(2)
      g_bass(1,9) ; g_mids(1,13) ; g_lead(1,13) ; bar(1)
      g_bass(1,9) ; g_mids(1,13) ; bar(1)
    end
    
    part = 2
  end
end
4 Likes

Modesta sounds nice. Is your Brazilian Guitar sample folder available anywhere?

1 Like

Thanks Robin :slight_smile: I’ll upload them later for you and share the link.

1 Like

I’m working on something that will start in 12 ED2 and progress to 18 ED2.