Skip to content

Instantly share code, notes, and snippets.

@dndrks
dndrks / user_script.lua
Created May 14, 2022
cheat codes user script boilerplate
View user_script.lua
-- required container, do not change this:
local user_script = {}
-- this function is called whenever a loaded collection
-- has a 'user_script.lua' file in the collection:
function user_script.init()
print("hello from the user script")
end
-- this function is called whenever the transport starts:
@dndrks
dndrks / user_script.lua
Last active May 14, 2022
cheat codes user script: pad sequencer example
View user_script.lua
-- cheat codes user script: pad sequencer example
-- required container, do not change this:
local user_script = {}
my_pads = {} -- use unique variables to reduce conflicts with the rest of cheat codes
-- this function is called whenever a loaded collection has a 'user_script.lua' file in the collection:
function user_script.init()
@dndrks
dndrks / user_script.lua
Last active May 14, 2022
cheat codes user script: delay sequencer example
View user_script.lua
-- cheat codes user script: delay sequencer example
-- required container, do not change this:
local user_script = {}
my_delays = {} -- use unique variables to reduce conflicts with the rest of cheat codes
-- this function is called whenever a loaded collection has a 'user_script.lua' file in the collection:
function user_script.init()
@dndrks
dndrks / Engine_BloopDrum.sc
Last active Nov 17, 2021
a simple drum synth
View Engine_BloopDrum.sc
Engine_BloopDrum : CroneEngine {
var pg; // pg is a "parallel group", see the alloc ~20 lines down
*new { arg context, doneCallback;
^super.new(context, doneCallback);
}
alloc {
pg = ParGroup.tail(context.xg);
@dndrks
dndrks / usb-tape-copy.lua
Last active Nov 26, 2021
norns USB TAPE copy
View usb-tape-copy.lua
-- USB tape copy
--
-- * attach a USB drive
-- * choose a TAPE, press K3:
-- * copy
-- * copy+delete
-- * delete
--
-- if you see "NO USB DETECTED",
-- reconnect and wait a minute
@dndrks
dndrks / midimatrix.lua
Last active Nov 3, 2020
example midi matrix
View midimatrix.lua
box = {} -- a table of boxes
msg =
{
["cc"] = {"cc","val","ch"}
, ["note_on"] = {"note","vel","ch"}
, ["note_off"] = {"note","vel","ch"}
, ["key_pressure"] = {"note","val","ch"}
, ["pitchbend"] = {"val","ch",nil}
, ["channel_pressure"] = {"val","ch",nil}
@dndrks
dndrks / cranes-200823.lua
Last active Aug 24, 2020
cranes-refactor
View cranes-200823.lua
-- cranes
-- dual looper / delay
-- (grid optional)
-- v2.14 @dan_derks
-- https://llllllll.co/t/21207
-- ---------------------
-- to start:
-- press key 2 to rec.
-- sounds are written to
-- two buffers.
View patchwork-abstract.lua
--
-- PATCHWORK (v2.0)
--
-- Dual sequencer for
-- norns, grid + crow
-- @olivier
-- llllllll.co/t/patchwork/28800
--
-- See full documentation
-- in library post on lines
View patchwork-midi.lua
--
-- PATCHWORK (v1.0.1)
--
-- Dual sequencer for
-- norns, grid + crow
-- @olivier
-- llllllll.co/t/patchwork/28800
--
-- See full documentation
-- in library post on lines
View physical-clock.lua
-- physical: clock edition
-- norns study 4
--
-- grid controls arpeggio
-- midi controls root note
-- ENC1 = bpm
-- ENC2 = divisor
-- ENC3 = scale
-- KEY2 = hold
-- KEY3 = restart sequence