Skip to content

Instantly share code, notes, and snippets.

@hsitz
hsitz / acc2-translate-mozaic.txt
Last active March 11, 2020 17:56
new version
@OnLoad
counter = 0
chordtype=0
FillArray chordnote, -1, 10
FillArray note_is_on, NO, 72
DIM=1
MAJ=2
MIN=3
SEVENTH=4
@End
@hsitz
hsitz / acc-translate-mozaic.txt
Last active March 11, 2020 19:20
mozaic translation of accordion buttons
@OnLoad
log { code version 0.1 }
counter = 0
chordtype=0
FillArray chordnote, -1, 10
FillArray note_is_on, NO, 100
DIM=1
MAJ=2
MIN=3
SEVENTH=4
@hsitz
hsitz / fbfly-noc.txt
Last active March 13, 2020 03:38
fbfly-nocomments
@OnMidiNote
  note = MIDIByte2
  button_col =  1 + ( div (59-(note-40)), 3)
  note = 4 + ((button_col-1) * 7)
  note = 12 + (note % 12)
  c = button_col    // just to save typing
@hsitz
hsitz / FB-to-fly-system.txt
Last active March 13, 2020 23:16
fly stem from Free Bass
// v. 0.1
// fixed several remaining note pairs that
// were sounding an octave too high,
// revised logging
@OnMidiNote
  note = MIDIByte2
  // notes in row 3 thru 5 have values
@hsitz
hsitz / filteroffs
Last active April 8, 2020 18:39
save all midi note offs until last key's
@OnLoad
counter = 0
fillarray noteoffs, 20, 0
fillarray channels, 20, 0
suppressed = 0
@END
@OnMidiNoteOn
inc counter
sendmidithru
@OnLoad
fillarray counter, 0, 20
@END
@OnMidiNoteOn
inc counter[midichannel]
sendmidithru
@END
@OnMidiNoteOff
@OnLoad
// counter will hold the
// humber of currently-held notes for each channel
fillarray counter, 0, 10
// each channel's saved notes are put in noteoffs array
// starting at offset of 40 * [their channel #]
fillarray noteoffs, 0
// save_cnt will count how many notes
// are being saved for each channel
fillarray save_cnt, 0, 10
@OnLoad
fillarray counter, 0, 20
@END
@OnMidiNoteOn
inc counter[midichannel]
sendmidithru
@END
@OnMidiNoteOff
@hsitz
hsitz / accrun.txt
Last active April 13, 2020 01:52
bassnoteruns
@OnLoad
// on_notes array will record the note
// that is actually played for
// any given note value.
// e.g., if note 60 is pressed
// but it is offset to 72
// then on_notes[60] will be 72.
fillarray on_notes, 0, 129
lastnote=0
lnote = 0
@OnLoad
// on_notes array will record the note
// that is actually played for
// any given note value.
// e.g., if note 60 is pressed
// but it is offset to 72
// then on_notes[60] will be 72.
fillarray on_notes, 0, 129
lastnote=0
lnote = 0