Information Technology Grimoire

Version .0.0.1

IT Notes from various projects because I forget, and hopefully they help you too.

Dubstep Gamma

This is Dubstep with Gamma Binaural Beats

Try it

setcpm(140/4)  // 140 BPM - dubstep/minimal techno sweet spot

// ========== GAMMA ISOCHRONIC TONES (40Hz ±0.5Hz) ==========
// PRIMARY 40Hz PULSE - Randomized between 39.5-40.5Hz to prevent habituation
$: note("<39.5 40.1 40.3 39.8 40.5 39.7 40.2 40.4>".slow(8))
  .s("sine")
  .gain(0.15)  // Subliminal but present
  
// SECONDARY GAMMA PULSE - Slightly offset for binaural-like effect
$: note("<40.2 39.6 40.4 39.9 40.1 40.3 39.5 40.0>".slow(8))
  .s("sine")
  .gain(0.12)
  .pan(0.7)  // Right ear bias

// TERTIARY GAMMA PULSE - Left ear
$: note("<39.8 40.5 39.7 40.2 39.6 40.0 40.3 39.9>".slow(8))
  .s("sine")
  .gain(0.12)
  .pan(0.3)  // Left ear bias

// ========== MINIMAL DUBSTEP BASS ==========
// WOBBLE BASS - Sparse, hypnotic pattern
$: n("<<[0 ~ ~ ~] [~ ~ 7 ~] [~ 5 ~ ~] [3 ~ ~ ~]> <[0 ~ 7 ~] [~ 5 ~ 3] [0 ~ ~ 7] [~ ~ 5 ~]>>*2").scale("d:minor").trans(-24)
  .s("triangle")
  .lpf(perlin.range(300, 1200).slow(2))  // Slow wobble LFO
  .resonance(15)
  .gain(1.55)
  .distort(0.5)
  ._pianoroll()

// SUB BASS - Deep, minimal hits
$: n("<<[0 ~ ~ ~] [~ ~ ~ ~] [0 ~ ~ ~] [~ ~ ~ ~]> <[0 ~ ~ ~] [~ ~ 0 ~] [0 ~ ~ ~] [~ ~ ~ 0]>>").scale("d:minor").trans(-36)
  .s("sine")
  .gain(0.9)
  .lpf(80)
  ._pianoroll()

// MID BASS STABS - Dubstep growl (sparse)
$: n("<<~ ~ [0 7] ~> <~ [3 10] ~ ~> <~ ~ [5 12] ~> <[7 14] ~ ~ ~>>").scale("d:minor").trans(-12)
  .s("triangle")
  .lpf("<400 600 500 700>")
  .gain(0.6)
  .distort(0.6)
  ._pianoroll()

// ========== MINIMAL TECHNO ELEMENTS ==========
// HYPNOTIC LOOP - Minimal techno repetition
$: n("<<[0 ~ 7 ~] [~ 5 ~ 3]> <[0 ~ ~ 7] [5 ~ 3 ~]>>*2").scale("d:minor").trans(0)
  .s("triangle")
  .lpf(2000)
  .gain(0.3)
  .delay(0.375)  // Dotted eighth delay
  .room(0.5)
  ._pianoroll()

// ATMOSPHERIC PAD - Minimal, spacious
$: n("<[0 3 7] [5 8 12] [-2 2 5] [3 7 10]>").scale("d:minor").trans(-12)
  .s("gm_pad_2_warm")
  .lpf(800)
  .gain(0.2)
  .room(0.8)
  ._pianoroll()

// ========== MINIMAL KICK PATTERN ==========
// KICK - Sparse dubstep pattern
$: s("<<[bd:0 ~ ~ ~] [bd:0 ~ bd:0 ~] [bd:0 ~ ~ ~] [bd:0 bd:0 ~ ~]> <[bd:0 ~ ~ bd:0] [~ ~ bd:0 ~] [bd:0 ~ ~ ~] [bd:0 ~ bd:0 bd:0]>>")
  .gain(0.9)
  .lpf(70)
  .room(0.1)

// ========== MINIMAL PERCUSSION ==========
// SNARE/CLAP - Dubstep half-time feel
$: s("<<~ ~ cp:2 ~> <~ ~ cp:2 ~> <~ ~ cp:2 [~ cp:2]> <~ ~ cp:2 ~>>")
  .gain(0.5)
  .room(0.6)
  .delay(0.25)

// HI-HATS - Minimal, spacious
$: s("<<[hh:8 ~ ~ ~]*4> <[~ hh:8 ~ ~]*4> <[hh:8 ~ hh:8 ~]*2> <[~ ~ hh:8 ~]*4>>")
  .gain(0.25)
  .lpf(9000)

// OPEN HAT - Sparse accent
$: s("<<~ ~ ~ oh:3> <~ oh:3 ~ ~> <~ ~ ~ ~> <~ ~ oh:3 ~>>")
  .gain(0.3)

// ========== DUBSTEP FILLS ==========
// SNARE ROLLS - Dubstep buildups (every 4th cycle)
$: s("<<~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ [cp:2*8]> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ [cp:2*16]>>")
  .gain(0.45)
  .lpf(7000)

// CRASH - Section markers only
$: s("<<crash:3 ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <crash:3 ~ ~ ~> <crash:3 ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <crash:3 ~ ~ crash:3>>")
  .gain(0.4)
  .room(0.7)

// ========== DUBSTEP/GLITCH EFFECTS ==========
// GLITCH PERCUSSION - Minimal textural hits
$: s("<<~ ~ perc:5 ~> <~ perc:8 ~ ~> <~ ~ ~ perc:5> <perc:8 ~ ~ ~>>")
  .gain(0.3)
  .lpf(5000)
  .pan(perlin.range(0.2, 0.8))

// DEEP TOM - Dubstep impact
$: s("<<~ ~ ~ ~> <~ tom:4 ~ ~> <~ ~ ~ ~> <tom:4 ~ ~ ~>>")
  .gain(0.7)
  .lpf(200)
  .room(0.4)

// REVERSE CYMBAL - Tension builder
$: s("<<~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ [crash:5*4] ~> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ ~ ~> <~ ~ [crash:5*8] ~>>")
  .gain(0.35)
  .room(0.9)

// ========== MINIMAL NOISE TEXTURE ==========
// FILTERED NOISE - Sparse atmospheric texture
$: s("<<~ ~ ~ hiss:1> <~ ~ ~ ~> <~ ~ hiss:1 ~> <~ ~ ~ ~>>")
  .gain(0.15)
  .lpf(3000)
  .hpf(1500)
  .room(0.7)
Last updated on 16 Nov 2025
Published on 16 Nov 2025