Norns: development

Now that:

are published, can we have a thread for discussing these repos and general low level stuffs?


I think this would be a very good idea, perhaps in the development category?
otherwise, the norns threads are going to get dominated by dev discussions (as by nature they tend to involve multiple/lengthy replies)
…. and that may also start to fuel the feeling that norns is more for software engineers than musicians.

I had a look at the all repos last night, all seemed clear enough, and easy enough to take in different directions - hopefully, at the weekend I might get some time to build it and do some ‘extensions’.

Id be interested to hear thoughts on what @tehn would be interested pushed back (as PRs) to the repo, and what is not e.g. is alternative hardware something your interested in, or shall I keep private.
(id plan to do a bit more abstraction in places to handle this a bit better)

anyway, my current thoughts are, Ive got some ideas I want to try out with it, but might do that in a private playground, which’ll also let norns mature a bit.
It’s clear, there are lots of things the original devs want to do, perhaps before receiving PRs and suggestions, which might just lead to confusion.


@TheTechnobear currently the norns repo will run on a normal computer with linux. the experience could be “finished” by adding glue for a cairo window and virtualization of the GPIO inputs (encoders and keys). these additions would be welcomed as it’d support a large user base.

hardware-specific ports we would assess case-by-case as we need to ensure the codebase stays readable and maintainable.

in general yes, if you have improvements to share please do. i personally see the point of open source is to build on the same project, not immediately splinter off into camps.


yup, totally agree… but some developers have different opinions, or motivations for open sourcing code.

But I personally, believe not only does improves the code base (more eyes principle), but also widening the audience will attract more open source developers… so can lead to a virtuous circle.

my main interest will be different display/control services (i.e. not based on the Linux fb, as you are currently using) , and this obviously need more C/C++ code.
(so basically screen.c/h needs to be abstracted a bit)

yup, that’s cool too… a practical approach is important :slight_smile:

anyway, busy at the moment on Orac, but Im sure I can squeeze in some time - for interesting things.


Hello, I’m a developer and I own a norns. I would like to contribute, should I just grab an open issue that appeals to me in the repo? Or is there an another way you delegate tasks?

i agree with the non-spliterings and the idea that

so software fans could experiment with Lua/SC to make patches easier
the build so far was not super difficult it just needed as @ngwese offered a little direction about what and how
i have not done much with cairo except include it in the past and of course last night but a release of everything which i am sure is planned will be welcomed so those not dev savvy can contribute with their musical skills.

For example in Derel Holzer’s Vector Synthesis endevaors with pd it really needed an XY Oscilliscope “app” that made the entrance intoit joyful so i was thinking that maybe something like that for the cairo stuff in OF or something simpler would be wonderful

i am about to go pickup my physical Norns and experiment with it this weekend and i am sure i’ll have some more questions and probably wishlists or task lists very soon

1 Like

Cloned the repo and looked over the code last night. I’m still trying to sort out all the interfaces with the HW that would need to be stubbed out for a non-norns port… even on linux, it seems there are still several things beyond just the screen and buttons. (A “norns-bios” layer?!?)

I did have one thought for how to go about bringing up the environment on a system w/o the HW screen and buttons: Ship the screen image back to sclang, and use the GUI classes in SC to draw the screen, and provide on-screen controls for the three buttons and encoders. Either the bitmap itself could be passed and painted… or the Cairo primitives actually map pretty directly onto the drawing commands in SC’s Pen.


probably a question for @ngwese , how tied is Maiden to norns/lua?
Ive had a couple of projects where id like a web-browser for SC, where sclang is running on the host (which is where my midi devices are)… when I first heard of Maiden, this sounded like a possibility… then once the talk of lua started, I feared perhaps not.

thoughts? it seems generally for SC a web-based editor onto sclang could be a useful thing, perhaps a ‘spinoff’, if its not inline with norns objectives.

(note: ive not ploughed thru the maiden code yet, mostly the norns server side)

1 Like

