Norns: dust

norns

#254

very much looking forward to playing with the new scripts and engines in the upcoming release


#255

super excited about all of the new scripts and engines! they’re amazing

doing final testing and packing up. realistically won’t be ready until tomorrow morn.

heads up to anyone manually git-pulling in dust changes: you also need to pull norns and recompile via ./waf configure; ./waf (!)


#256

moderators please correct me if this is in the wrong place, but I just fired up the new update and gave cranes a spin, and holy cow @Dan_Derks it’s fantastic! so simple to use but this was literally the first thing I created off the bat using just a Juno-6 into Cranes, processed by BIM, and BAM.


#258

holy cow, indeed! but really, holy cow @n-So! that sounds marvelous — thank you so much for sharing it. i love the juno swells against the pitch bumps. please send any feedback about usability or wish list!


#259

After an update, my dust repo on device has some modifications that I have to address before I can use git.

On branch master
Your branch is behind 'origin/master' by 325 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)
Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

	modified:   docs/index.md
	modified:   lib/lua/er.lua
	modified:   lib/lua/gridbuf.lua
	modified:   lib/lua/jah/ack.lua
	modified:   lib/lua/jah/formatters.lua
	modified:   lib/sc/Engine_Ack.sc
	modified:   lib/sc/Engine_Glut.sc
	modified:   lib/sc/Engine_PolyPerc.sc
	modified:   readme.md
	modified:   scripts/artfwo/flin.lua
	modified:   scripts/artfwo/glut.lua
	deleted:    scripts/emb/elcos.lua
	deleted:    scripts/emb/invocer.lua
	modified:   scripts/emb/loops.lua
	modified:   scripts/jah/hello_ack.lua
	modified:   scripts/jah/step.lua
	modified:   scripts/study/16sliders.lua
	modified:   scripts/study/param.lua
	modified:   scripts/tehn/awake.lua
	modified:   scripts/tehn/earthsea.lua
	modified:   scripts/tehn/mlr.lua
	modified:   scripts/tehn/playfair.lua

Executing git pull results in the following.

we@norns:~/dust $ git pull
Updating 49d3b9a..cc71bc6
error: Your local changes to the following files would be overwritten by merge:
	docs/index.md
	lib/lua/er.lua
	lib/lua/gridbuf.lua
	lib/lua/jah/ack.lua
	lib/lua/jah/formatters.lua
	lib/sc/Engine_Ack.sc
	lib/sc/Engine_Glut.sc
	lib/sc/Engine_PolyPerc.sc
	readme.md
	scripts/artfwo/flin.lua
	scripts/artfwo/glut.lua
	scripts/emb/loops.lua
	scripts/jah/hello_ack.lua
	scripts/jah/step.lua
	scripts/study/16sliders.lua
	scripts/study/param.lua
	scripts/tehn/awake.lua
	scripts/tehn/earthsea.lua
	scripts/tehn/mlr.lua
	scripts/tehn/playfair.lua
