Bob@Pangolin
Staff member
Want to learn how to connect your MIDI device to BEYOND with PangoScript?
There are a lot of PangoScript commands that you can use in combination with MIDI. Using the power of PangoScript and the other features of BEYOND,
we made it possible to use almost every MIDI device that is out there!
You can find a list of commands within the PangoScript editor that is built into BEYOND.
To make it easy during the programming process, we advise you to open one of the MIDI monitors that are build into BEYOND.
(can be opened by following the menu : View >> Show Midi Monitor)
(can be enabled in the configuration of beyond : Settings >> Configuration >> Preview Window)
(can be viewed when opening your midi device configuration)
You can easily, turn a dial, press a button, or move an slider to jump to the corresponding line in the Script Editor. You will notice that it will match the same address as shown in the MIDI monitor.
So how do I use it?
In the first examples, I will set the brightness in various ways.
You can replace brightness with other functions, but I will keep it simple for now. The Script editor always shows the functions that are available in the version you are using.
For my examples we will use the script:
This function controls the brightness of all zones.
The above example shows an absolute statement.
The statement is 100. 100% in this case.
The text behind the // is for quick reference and is not needed for scripting.
We recommend you place separate commands onto separate lines in the editor.
There is no need to put a line termination character (such as ; ) at the end of a line.
If you are accustomed to doing that because of C or Pascal programming, that is okay, and the script editor will not mind, but it is not needed.
We will start with a MIDI button.
When you have opened the MIDI window of your device, press a button to jump to the line that controls the button you want to program.
Double click the empty line to open the editor.
(note that some buttons have 2 states, on and off. Choose ON in most cases)
I want this MIDI button to set my brightness of all my zones to 50%, so I enter the following line in the script editor
Close the editor, the button is programmed and thats all there is to it!
For an encoder or slider we need to change the script a bit.
A normal slider or encoder changes MIDI commands from 00 till 7F, so if you want to assign the master brightness to it, you need to enter the following code:
Close the editor, and thats it.
What we just have done is this; we want brightness, and we want to control it from 0% to 100%.
As we don't want to enter long lines of code to reprogram a controller, we use the statement ExtValue (minimum,maximum).
ExtValue can be used with almost any function that uses values.
Except for functions with On, Of or Toggle as value. (These values are made for assignment to buttons or usage within a script it self.)
We could also say that we want to control the brightness only from 10 to 100%. This is easily done by changing the script to:
Easy as pie
If I had used the function "AngleY 0 // degree" in my examples, then I could have used the scipt "AngleY ExtValue (-360,360)" to control the Y angle on a slider or encoder.
But what if you only want to control the brightness of only the first zone?
We have to extend the script a bit:
ControlZone defines the parameter that you want to control and on the next line you enter the function you want to change.
You could also do this, to control 3 zones;
As long as you put every command on a new line, the function will be used.
Encoders which have only two states:
If you have an encoder that has only sends out 2 values (shown in the midi editor as 00 and 7F), and you want to control brightness with it use the following command:
This adds one, and removes 1, as soon as you rotate the encoder in various ways.
So now you know how to program an button, to program an encoder and an slider with your own preferred commands.
There are a lot of PangoScript commands that you can use in combination with MIDI. Using the power of PangoScript and the other features of BEYOND,
we made it possible to use almost every MIDI device that is out there!
You can find a list of commands within the PangoScript editor that is built into BEYOND.
To make it easy during the programming process, we advise you to open one of the MIDI monitors that are build into BEYOND.
(can be opened by following the menu : View >> Show Midi Monitor)
(can be enabled in the configuration of beyond : Settings >> Configuration >> Preview Window)
(can be viewed when opening your midi device configuration)
You can easily, turn a dial, press a button, or move an slider to jump to the corresponding line in the Script Editor. You will notice that it will match the same address as shown in the MIDI monitor.
So how do I use it?
In the first examples, I will set the brightness in various ways.
You can replace brightness with other functions, but I will keep it simple for now. The Script editor always shows the functions that are available in the version you are using.
For my examples we will use the script:
Code:
Brightness 100 // 0..100 (percents)
This function controls the brightness of all zones.
The above example shows an absolute statement.
The statement is 100. 100% in this case.
The text behind the // is for quick reference and is not needed for scripting.
We recommend you place separate commands onto separate lines in the editor.
There is no need to put a line termination character (such as ; ) at the end of a line.
If you are accustomed to doing that because of C or Pascal programming, that is okay, and the script editor will not mind, but it is not needed.
We will start with a MIDI button.
When you have opened the MIDI window of your device, press a button to jump to the line that controls the button you want to program.
Double click the empty line to open the editor.
(note that some buttons have 2 states, on and off. Choose ON in most cases)
I want this MIDI button to set my brightness of all my zones to 50%, so I enter the following line in the script editor
Code:
Brightness 50
Close the editor, the button is programmed and thats all there is to it!
For an encoder or slider we need to change the script a bit.
A normal slider or encoder changes MIDI commands from 00 till 7F, so if you want to assign the master brightness to it, you need to enter the following code:
Code:
Brightness ExtValue (0,100)
Close the editor, and thats it.
What we just have done is this; we want brightness, and we want to control it from 0% to 100%.
As we don't want to enter long lines of code to reprogram a controller, we use the statement ExtValue (minimum,maximum).
ExtValue can be used with almost any function that uses values.
Except for functions with On, Of or Toggle as value. (These values are made for assignment to buttons or usage within a script it self.)
We could also say that we want to control the brightness only from 10 to 100%. This is easily done by changing the script to:
Code:
Brightness ExtValue (10,100)
Easy as pie
If I had used the function "AngleY 0 // degree" in my examples, then I could have used the scipt "AngleY ExtValue (-360,360)" to control the Y angle on a slider or encoder.
But what if you only want to control the brightness of only the first zone?
We have to extend the script a bit:
Code:
ControlZone 1
Brightness ExtValue(0,100)
ControlZone defines the parameter that you want to control and on the next line you enter the function you want to change.
You could also do this, to control 3 zones;
Code:
ControlZone 1
Brightness ExtValue(0,100)
ControlZone 2
Brightness ExtValue(0,100)
ControlZone 3
Brightness ExtValue(0,100)
As long as you put every command on a new line, the function will be used.
Encoders which have only two states:
If you have an encoder that has only sends out 2 values (shown in the midi editor as 00 and 7F), and you want to control brightness with it use the following command:
Code:
Brightness ExtValue (1,-1)
This adds one, and removes 1, as soon as you rotate the encoder in various ways.
So now you know how to program an button, to program an encoder and an slider with your own preferred commands.
Last edited: