JASS Wiring Patch Example


Time to wrap things up for a while. This will be the last entry for the JASS synth, until I come up with an excuse to write about it again. I’m hoping that someone else will look at the code and decide to make it more “Java compliant”, and maybe point out ways of making improvements to the FFT section, or overall playback.  Enjoy. In the meantime, here’s the “patch” for my equivalent of an old Moog synth.

// This is a wiring patch for the JASS (Java ADSR Software Synth) app.
// It contains:
//     3 VCOs (voltage controlled oscillators)
//     2 Benders, for shifting frequencies of VCO 2 and 3, based on the VCO 1 frequency
//     1 Gate oscillator, for driving the circuit if the A-300 keyboard isn’t connected
//     2 Noise generator (configured to run during the ADSR attack, decay and release phases)
//     1 ADRS
//     3 mixers for allowing multiple connections to 1 input pin
//     2 Splitters, for allowing multiple connections from one output pin
//     1 VCF (voltage controlled filter)
//     1 Pan module
//     1 echo module for reverb
//     1 VCA (voltage controlled amplifier) as the main sound amp
//     1 arp (arperggiator) module for running note patterns
//
// https://threestepsoverjapan.wordpress.com/
//
///////////////////////////////////////////////////////////////////////////////////

// Create the new modules.

new osc osc1 (100, 0, 0.5, true, 0)
pin (50, 1000, 512, 256, Freq.,    freq)
pin (0,     4,   4,   0, Waveform, waveform)
pin (0.0, 1.0, 100,  49, Ratio,    ratio)
pin (0,    50,  50,   0, Glide Smoothness, smooth)
pin (0,    50,  50,   0, Glide Width,      width)
pin (0,     1,   1,   1, Enable Glide,     enableGlide)
pin (0,     1,   1,   1, Gate,             gate)

new osc osc2 (100, 0, 0.5, true, 0)
pin (50, 1000, 512, 256, Freq.,    freq)
pin (0,     4,   4,   0, Waveform, waveform)
pin (0.0, 1.0, 100,  49, Ratio,    ratio)
pin (0,    50,  50,   0, Glide Smoothness, smooth)
pin (0,    50,  50,   0, Glide Width,      width)
pin (0,     1,   1,   1, Enable Glide,     enableGlide)
pin (0,     1,   1,   1, Gate,             gate)

new Bender bender1 (1.0)
pin (-2.0,  2.0, 400, 199, Offset, offset)

new osc osc3 (100, 0, 0.5, true, 0)
pin (50, 1000, 512, 256, Freq.,    freq)
pin (0,     4,   4,   0, Waveform, waveform)
pin (0.0, 1.0, 100,  49, Ratio,    ratio)
pin (0,    50,  50,   0, Glide Smoothness, smooth)
pin (0,    50,  50,   0, Glide Width,      width)
pin (0,     1,   1,   1, Enable Glide,     enableGlide)
pin (0,     1,   1,   1, Gate,             gate)
new Bender bender2 (1.0)
pin (-2.0,  2.0, 400, 199, Offset, offset)

new osc gate1 (20, 1, 0.5, true, 2)
pin (0.1,  20, 100,   3, Freq.,    freq)
pin (0,     4,   4,   1, Waveform, waveform)
pin (0.0, 1.0, 100,  49, Ratio,    ratio)
pin (0,    50,  50,   0, Glide Smoothness, smooth)
pin (0,    50,  50,   0, Glide Width,      width)
pin (0,     1,   1,   0, Enable Glide,     enableGlide)
pin (0,     1,   1,   1, Gate,             gate)

new Splitter freqSplitter (2, 0)

new mixer adsrMixer (4, 1.0, 0)
pin (0.0,   3, 100,  60, Avg. Comp., comp)

new vca mainAmp (16000, 0.0)
pin (0, 16000, 512, 256, Amp., amp)
pin (-2.0, 2.0, 100, 49, Offset, offset)