Please commit your changes or stash them before you merge.
error: The following untracked working tree files would be overwritten by merge:
	LICENSE
	data/jah/step.pset
	data/tehn/awake.pset
	data/tehn/earthsea.pset
	data/tehn/playfair.pset
	data/tyler/ekombi.data
	data/tyler/ekombi.pset
	docs/jah/ack/index.md
	docs/jah/gong/index.md
	docs/jah/hello_ack/index.md
	docs/jah/hello_gong/index.md
	docs/jah/step/index.md
	docs/justmat/foulplay/FP_grid.png
	docs/justmat/foulplay/foulplay.md
	docs/mark_eats/lib/index.html
	docs/mark_eats/lib/ldoc.css
	docs/mark_eats/lib/modules/EnvGraph.html
	docs/mark_eats/lib/modules/Graph.html
	docs/mark_eats/lib/modules/MusicUtil.html
	docs/mark_eats/lib/modules/UI.html
	docs/mark_eats/loom/loom-ideas.png
	docs/tehn/awake/index.md
	docs/tehn/mlr/index.md
	docs/tehn/mlr/mlr.ai
	docs/tehn/mlr/mlr.png
	lib/lua/beatclock.lua
	lib/lua/jah/bob.lua
	lib/lua/jah/gong.lua
	lib/lua/jah/shift.lua
	lib/lua/mark_eats/envgraph.lua
	lib/lua/mark_eats/formatters.lua
	lib/lua/mark_eats/graph.lua
	lib/lua/mark_eats/mollythepoly.lua
	lib/lua/mark_eats/musicutil.lua
	lib/lua/mark_eats/passersby.lua
	lib/lua/mark_eats/ui.lua
	lib/sc/Engine_Bob.sc
	lib/sc/Engine_Gong.sc
	lib/sc/Engine_KarplusRings.sc
	lib/sc/Engine_MollyThePoly.sc
	lib/sc/Engine_Passersby.sc
	lib/sc/Engine_PolySub.sc
	lib/sc/Engine_Shift.sc
	lib/sc/Engine_SoftCut.sc
	lib/sc/abstractions/AudioTaper.sc
	lib/sc/abstractions/BufUtil.sc
	lib/sc/abstractions/CroneGenEngine.sc
	lib/sc/abstractions/PatchMatrix.sc
	lib/sc/abstractions/SoftCutVoice.sc
	lib/sc/abstractions/SoftRecord.sc
	scripts/M4R71N/ANDR.lua
	scripts/burn/kayan.lua
	scripts/declutter/boingg.lua
	scripts/dndrks/cranes.lua
	scripts/jah/bob.lua
	scripts/jah/hello_gong.lua
	scripts/jah/shifty.lua
	scripts/justmat/foulplay.lua
	scripts/justmat/paths.lua
	scripts/mark_eats/graph_demo.lua
	scripts/mark_eats/loom.lua
	scripts/mark_eats/molly_the_poly.lua
	scripts/mark_eats/passersby.lua
	scripts/mark_eats/scales_demo.lua
	scripts/mhetrick/easygrain.lua
	scripts/mhetrick/wormhole.lua
	scripts/nf/rebound.lua
	scripts/olivier/oblique_strategies.lua
	scripts/speakerdamage/channel_changer.lua
	scripts/study/study1.lua
	scripts/study/study2.lua
	scripts/study/study3.lua
	scripts/tehn/halfsecond.lua
	scripts/tyler/ekombi.lua
Please move or remove them before you merge.
Aborting

My hack is to rename the ~/dust repo to ~/dust.bak and clone a new copy from origin. This appears to have the side effect of removing audio recordings and scripts created via the file manager in Maiden.


#260

Molly The Poly is awesome and totally relevant to what I’m working on! Thanks @markeats

Reading over the SC implementation. I’m in a similar boat of exposing dozens of parameters and providing a capability to randomize sets of them.


#261

Cool! For both engines I’ve worked on I handled all the randomisation etc on the lua side in a lib which I found a convenient way of doing it.


#262

Just read over the Lua side and I like your convention. The device script only deals with “device stuff” like the screen, encoders, midi, etc and the library does “synth stuff” like control sets and params. I’m gonna port my stuff to work that way.

On the SuperCollider side, good thing I know my text editor well because dang…doing a lot of copy + paste to expose 32 params in a 6x6 matrix :slight_smile:

It could be nice to have some kind of way to do a loop over a collection in the {arg foo; ... } part of a SynthDef.


#263

Hello! I am a total newbie in the new Monome world and have no programming knowledge (sorry). I am about to go the Monome & Norns route and got two questions concerning the scripts:

  • Is the MLR midi out already working properly?
  • Can you save your recordings/projects/patterns in those new scripts, e.g. in Cranes or MLR? I haven’t found any info on this.

As I am new to this forum, please correct me if this question should fall in another category.
Any help or info is welcome!!
cheers!


#264

hi @Trigga

you can record audio output direct-to-disk using the TAPE method.

right now most scripts don’t have extensive saving options. some of the sequencer-like scripts do.

mlr does have midi sync output. it does not yet have facilities to save recored clips or “scenes” (that is forthcoming)


#265

thanks for the swift reply! sounds like great future plans!


#266

@lazzarello you can use arrays and array arguments in synthdefs, though there are some limitations. see the help files for SynthDef, Mulltichannel Expansion, Mix, &c.

here’s an example with 3 sinewaves in a phase-modulation loop. (feedback provided by LocalIn/LocalOut.)
demonstrates:

  • array arguments (for freq, mod index, and delay time)
  • building and using arrays of ugens programatically in the synthdef

