as is used to import a namespace with an alias.
import Filters as flt
AudioIn[1]
>> flt.Butteworth (
type: 'LowPass'
order: 4
cutoff: 500.
)
>> AudioOut;
from is used to get a value from a dictionary using the key or the key using the value.
dictionary Multiplexer (
key: [ 'One', 'Two', 'Three' ]
value: [ 1, 2, 3 ]
)
[ SignalOne, SignalTwo, SignalThree ]
>> GetPort ( index: 'Two' from Multiplexer )
>> Output;
dictionary Multiplexer (
key: [ 'Sine', 'Saw', 'Square' ]
value: [ 1, 2, 3 ]
)
Oscillator (
type : 2 from Multiplexer
)
>> Output;
import
import Filters
AudioIn[1]
>> Butteworth (
type: 'LowPass'
order: 4
cutoff: 500.
)
>> AudioOut;
in specifies a port direction. It is passed to the propertDirection port when declaring a module. It sets the port as an input port.
See Boolean off
See Boolean on
on is also used to specify the targetted hardware.
use PLATFORM version 1.2 on HARDWARE version 1.0
out specifies a port direction. It is passed to the propertDirection port when declaring a module. It sets the port as an output port.
If a certain property needs to be left unassigned during deceleration the none keyword is assigned to it. Not all properties can be assigned none. Consult the documentation of a block for more details.
version loads a particular version of a platform or specifies the version of the hardware.
use PLATFORM version 1.2 on HARDWARE version 1.0
with is used to specify a configuration file for the hardware.
use PLATFORM version 1.2 on HARDWARE version 1.0 with CONF_48KHz