this should be pretty simple, not requiring a lot of further abstraction, just pair of functions for creating/destroying teh cairo surface
opened issue
[ ]

1 Like

maiden is only loosely coupled to norns. Currently there are some hard coded assumptions about file types but that is likely to get addressed. The REPL only assumes that the underlying interpreters are available via websockets (and there is a static config file which it loads to learn about which ports to connect to).

There is some specific knowledge/coupling around the play button as that works by sending lua code to matron for evaluation.

Moving forward I anticipate maiden becoming more coupled to the norns ecosystem in various regards in an effort to improve the development experience. There are several areas that I’d like to explore around content sharing and potentially a project/package concept to better manage dependencies…


yes, apparently it is :slight_smile:
On my machine i only needed
and a simple
./waf configure
sudo ./waf install did the trick
i will share that nanomsg had to be compiled from source the apt-get repos i was pointing at did not have the latest one.


Answering my own question here but it looks like engine code is not present via maiden at the moment, so I assume it will be worked on in a local (non-norns) build env which will have to be built and installed over on norns.

If anyone knows whether or not I’m getting that wrong I’d appreciate the perspective.

I guess it also leads me to ask: just because the engines that ship with norns don’t seem to be accessible via maiden, can we add our own custom engines that way?

you can do it that way, or you can edit SC classes directly on the device over ssh. (we have used a combination of both approaches so far.)

currently there isn’t really a convenient and functional way to restart / recompile the SC class library, except by manually running sclang and matron processes from ssh sessions. (there is the audio.restart() method in lua, but it has drawbacks - e.g., currently doesn’t re-initialize global effect parameters and I/O levels.)

more tooling for SC development will be added, not in this next update, but probably starting in the one after that.


Thanks, this all makes sense & helps a ton. I’ll play around in there this weekend.

Per the docs (if I’m understanding them correctly), this translates to just:


followed by



1 Like

those scripts will redirect stdio from the matron and crone processes to websockets, for use by maiden.

if you want I/O on the terminal, do

cd ~/norns

in one session, and just plain old sclang in another.

[mod hat: i’m going to move these posts to the develoment thread.]

1 Like


that is, 1) create an X window, 2) use cairo_create_x11_surface()
[ ]

1 Like

When you run a Lua ‘app’ from the Norns menu, does the app run in it’s own:

  • Lua environment
  • sclang instance
  • scsynth instance

or does each app reuse the running instances?

I can see there is an audio.restart method that recompiles the class library (and effectively kicks) sclang, does that also restart scsynth too?

Maiden is a react/redux app built around the open source ace editor (also a third party lib called treebeard for the file tree pane). The go stuff is a super simple REST api for doing crud operations for the scripts/datafiles/etc.

I think it might be somewhat difficult to make the Maiden repo work with other systems, but it would probably be a great reference or starting point if you were interested in writing a react/redux web-based code editor/viewer. And it’s GPL’d so you can use the code itself, as long as wherever it’s used is also open-sourced (I think that’s the gist of GPL…I am not a lawyer disclaimer)


hi eric! check out the issues page and for what we’ve noted in terms of features and fixes, but feel free to work on anything that you yourself would find useful immediately. perhaps spend some time with the device first and see how it works for you as is. and would love to have you onboard!

for a web based sc-editor it seems almost appropriate to just start from scratch with maiden as a model. fundamentally maiden is the glue between the ace editor and the file system + norns REPL.

edit what @jlmitch5 said (also thank you @jlmitch5 for the fantastic maiden contributions)

remember ./waf configure if you’re using a fresh checkout


none of the above; rather

or does each app reuse the running instances?


I can see there is an audio.restart method that recompiles the class library (and effectively kicks) sclang , does that also restart scsynth too?

effectively yes; a local server is booted as part of the Crone startup method. (we might change this to use an explicit scsynth instance.)

right now working on some changes to make audio.restart() more useful as first step to a functioning workflow for live-editing SC components.

1 Like