doc_px1m0d_XMLStructure
Plug Description File
[print]
[en ]

Table of contents



Example:
<plugTree xmlns="http://maybites.ch/px1m0d/plugTypesSchema"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://maybites.ch/px1m0d/plugTypesSchema file:./data/schemas/plugTypes.xsd">
    <plug path="ch.maybites.px1m0d.plug.collection.liveA.PlgDevice" name="Device.NumberOne">
    	<parameter>
    	    <display>
    		<icon path="ch.maybites.px1m0d.plug.drawing.effects.icons.IconBasic">
    		    <color red="255" green="0" blue="0" alpha="255" />
    		    <label>SamplerTake4</label>
    		    <labelPipe0>Volume</labelPipe0>
    	       	    <labelPipe1>ChannelA</labelPipe1>
    		    <labelPipe2>ChannelB</labelPipe2>
    		    <labelPipe3>*3*</labelPipe3>
    		    <labelPipe4>*4*</labelPipe4>
    		    <labelPipe5>*5*</labelPipe5>
    		    <labelPipe6>*6*</labelPipe6>
    		    <labelPipe7>*7*</labelPipe7>
    		    <labelPipe8>*8*</labelPipe8>
    		</icon>
    	    </display>
	    <jobs>
		<job 	id="125" 
			name="DeviceJobNumber02"
			description="sends osc message to...">
		    <message trigger="LocalSwitchIsToggled and LocalSwitchIsOn">
	                <target>
			    <sendToSocketID>LinkSocketID</sendToSocketID>
			</target>
			<midi>
			    <status type="NoteON" channel="LinkXPos" />
			    <data>LinkPlugID</data>
			    <data>LocalNatebuValue</data>
			</midi>
		     </message>
		</job>
	    </jobs>
         </parameter>
    </plug>
</plugTree>


More Abstract:

<plugTree xmlns="http://maybites.ch/px1m0d/plugTypesSchema"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://maybites.ch/px1m0d/plugTypesSchema file:./data/schemas/plugTypes.xsd">
    <plug path="##ClassPath##" name="##PlugName##">
    	<parameter>
    	    <display>
    		<icon path="##ClassPath##">
    		    <color red="##RedValue##" green="##GreenValue##" blue="##BlueValue##" alpha="##AlphaValue##" />
    		    <label>##PlugLabel##</label>
    		    <labelPipe0>##PipeLabel##</labelPipe0>
    	       	    <labelPipe1>##PipeLabel##</labelPipe1>
    		    <labelPipe2>##PipeLabel##</labelPipe2>
    		    <labelPipe3>##PipeLabel##</labelPipe3>
    		    <labelPipe4>##PipeLabel##</labelPipe4>
    		    <labelPipe5>##PipeLabel##</labelPipe5>
    		    <labelPipe6>##PipeLabel##</labelPipe6>
    		    <labelPipe7>##PipeLabel##</labelPipe7>
    		    <labelPipe8>##PipeLabel##</labelPipe8>
    		</icon>
    	    </display>
	    <jobs>
		<job 	id="##JobID##"
			name="##JobName##"
			description="##JobDescription##">
		    <message trigger="##JobTrigger##">
			##TargetTag##
                        ##MessageTypeTag##
		    </message>
		</job>
	    </jobs>
	</parameter>
    </plug>
</plugTree>


Icon Definition


<icon path="##ClassPath##">
DataType: <String>
i.e. "ch.maybites.px1m0d.plug.drawing.effects.icons.IconBasic"
is the java class path to the java class that represents this icon.
more about java classes?

<color red="##RedValue##" green="##GreenValue##" blue="##BlueValue##" alpha="##AlphaValue##" />
DataType: <Int> Range: 0...255
i.e. "123"
the values of the color components of the icon

<label>##PlugLabel##</label>
DataType: <String>
i.e. "SamplePlayer"
Text of the Label of the Icon

<labelPipeX>##PipeLabel##</labelPipeX>
DataType: <String>
i.e. "Volume"
Text of the Label of the respective PipeChannel
Should be kept short (less than 10 characters)

Plug Definition


<plug path="##ClassPath##" name="##PlugName##">
DataType: <String>
i.e. "ch.maybites.px1m0d.plug.collection.liveA.PlgDevice"
is the java class path to the java class that represents this plug.
more about java classes?

<plug path="##ClassPath##" name="##PlugName##">
DataType: <String>
i.e. "Device.NumberOne"
is the name of the plug as it appears inside the application tab "plugs". the dots represent the the different levels, similar to '/' for folder structures.

Job Description


<job id="##JobID##" name="JobNo1" description="some description...">
DataType: <Int> (not required)
i.e. "123"
the jobs id. not used internally, only descriptive

<job id="1" name="##JobName##" description="some description...">
DataType: <String> (not required)
i.e. "DeviceJobNumber02"
the jobs name. not used internally, only descriptive

<job id="1" name="JobNo1" description="##JobDescription##">
DataType: <String> (not required)
i.e. "sends osc message to..."
the jobs description. not used internally, only descriptive

Message Trigger


<message trigger=##JobTrigger##">
DataType: <Boolean Expression>
i.e. "LocalNatebuValueIsChanged and LocalPlugIsLinked"
Describes the condition, in which the job is beeing executed. Has to return a Boolean Value. (true or false)
more about ExpressionLanguage?

Targets


##TargetTag##
there are currently the following SendTo Tags inside the TargetTag available:
<target>
    <sendToWorld/>
