Audiobus: Use your music apps together.

What is Audiobus?Audiobus is an award-winning music app for iPhone and iPad which lets you use your other music apps together. Chain effects on your favourite synth, run the output of apps or Audio Units into an app like GarageBand or Loopy, or select a different audio interface output for each app. Route MIDI between apps — drive a synth from a MIDI sequencer, or add an arpeggiator to your MIDI keyboard — or sync with your external MIDI gear. And control your entire setup from a MIDI controller.

Download on the App Store

Audiobus is the app that makes the rest of your setup better.

One Finger Orchestra Mozaic Script

245

Comments

  • @lukesleepwalker said:
    Does this script correctly save state? I had a nice thing going last night (saved in AUM) and came back this morning and it's totally different.

    Not sure. Let me do some testing and see if it keeps the last state. It might require hitting "Save" in the Mozaic UI if the knobs have been changed during your session.

  • @Jocphone said:

    @MonzoPro said:

    @Jocphone said:
    Like how this is progressing @McD

    I only had a quick play this morning before work but got a nice little piano piece going with StepBud in chord mode and BeatHawk Grand Piano. Threw in some random probabilities using Caility and modulated some velocities and echo sends with Rozeta LFO and had a fairly listenable little number going.

    The Arp and Chord channel had me foxed until I looked in the code and saw that you were dividing them be 10. WOuld be nice to have their divided value update in the label so that the user can see what channel they are really selecting.

    Otherwise, great stuff!

    What channel settings are you using in Mozaic, and inAUM?

    I am not near my iPad today but essentially I have some MIDI notes feeding into Mozaic from StepBud. MIDI Channel doesn't matter for that connection.

    Then, from Mozaic running the latest McD Orchestrator 0.9?, connect two audio channels in AUM. Each audio channel gets a synth and in its connection popup set the first to channel 1 only and the second to channel 2 only. This should get you going with the defaults for Orchestrator. If you want to tweak the ARP Channel and MIDI Channel just mute the audio channel in AUM that you don't want to hear (Arp or Chords) until the other synth is getting triggered. I don't remember what number I have set them to but @McD says he has fixed the labelling so maybe there is a new version of Orchestrator which shows the correct MIDI channel when you change the knobs in Mozaic now?

    Cheers Joc that works, I was stumped by the references to channel 0.

  • @MonzoPro said:
    Cheers Joc that works, I was stumped by the references to channel 0.

    Sorry about that. I'll change the numbering to the Channel 1-16 convention rather than the
    programmer's 0-15. Too many will follow into that trap on first use.

  • @MonzoPro said:

    @Jocphone said:

    @MonzoPro said:

    @Jocphone said:
    Like how this is progressing @McD

    I only had a quick play this morning before work but got a nice little piano piece going with StepBud in chord mode and BeatHawk Grand Piano. Threw in some random probabilities using Caility and modulated some velocities and echo sends with Rozeta LFO and had a fairly listenable little number going.

    The Arp and Chord channel had me foxed until I looked in the code and saw that you were dividing them be 10. WOuld be nice to have their divided value update in the label so that the user can see what channel they are really selecting.

    Otherwise, great stuff!

    What channel settings are you using in Mozaic, and inAUM?

    I am not near my iPad today but essentially I have some MIDI notes feeding into Mozaic from StepBud. MIDI Channel doesn't matter for that connection.

    Then, from Mozaic running the latest McD Orchestrator 0.9?, connect two audio channels in AUM. Each audio channel gets a synth and in its connection popup set the first to channel 1 only and the second to channel 2 only. This should get you going with the defaults for Orchestrator. If you want to tweak the ARP Channel and MIDI Channel just mute the audio channel in AUM that you don't want to hear (Arp or Chords) until the other synth is getting triggered. I don't remember what number I have set them to but @McD says he has fixed the labelling so maybe there is a new version of Orchestrator which shows the correct MIDI channel when you change the knobs in Mozaic now?

    Cheers Joc that works, I was stumped by the references to channel 0.

    No problem. Stumped me for a while this morning as well.

    Looking forward to some smooooth Monzo Jazz.

    Nice!

  • @McD said:

    @MonzoPro said:
    Cheers Joc that works, I was stumped by the references to channel 0.

    Sorry about that. I'll change the numbering to the Channel 1-16 convention rather than the
    programmer's 0-15. Too many will follow into that trap on first use.

    No worries, thanks for the script!

    @Jocphone said:

    @MonzoPro said:

    @Jocphone said:

    @MonzoPro said:

    @Jocphone said:
    Like how this is progressing @McD

    I only had a quick play this morning before work but got a nice little piano piece going with StepBud in chord mode and BeatHawk Grand Piano. Threw in some random probabilities using Caility and modulated some velocities and echo sends with Rozeta LFO and had a fairly listenable little number going.

    The Arp and Chord channel had me foxed until I looked in the code and saw that you were dividing them be 10. WOuld be nice to have their divided value update in the label so that the user can see what channel they are really selecting.

    Otherwise, great stuff!

    What channel settings are you using in Mozaic, and inAUM?

    I am not near my iPad today but essentially I have some MIDI notes feeding into Mozaic from StepBud. MIDI Channel doesn't matter for that connection.

    Then, from Mozaic running the latest McD Orchestrator 0.9?, connect two audio channels in AUM. Each audio channel gets a synth and in its connection popup set the first to channel 1 only and the second to channel 2 only. This should get you going with the defaults for Orchestrator. If you want to tweak the ARP Channel and MIDI Channel just mute the audio channel in AUM that you don't want to hear (Arp or Chords) until the other synth is getting triggered. I don't remember what number I have set them to but @McD says he has fixed the labelling so maybe there is a new version of Orchestrator which shows the correct MIDI channel when you change the knobs in Mozaic now?

    Cheers Joc that works, I was stumped by the references to channel 0.

    No problem. Stumped me for a while this morning as well.

    Looking forward to some smooooth Monzo Jazz.

    Nice!

    Great!

  • Version 0.93

    I changed the default channel labeling to 1 and 2 and added the capability to insert "rests"
    in Arp sequences to make more interesting rhythms.

  • @McD said:

    @lukesleepwalker said:
    Does this script correctly save state? I had a nice thing going last night (saved in AUM) and came back this morning and it's totally different.

    Not sure. Let me do some testing and see if it keeps the last state. It might require hitting "Save" in the Mozaic UI if the knobs have been changed during your session.

    Early testing shows that AUM and Mozaic coordinate to save the active state of the script
    variables/settings. If you installed an updated version then too many things are changing.
    and installing the update refreshes everything to the programmed defaults.

  • wimwim
    edited November 2019

    @McD said:

    @McD said:

    @lukesleepwalker said:
    Does this script correctly save state? I had a nice thing going last night (saved in AUM) and came back this morning and it's totally different.

    Not sure. Let me do some testing and see if it keeps the last state. It might require hitting "Save" in the Mozaic UI if the knobs have been changed during your session.

    Early testing shows that AUM and Mozaic coordinate to save the active state of the script
    variables/settings. If you installed an updated version then too many things are changing.
    and installing the update refreshes everything to the programmed defaults.

    Hi @McD, there’s a difference between “State Save” and “Preset Save”. State Saving is meant to automatically open a plugin up to the same knob positions and variables state when a host session is saved and re-opened. That’s different from saving an app preset.

    Looking at your @LoadInitState event, you’re initializing all variables every time the script loads. This will override any variable states every time it runs. The good news is there’s an easy way to avoid this. Page 12 of the current Mozaic manual explains it far better than I can. But here’s a short snippet that illustrates how the variables in your @LoadInitState event can be separated out into ones that should be initialized every time, and ones that should not be initialized because they already have values as a result of resuming a saved host session.

    @LoadInitState
    
    // check if this is a new load or resumption of a saved host session
    // we'll use a variable called "init", which would be unassigned if a new load
    
      if (Unassigned init)
        // assign something to init so this if block is skipped on resumption
        init = TRUE
    
        // proceed to initialize everything that needs to be on a new load.
        // don’t initialize run-time variables such as things that users can
        // change when running the script.
    
      endif
    
    // initialize things that should be set EVERY time outside the block above
    // these will be rare.
    
    @End
    
  • @wim said:
    Looking at your @LoadInitState event, you’re initializing all variables every time the script loads.
    @LoadInitState

    // check if this is a new load or resumption of a saved host session
    // we'll use a variable called "init", which would be unassigned if a new load

    if (Unassigned init)
    // assign something to init so this if block is skipped on resumption
    init = TRUE

    // proceed to initialize everything that needs to be on a new load

    endif

    // initialize things that should be set EVERY time outside the block above
    // these will be rare.

    @End

    Thank you for looking at the script and recommending the right solution.
    I'll try to implement this in an update.

  • It’s a great script. 👍

  • @wim said:
    It’s a great script. 👍

    It really is! Greatly enjoying this one.

  • @wim said:
    It’s a great script. 👍

    Thanks. That means a lot to me since you've crafted so many excellent Mozaic scripts.
    I knew the idea had merit from the SB script with @_Ki's and Nic's assistance. I just had to
    dig in and start learning the Mozaic commands and features. Reading your code opened
    many doors to new concepts. I'm just not the type that starts with reading the manual end to end. I get something that prints "Hello" working and just keep adding features.

    I still have a lot of ideas to implement.

    I suspect I could have followed your use of Mozaic's scale features and had a more powerful
    tool with a lot less code. But I had the vision of Sequence/Chord tables with Indexing.

  • @McD said:

    I'm just not the type that starts with reading the manual end to end. I get something that prints "Hello" working and just keep adding features.

    Me too, except that I like to give a relatively quick read, skipping over all but the most basic details before going far. My objective in this is to mainly look for why features might exist and be important. I try to tuck these things away so I have an idea where to come back to if I'm not sure how to do something. This pass also tends to trigger ideas as I naturally think about real-world ways I could use that. Kind of like walking into a tool-shed and realizing "oh! So that's how they make rounded chair legs." or "ahh, so that's how they bend iron bars".

  • So how do you insert rests in the arp?

  • @lukesleepwalker said:
    So how do you insert rests in the arp?

    I put them into the code but I could add a knob that would insert them into the sequence so users could dial in a nice rhythm using knobs.

    Thx for the idea!

  • @McD said:

    @lukesleepwalker said:
    So how do you insert rests in the arp?

    I put them into the code but I could add a knob that would insert them into the sequence so users could dial in a nice rhythm using knobs.

    Thx for the idea!

    That would be ideal. Thx for considering it.

  • @lukesleepwalker said:

    @McD said:

    @lukesleepwalker said:
    So how do you insert rests in the arp?

    I put them into the code but I could add a knob that would insert them into the sequence so users could dial in a nice rhythm using knobs.

    Thx for the idea!

    That would be ideal. Thx for considering it.

    It beats having to hand edit a huge number of patterns. I can just use the existing
    sequences and add "rest" based upon 1's and 0's.

    0xFE = 1111-1110 - skip the first pulse and play 2-8.
    0x49 = 0100-1001 - output notes on pulses 1,4,7 (skip the others).

    I can use 4 knobs and let the user dial in 16 pulse patterns to be played in a sequence.
    There's already a knob for the number of notes to play in a sequence loop 1-16.

    I like dialing in something unique from 65,000 options with a few lines of code in a loop.
    I'm not sure I would have thought of this without your question since my answer was going to be... "You don't add the rests. I have to code them." But with this approach you could.

  • @McD said:

    @lukesleepwalker said:

    @McD said:

    @lukesleepwalker said:
    So how do you insert rests in the arp?

    I put them into the code but I could add a knob that would insert them into the sequence so users could dial in a nice rhythm using knobs.

    Thx for the idea!

    That would be ideal. Thx for considering it.

    It beats having to hand edit a huge number of patterns. I can just use the existing
    sequences and add "rest" based upon 1's and 0's.

    0xFE = 1111-1110 - skip the first pulse and play 2-8.
    0x49 = 0100-1001 - output notes on pulses 1,4,7 (skip the others).

    I can use 4 knobs and let the user dial in 16 pulse patterns to be played in a sequence.
    There's already a knob for the number of notes to play in a sequence loop 1-16.

    I like dialing in something unique from 65,000 options with a few lines of code in a loop.
    I'm not sure I would have thought of this without your question since my answer was going to be... "You don't add the rests. I have to code them." But with this approach you could.

    Yes, I like the pulse knob quite a bit and think the rest knob will be equally as handy! I like the flexibility you've built into the implementation and has been fun to watch it evolve.

  • @McD Just downloaded this tonight and then proceeded to get lost in it for a good couple hours on the first go.. Nice work! 👍 There’s plenty to tweak and of course it all depends on what you feed it (note-wise) and then what it feeds.. an unexpectedly fun gift 😀.. thank you..

  • @royor said:
    @McD Just downloaded this tonight and then proceeded to get lost in it for a good couple hours on the first go.. Nice work! 👍 There’s plenty to tweak and of course it all depends on what you feed it (note-wise) and then what it feeds.. an unexpectedly fun gift 😀.. thank you.

    Thanks for the encouragement. I'm busy adding 4 "Rhythm Knobs" to insert up to 65,000 potential combinations of rests in a 16 (plus number of rests) sequence. So, the arp it should be getting funky sometime this week in update v0.95.

  • @McD said:

    @royor said:
    @McD Just downloaded this tonight and then proceeded to get lost in it for a good couple hours on the first go.. Nice work! 👍 There’s plenty to tweak and of course it all depends on what you feed it (note-wise) and then what it feeds.. an unexpectedly fun gift 😀.. thank you.

    Thanks for the encouragement. I'm busy adding 4 "Rhythm Knobs" to insert up to 65,000 potential combinations of rests in a 16 (plus number of rests) sequence. So, the arp it should be getting funky sometime this week in update v0.95.

    Have you considered implimenting a Euclidean Rhythm generator?

    https://en.wikipedia.org/wiki/Euclidean_rhythm

    One knob to generate a great number of useful rhythmic sequences. Might be a little more 'immediate'..

  • @McD said:

    @royor said:
    @McD Just downloaded this tonight and then proceeded to get lost in it for a good couple hours on the first go.. Nice work! 👍 There’s plenty to tweak and of course it all depends on what you feed it (note-wise) and then what it feeds.. an unexpectedly fun gift 😀.. thank you.

    Thanks for the encouragement. I'm busy adding 4 "Rhythm Knobs" to insert up to 65,000 potential combinations of rests in a 16 (plus number of rests) sequence. So, the arp it should be getting funky sometime this week in update v0.95.

    <3

  • I added the insertion of rests into the app controlled by 4 knobs labeled "Skip 1-4".
    They allow you to dial in an interesting syncopation. Here's a short example using
    2 Mozaic instances in sync with the Funk Drummer at BPM=80.

    Mozaic #1 = Piano
    Mozaic #2 = Bass

  • Thanks again for making me think outside the box and come up with something fun to
    tweak. I'm enjoying changing up the patterns of the arp. It's really fun to run multiple
    instances and assign the syncopated patterns to different targets. So easy to craft some
    complex textures.

  • @McD The new Rhythm enhancement sounds really cool, i am looking forward to try that out :)

  • @_ki said:
    @McD The new Rhythm enhancement sounds really cool, i am looking forward to try that out :)

    Thanks. It's getting fun.. I recorded a test with iSymphonic targeted by the Chord output on Channel 2. This one has a Sade background groove, I think.

  • @Jocphone said:
    Have you considered implimenting a Euclidean Rhythm generator?

    https://en.wikipedia.org/wiki/Euclidean_rhythm

    I will check this out and put it on my enhancement request list. If I have to code the generator myself, it's probably not in the cards. But I'll bet there are folks involved with Mosaic that could fork the script and implement it.

    If the math is trivial I might do it. The boolean math for the "Skip" knobs was fun to figure out.

    I have a lot to do just cleaning up the havoc I created with the recent updates. I added a lot of new code fast without too much testing.

  • v0.97 - I added 4 new "Skip Knobs" for the Chord Delays.

    This test drive is completely "Hands Off" using Riffer for MIDI input to the script.
    BPM = 20 and lots of "skips" to create seeming randomness.

  • @McD said:

    @Jocphone said:
    Have you considered implimenting a Euclidean Rhythm generator?

    https://en.wikipedia.org/wiki/Euclidean_rhythm

    I will check this out and put it on my enhancement request list. If I have to code the generator myself, it's probably not in the cards. But I'll bet there are folks involved with Mosaic that could fork the script and implement it.

    If the math is trivial I might do it. The boolean math for the "Skip" knobs was fun to figure out.

    I have a lot to do just cleaning up the havoc I created with the recent updates. I added a lot of new code fast without too much testing.

    Unfortunately I don't have time to help with this until next week possibly. But if anyone fancies the challenge in the meantime, here is an implimentation of the Euclidean Rhythm generator in JavaScript:

    module.exports = function (onNotes, totalNotes) {
      var groups = [];
      for (var i = 0; i < totalNotes; i++) groups.push([Number(i < onNotes)]);
    
      var l;
      while (l = groups.length - 1) {
        var start = 0, first = groups[0];
        while (start < l && compareArrays(first, groups[start])) start++;
        if (start === l) break;
    
        var end = l, last = groups[l];
        while (end > 0 && compareArrays(last, groups[end])) end--;
        if (end === 0) break;
    
        var count = Math.min(start, l - end);
        groups = groups
          .slice(0, count)
          .map(function (group, i) { return group.concat(groups[l - i]); })
          .concat(groups.slice(count, -count));
      }
      return [].concat.apply([], groups);
    };
    
    function compareArrays (a, b) {
      // TODO: optimize
      return JSON.stringify(a) === JSON.stringify(b);
    };
    
  • McDMcD
    edited November 2019

    @Jocphone said:
    Have you considered implimenting a Euclidean Rhythm generator?
    @McD replied:
    If the math is trivial I might do it.

    OK. The Math is NOT trivial.

Sign In or Register to comment.