note the use of the array literal notation (#[])

(warning: gets noisy)

Routine {
	SynthDef.new(\fm3, {
		arg out=0, amp=0.05,
		freqs = #[110, 220, 330],
		mods = #[0.1, 0,1, 0.1],
		delays = #[0.001, 0.001, 0.001],
		freqlag = 0.1, modlag=0.1, delaylag=0.1;

		var mod_in;
		var mod_out;
		var sins;

		mod_in = LocalIn.ar(3);
		sins = freqs.collect({ arg f, i;
			SinOsc.ar(Lag.kr(freqs[i], freqlag), mod_in[(i+1)%3] * Lag.kr(mods[i], modlag))
		});

		mod_out = sins.collect({ arg sin, i;
			DelayC.ar(sin, 0.2, Lag.kr(delays[i], delaylag))
		});
		LocalOut.ar(mod_out);

		Out.ar(out, amp * Mix.new(sins));
	}).send(s);

	s.sync;
	x = Synth.new(\fm3);

	// command-period to stop!
	inf.do ({
		(1 + 1.0.rand).wait;
		x.set(\freqs, Array.fill(3, {200 + 200.rand}).postln);
		x.set(\mods, Array.fill(3, { 2.0.rand}).postln);
		x.set(\delays, Array.fill(3, {0.1.rand}).postln);
	})
}.play;

#267

Weird Lua syntax stuff in my FM7 adventure.

I’m referencing the lib/mark_eats/mollythepoly.lua library. I didn’t recognize a syntax for adding key/value pairs to a table. It looks like this

params:add{type = "control", id = "pulse_width_mod", name = "Pulse Width Mod", controlspec = specs.PW_MOD, action = engine.pwMod}

I got the same results with two lines I recognized from some tutorials, like so

params:add_control("pulse_width_mod","Pulse Width Mod", controlspec.new(0, 1, "lin", 0, 0.2, ""))
params:set_action("pulse_width_mod", function(x) engine.pwMod(x) end)

I thought I’d test what I think are the semantics so I did this and got an exception on the first try.

foo = {}
<ok>
foo{type = "control", id = "wtf?"}
lua: stdin:1: attempt to call a table value (global 'foo')
stack traceback:
	stdin:1: in main chunk

Do tables get an add method by default? It appears not. What’s going on here?

foo:add{type = "control", id = "wtf?"}
lua: stdin:1: attempt to call a nil value (method 'add')
stack traceback:
	stdin:1: in main chunk

#268

because that’s not what that is. :add is a method of the paramset class (in paramset.lua) of which the global params is an instance.

this would work if foo was a function with a single argument (a table). in lua, you can omit the parens in a fn call if the fn has only one argument


#269

Woah, h4x. That’s pretty clever, though in no way intuitive. It def cuts down on the number of lines for UI stuff.


#270

see here re params syntax: Norns: update 181002

furthermore:

some_function({element1=345, ish="whatever"})

is the same as

some_function{element1=345, ish="whatever"}

fancy lua-jazz


#271

I changed the code in a library. How do I reload Lua libraries in the path lib/lua/mydir/foo.lua?

I tried loading a new script and reloading the one that requires this library. The code changes are not on the device (they expose new params). I restarted the audio engine. Still no change. I loaded the code from a script through Maiden. No new params. I rebooted…new params. :frowning:

Any way to force reload libraries without rebooting?


#272

you have to muck with the package cache directly. i did this enough a while back that i stuck it in a util:

using this you could reload your lib like this:

local my_lib = reload('my_lib')

(note this won’t follow transitive dependencies so you need to explicitly reload everything that’s changed.)


#273

I did it!

PR for FM7 created

FM7 is a Norns interface for the FM7 UGen, a phase modulation oscillator matrix. This is an MVP release. The engine is a 16 voice polyphonic synthesizer.

Notable features.

  • Device UI displays 6x6 modulation matrix and which of the 6 operators are output to audio
  • Key 2 for random modulation matrix + carrier output
  • Key 3 for random note event
  • Encoders 1 - 3 change operator 1 frequency multiplier, phase, amplitude (pre output)
  • Grid in Earthsea sequencer mode
  • Grid keys toggle encoders 1 - 3 to change operator 2 - 6
  • All params exposed via PARAMETERS menu
  • MIDI!
  • OSC for all params should “just work” as of norns v1.1.0

Thanks to @catfact , @tehn , @markwheeler , @pq and @junklight for Norns/Lua/SC help.

Special thanks to Stefan Kersten who made the FM7 UGen over 10 years ago.


#274

just having a play - this is really cool

obviously I now want changes: needs operator envelops and midi pitch bend :wink:

is there any way of editing the mod matrix? or do we just get to cycle around random things?

All those niggles apart this is an amazing basis - I’m going to use this as a basis for my multi-timbral project and it will help with the FM idea I had (more of an experiment - no idea if it will make anything musically useful but I’ll share it if it does)

(edit - nowhere near as noisy as my old FM7 (that I sadly lost in a house move) though… :wink: )