</target>
or
<target>
    <sendToSocketID>##SocketID##</sendToSocketID>
</target>
or
<target>
    <sendToPlugID>##PlugID##</sendToPlugID>
</target>
or
<target>
    <sendToBoard>##SocketID##</sendToBoard>
</target>
or
<target>
    <sendToRow>##SocketID##</sendToRow>
</target>
or
<target>
    <sendToCollum>##SocketID##</sendToCollum>
</target>
or
<target>
    <sendToNeighbours>##SocketID##</sendToNeighbours>
</target>


Send To


<sendToWorld/>
sends the message to the world - meaning to the outside of the application. It usually is sent to the specified address in the UserInterface? under the tab 'Connections'. An exception of this can be found under doc_px1m0d_OSCMessage?.

<sendToSocketID>
sends the message internally to the specified SocketID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToPlugID>
sends the message internally to the specified PlugID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToBoard>
sends the message internally to the complete Board, except to the specified SocketID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToRow>
sends the message internally to the complete Row of the specified SocketID, except to the specified SocketID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToCollum>
sends the message internally to the complete Collum of the specified SocketID, except to the specified SocketID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToNeighbours>
sends the message internally to all the Neighbours of the specified SocketID. Is usually used for doc_px1m0d_PipeMessage?.

<sendToSocketID>##SocketID##</sendToSocketID>
DataType: <Number Expression>
i.e. "LinkSocketID"
socketID is numbered from 0 to 63, starting from upper left to lower right.

<sendToPlugID>##PlugID##</sendToPlugID>
DataType: <Number Expression>
i.e. "LinkPlugID"
The plugID is usually written onto the plug itself and is used internally to map the hardware plug with the software plug object. This mapping is not done inside this file but in a different file found in the data folder under plug/mapping/default.xml or similar. The mapping should be done inside the UserInterface?.

Message Types


##MessageTypeTag##
There are three different message types available.
<midi>
	<status type="##MidiStatusType##" channel="##MidiStatusChannel##" />
	<data>##MidiData##</data>
	<data>##MidiData##</data>
</midi>
<osc ipAddress="##OscIPAddress##"> 
        <addressPattern>##OscAddrPattern##</addressPattern>
	<addOscString>##OscDataString##</addOscString>
	<addOscInt>##OscDataInt##</addOscInt>
	<addOscFloat>##OscDataFloat##</addOscFloat>
</osc>
<pipe channel="##PipeChannel##">
	<value type="##PipeValueType##">##PipeValue##</value>
</pipe>


Midi Messages


<status type="##MidiStatusType##" channel="3"/>
DataType: <StatusType>
i.e. "NoteOn"
more about doc_px1m0d_MidiMessage?

<status type="##MidiStatusType##" channel="##MidiStatusChannel##" />
DataType: <Number Expression>
i.e. "LinkXPos"
a number (or an expression that returns a number) between 0 and 15 [midi channel 1...16]].
more about doc_px1m0d_MidiMessage? or ExpressionLanguage?

<data>##MidiData##</data>
DataType: <Number Expression>
i.e. "LinkXPos + 11"
The expression calculates the value of the data-bytes.
more about doc_px1m0d_MidiMessage? or ExpressionLanguage?

OSC Messages


<osc ipAddress="##OscIPAddress##">
DataType: <String>
i.e. "world" or "192.168.1.27"
represents the keyphrase "world" or a valid IP adress, where the message should be sent to. If the keyphrase "world" is used, the osc message will be sent to the specified address in the UserInterface? under the tab 'Connections'.
more about doc_px1m0d_OSCMessage?

<addressPattern>##OscAddrPattern##</addressPattern>
DataType: <String Expression>
i.e. "'/osc/level/'+LocalNatebuValue"
represents a valid Osc Path that could look like /osc/level/3
more about doc_px1m0d_OSCMessage? or ExpressionLanguage?

<addOscString>##OscDataString##</addOscString>
DataType: <String Expression>
i.e. "plug1"
adds a string to the osc message, concatinated by the expression.
more about doc_px1m0d_OSCMessage? or ExpressionLanguage?

<addOscInt>##OscDataInt##</addOscInt>
DataType: <Number Expression>
i.e. "LocalNatebuValue / 2"
adds an Int to the osc message, calculated by the expression.
more about doc_px1m0d_OSCMessage? or ExpressionLanguage?

<addOscFloat>##OscDataFloat##</addOscFloat>
DataType: <Number Expression>
i.e. "LocalNatebuValue / 2.354"
adds a Float to the osc message, calculated by the expression.
more about doc_px1m0d_OSCMessage? or ExpressionLanguage?

Pipe Messages


<pipe channel="##PipeChannel##">
DataType: <Number Expression>
i.e. "4"
There are 9 pipe channels, numbered from 0...8
more about doc_px1m0d_PipeMessage? or ExpressionLanguage?

<value type="##PipeValueType##">LocalPipeValue01</value>
DataType: <PipeValueType>
i.e. "abs" or "rel"
Defines if the PipeMessage is of absolute or relative type. Absolute means, the sent value is as it is, Relative means, this value has to be added (if positive) or subtracted (if negativ) from the former value.
more about doc_px1m0d_PipeMessage?

<value type="abs">##PipeValue##</value>
DataType: <Number Expression>
i.e. "LocalNatebuValue / 2"
more about doc_px1m0d_PipeMessage? or ExpressionLanguage?



pic

thumbnail
905_Pic090.jpg