new ADSR adsr1 (4000, 4000, 0.4, 4000)
pin (0, 8000, 512, 255, Attack,   attack)
pin (0,  600, 100,  10, Punch,    punch)
pin (0, 8000, 512, 255, Decay,    decay)
pin (0,  1.0, 400, 200, Sustain,  sustain)
pin (0, 8000, 512, 255, Attack2,  attack2)
pin (0,  1.0, 400, 200, Sustain2, sustain2)
pin (0, 8000, 512, 255, Release,  release)
pin (0,    1,   1,   0, Invert,   invert)
pin (0,    1,   1,   1, Gate,     gate)

new mixer gateMixer (2, 1.0, 2)

new VCF vcf1 (512, 0, 500, 0.5)
pin (0,   512, 512, 512, Cutoff,   filterLevel)
pin (0,    2,   2,   0, Mode,      mode)
pin (0,    7, 512, 256, Threshold, threshold)
pin (0,  1.0, 100,  50, Mult.,     mult)
pin (0,    1,   1,   1, Filter On, filterOn)

new Splitter echoSplitter (2, 0)

new mixer echoMixer (2, 1.0, 0)
pin (0.0,   3, 100,  60, Avg. Comp., comp)

new Echo echo1 (32000, 0.5, 0.75, 0, 1)
pin (100, 32000, 512, 255, Loop Length, loop)
pin (0.0,   1.0, 100,  49, Delay Max.,  delay)
pin (0.0,   1.0, 100,  49, Decay,       decay)
pin (0,       1,   1,   0, Mode,        mode)
pin (0,       1,   1,   1, echoOn,      echoOn)

new mixer noiseMixer (3, 0.0, 3)

new noise noise1 (0, 10, 0.4)
pin (0,   3,   3,  0, Mode,          mode)
pin (0, 100, 100, 10, Density,       density)
pin (1, 100,  99, 49, Brownian Max., brownian)
pin (0, 1.0, 100, 20, Volume,        amp)
pin (0,   1,   1,  1, Gate,          gate)

new Pan pan1 (true, 0.5, 1.0, 0.5)
pin (0.1, 10, 100, 10, Pan Rate,     rate)
pin (0,    4,   4,  0, Pan Waveform, waveform)
pin (0,  1.0, 100,  49, Magnitude,   mag)
pin (0,  1.0, 100,  49, Offset,      offset)
pin (0,    1,   1,   1, panOn,       panOn)

new Arp arp1 (1, 2.0, 0.5, true)
pin (0.1,   10, 100,  10, Arp Rate,     rate)
pin (0.01, 1.0, 100, 100, Arp Ratio,    ratio)
pin (   1,   5,   4,   0, Note Steps,    step)
pin (   0,   1,   1,   0, Note Gate,    noteGate)
pin (   0,   1,   1,   0, Master Gate,  masterGate)
pin (0,    4,   4 ,  0, Pattern,      pattern)
pin (0,    1,   1,   1, Enable,      gate)

// The next section sets up the patch.
// Specify wiring to the fixed pins.

connect kbd.note osc1.freq
connect kbd.gate gateMixer.1
connect kbd.pitch osc1.pitchBend
connect kbd.touch osc1.touchIn
connect arp1.out kbd.arp

// Specify wiring between modules.

connect gate1.gateOut gateMixer.2
connect gateMixer.out adsr1.gate
connect osc1.out adsrMixer.1
connect osc1.getFreq freqSplitter.in
connect freqSplitter.1 bender1.freqIn
connect bender1.out osc2.freq
connect osc2.out adsrMixer.2
connect freqSplitter.2 bender2.freqIn
connect bender2.out osc3.freq
connect osc3.out adsrMixer.3
connect adsrMixer.out adsr1.in
connect adsr1.attackE noiseMixer.1
connect adsr1.decayE noiseMixer.2
connect adsr1.releaseE noiseMixer.3
connect noiseMixer.out noise1.gate
connect noise1.out adsrMixer.4
connect adsr1.out echoSplitter.in
connect echoSplitter.1 echoMixer.1
connect echoSplitter.2 echo1.in
connect echo1.out echoMixer.2
connect echoMixer.out mainAmp.in
connect mainAmp.out box.fixed

