Documentation Wiki rss-feed

Workbench Tutorial 3

In this section we will add a second audio unit instrument to the setup created in the previous section and add a new Keygroup Agent which will allow switching between the two instruments.

Open the setup saved at the end of Workbench Tutorial 2. The first step is to add a second Scaler Agent and a second Audio Unit Agent. These are created in the same way as in the previous section. Note that when you select Scaler in the create dialog, the number of the agent will automatically be shown as 2 as you already have Scaler 1 in your setup. The same applies with the Audio Unit Agent.

Configure the Audio Unit Agent in the same way as you did in Tutorial 2, and make sure that you choose a different sound or you will not be able to tell which one you are playing later in the tutorial.

Connect the Scaler 2 Agent to Audio Unit 2 Agent.

Expand the Console Mixer Agent and connect the Audio Unit 2 Agent to Mixer Channel 2.

Your setup should now look something like this.


At this point you should still be able to play Audio Unit 1. Before we introduce the Keygroup Agent, check that Audio Unit 2 can be played by deleting the connection between the Keyboard Pico Agent and Scaler 1. (Just click on the wire with the Delete Tool) and, using the Wiring Tool, make a new connection between the Keyboard Pico Agent and Scaler 2. Now the setup should look like this.


Try playing again. You should be able to hear the different sound of Audio Unit 2. If you can't, please check that you have selected a different sound in its instrument window. You can also make another connection from the Keyboard Pico Agent and connect it to Audio Unit 1. Now you should be able to hear both Audio Units playing at the same time.

Although we can switch between these two sounds by removing and creating connections, a better way is to add a new agent, the Keygroup, to the setup. Using the delete tool, remove the connections from the Keyboard Pico Agent. Then, select the create tool and create a new Keygroup Agent. Connect the Keyboard Pico Agent to the Keygroup Agent input.


We now need to connect the Keygroup Agent to the Scaler Agents. This connection is not made from top level of the Keygroup Agent, however. Expand the Keygroup Agent to show its ports and you will see one named 'output' that has a small '+' button in the top right hand corner. This button allows you to add as many outputs to the keygroup as you want. We're going to add two, to be able to switch between both Audio Units that we have created.


Click on this button (or you can click anywhere on the output port with the create tool) and you will be prompted to create a new Keygroup Output (numbered 1). Click OK and the new Keygroup ouput port will be created under the output port. Expand the output port to reveal the new port and, using the wiring tool, make a connection from it to the Scaler 1 Agent.


We now need to create another Keygroup Output to connect to the Scaler 2. So click on the button on the output port of Keygroup 1 again and click OK when you are prompted to create new Keygroup Output number 2. With the wiring tool, connect Keygroup Output 2 to Scaler 2. The setup should now look something like this.


Select the edit tool and click on the top level (title bar) of the Keygroup 1 agent. The properties window for Keygroup 1 will appear.


In this window you can see that each of the Keygroup outputs, which you just created, has an "enable" button. Try playing your Pico again and you will find that you can switch between Audio Units by toggling these "enable" buttons.

Next we need to modify the setup so that this enabling and disabling of the Keygroup Outputs can be done from a key on the Pico keyboard itself. This switching between Keygroup Outputs is carried out by a so-called "mode key". For a mode key to work, we have to make a connection from the Keyboard (or upstream Keygroup in more complicated setups) to the Mode Key Input in the Keygroup. To do this, expand the Keyboard Pico Agent and the Keygroup 1 Agent. With the wiring tool, make a connection from the Key Output port on the Keyboard Agent to the Mode Key Input port on the Keygroup Agent.


Next, we have to define which key on the keyboard to use as the mode key for Keygroup 1. This definition is made in the edit window of Keygroup 1. To display this window, click on the top-level (title bar) of the Kgroup 1 Agent with the edit tool. Scroll down the list of properties until you find "mode key row" and "mode key column". The numbers you set here will set the position of the mode key. The rows and columns on the Pico keyboard are defined as shown on this diagram. The four switches that are not eigen-keys are in a column of their own, column three.


Set the Mode Key Column to 1 and the Mode Key Row to 9 in the Keygroup 1 edit window,


this will make that key the mode key. There is nothing special about the choice of Column 1 and Row 9. You can choose any key to be the mode key. If you press the newly created mode key, the lights on all the keys on the keyboard should now flash orange.

To achieve the switching behaviour that we require, the final step is to define a key for each Keygroup Output in the Keygroup. When one of these keys is pressed while the mode key is held down the relevant Keygroup Output will be selected. Defining these keys is staightforward. Open the edit window for Keygroup 1 again. In the output section you will see that each Keygroup Output has a Key Row and Key Column setting.


So set Key Row to 1 and Key Column to 1 for Keygroup Output 1 and set Key Row to 1 and Key Column to 2 for Keygroup Output 2. The two keys in row 1 are now the keys which will select the different Keygroup Outputs when the mode key is held down. As for the mode key there is nothing special about the choice of keys at this step. You can choose any of the keys on the keyboard to be the Keygroup Output selector keys.

Try playing your Pico again. The keys should still play, except for the mode key which will cause all of the lights to go orange. If you continue to hold down the mode key after the orange lights go out, the lights on the Keygroup Output selector keys should be either green (Keygroup Output is enabled) or red (Keygroup Output is disabled). Try switching between Keygroup Outputs by holding down the mode key and pressing the key with the red light in row 1. You should find that it selects the other Keygroup Output and you will hear the output from the other Audio Unit when you play. In this way you are now able to switch between the two different sounds by simply pressing two keys on the keyboard - the mode key followed by the required Keygroup Output selector key.

Tip: A minor refinement is to note that the length of time that the keys in the keygroup stay orange after the mode key is pressed can be changed by setting the property, "blink" in the Keygroup 1 edit window. The number given here is simply the length of time in seconds. It is 0.5 by default, but a beginner may find 1 or 2 seconds less intimidating at first.

In the next tutorial we will introduce the concept of rigs to the setup. Save this setup in EigenD and give it the short tag "Workbench Tutorial 3"

Back To: Building_your_first_setup_from_scratch