// Specify wiring from the sliders and dials to the module input pins.

connect Control.0 mainAmp.amp
connect Control.1 osc1.waveform
connect Control.2 bender1.offset
connect Control.3 bender2.offset
connect Control.4 adsr1.attack
connect Control.5 adsr1.decay
connect Control.6 adsr1.sustain
connect Control.7 adsr1.release
connect Control.8 echo1.loop
connect Control.9 echo1.delay
connect Control.10 echo1.decay
connect Control.11 osc1.smooth
connect Control.12 osc1.width
connect Control.13 osc2.waveform
connect Control.14 osc3.waveform
connect Control.15 noise1.density
connect Control.16 noise1.amp
connect Control.17 pan1.rate
connect Control.18 pan1.mag
connect Control.26 echo1.toggle
connect Control.27 vcf1.toggle
connect Control.28 noise1.toggle
connect Control.29 pan1.toggle

// Specify the module “pin” settings. This is part of the actual patch.
// Format: setting moduleName pinName sliderValue rawData

setting osc1 freq 51 144.63
setting osc1 waveform 0 0
setting osc1 ratio 54 0.54
setting osc1 smooth 10 10
setting osc1 width 10 10
setting osc1 enableGlide 1 1
setting osc1 gate 1 1
setting osc2 freq 198 417.38
setting osc2 waveform 0 0
setting osc2 ratio 49 0.49
setting osc2 smooth 10 10
setting osc2 width 10 10
setting osc2 enableGlide 1 1
setting osc2 gate 1 1
setting bender1 offset 141 -0.59
setting osc3 freq 256 525
setting osc3 waveform 0 0
setting osc3 ratio 9 0.09
setting osc3 smooth 10 10
setting osc3 width 10 10
setting osc3 enableGlide 1 1
setting osc3 gate 1 1
setting bender2 offset 170 -0.3
setting gate1 freq 0 0.1
setting gate1 waveform 1 1
setting gate1 ratio 95 0.95
setting gate1 smooth 0 0
setting gate1 width 0 0
setting gate1 enableGlide 0 0
setting gate1 gate 1 1
setting adsrMixer comp 60 1.8
setting mainAmp amp 419 13093.75
setting mainAmp offset 49 -0.04
setting adsr1 attack 113 1765.62
setting adsr1 punch 10 60
setting adsr1 decay 124 1937.5
setting adsr1 sustain 309 0.77
setting adsr1 attack2 0 0
setting adsr1 sustain2 0 0
setting adsr1 release 323 5046.88
setting adsr1 invert 0 0
setting adsr1 gate 1 1
setting vcf1 filterLevel 512 512
setting vcf1 mode 0 0
setting vcf1 threshold 287 3.92
setting vcf1 mult 39 0.39
setting vcf1 filterOn 1 1
setting echoMixer comp 54 1.62
setting echo1 loop 92 5832.03
setting echo1 delay 30 0.3
setting echo1 decay 11 0.11
setting echo1 mode 0 0
setting echo1 echoOn 0 0
setting noise1 mode 0 0
setting noise1 density 19 19
setting noise1 brownian 65 66
setting noise1 amp 4 0.04
setting noise1 gate 1 1
setting pan1 rate 12 1.29
setting pan1 waveform 0 0
setting pan1 mag 86 0.86
setting pan1 offset 7 0.07
setting pan1 panOn 0 0
setting arp1 rate 20 2.08
setting arp1 ratio 49 0.5
setting arp1 step 1 2
setting arp1 noteGate 0 0
setting arp1 masterGate 1 1
setting arp1 pattern 1 1
setting arp1 gate 1 1

Advertisements
Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: