]> Shamusworld >> Repos - ardour-manual/blob - include/osc58-querying-ardour.html
OSC added /strip/list feedback documentation.
[ardour-manual] / include / osc58-querying-ardour.html
1
2 <p>
3   In order to make a custom controller that knows what strips Ardour
4   has, the controller needs to be able to query Ardour for that
5   information. These set of commands are for smarter control surfaces
6   That have the logic to figure out what to do with the information.
7   These are not of value for mapped controllers like touchOSC and
8   friends. The controller will need to send these queries to ardour
9   as often as it needs this information. It may well make sense to use
10   regular feedback for things that need to be updated often such as
11   position or metering.
12   Here are the commands used to query Ardour: (added in Ardour 5.5)
13 </p>
14
15 <table class="dl">
16   <tr><th><kbd class="osc">/strip/list</kbd></th>
17   <td>Ask for a list of strips</td></tr>
18   <tr><th><kbd class="osc">/strip/sends <em>ssid</em></kbd></th>
19   <td>Asks for a list of sends on the strip <em>ssid</em></td></tr>
20   <tr><th><kbd class="osc">/strip/receives <em>ssid</em></kbd></th>
21   <td>Asks for a list of tracks that have sends to the strip <em>ssid</em> points to</td></tr>
22   <tr><th><kbd class="osc">/strip/plugin/list <em>ssid</em></kbd></th>
23   <td>Asks for a list of plug-ins for strip <em>ssid.</em></td></tr>
24   <tr><th><kbd class="osc">/plugin/descriptor <em>ssid</em> <em>piid</em></kbd></th>
25   <td>Asks for a list of descriptors for plug-in <em>piid</em> on strip <em>ssid</em></td></tr>
26 </table>
27
28 <h3>A list of strips</h3>
29
30 <p>
31   <code>/strip/list</code> asks Ardour for a list of strips that the
32   current session has. Ardour replies with a message for each
33   strip with the following information:
34   <ul>
35     <li>Strip type - One of:</li>
36     <ul>
37                 <li>AT - Audio Track</li>
38                 <li>MT - MIDI Track</li>
39                 <li>B - Audio Bus</li>
40                 <li>MB - MIDI bus</li>
41                 <li>AX - Aux bus</li>
42                 <li>V - VCA</li>
43     </ul>
44     <li>Strip name</li>
45     <li>Number of inputs</li>
46     <li>Number of outputs</li>
47     <li>Muted</li>
48     <li>Soloed</li>
49     <li>Ssid (strip number)</li>
50     <li>Record enabled</li>
51   </ul>
52   After all the strip messages have been sent, one final message is
53   sent with:
54   <ul>
55     <li>The text <code>end_route_list</code></li>
56     <li>The session frame rate</li>
57     <li>The last frame number of the session</li>
58     <li>Monitor section present</li>
59   </ul>
60 </p>
61 <p>
62   If the surface is using <code>/strip/list</code>, the surface needs to know
63   if the strips have changed. This would be true if a strip gets moved, created or
64   deleted. When this happens Ardour sends <code>/strip/list</code> to the surfaces
65   that have previously requested a <code>/strip/list</code>. This lets the
66   surface know that it's list of strips is no longer valid.
67 </p>
68 <p class="note">A bus will not have a record enable and so a bus message
69   will have one less parameter than a track. It is the controllers
70   responsability to deal with this.
71 </p>
72
73 <h3>A list of sends</h3>
74 <p>
75   <code>/strip/sends <em>ssid</em></code> asks Ardour for a list of
76   sends for strip number ssid. The reply is sent back to the
77   controller as one message with the following information:
78   <ul>
79     <li>Ssid that information is for</li>
80     <li>Each send's information:</li>
81     <ul>
82       <li>The send's target bus ssid</li>
83       <li>The send's target bus name</li>
84       <li>The send id for this strip</li>
85       <li>The send gain as a fader possition</li>
86       <li>The Send's enable state</li>
87     </ul>
88   </ul>
89 </p>
90 <p>
91   The controller can tell how many sends there are from the number of
92   parameters as each send has 5 parameters and there is one extra for
93   ssid.
94 </p>
95
96 <h3>A list if tracks that send audio to a bus</h3>
97 <p>
98   <code>/strip/receives <em>ssid</em></code> will return a list of
99   tracks that have sends to the bus at the ssid. The reply will
100   contain the following information for each track conntected to this
101   bus:
102   <ul>
103     <li>The ssid of the track sending</li>
104     <li>The name of the sending track</li>
105     <li>The id of the send at that track</li>
106     <li>It's gain in fader possition</li>
107     <li>The send's enable state</li>
108   </ul>
109 </p>
110
111 <h3>A list of plug-ins for strip</h3>
112 <p>
113   <code>/strip/plugin/list <em>ssid</em></code> will return a list of
114   plug-ins that strip ssid has. The reply will contain the following
115   information:
116   <ul>
117     <li>Ssid that information is for</li>
118     <li>Each plugin's information:</li>
119     <ul>
120       <li>The plug-in's id</li>
121       <li>The plug-in's name</li>
122     </ul>
123   </ul>
124 </p>
125
126 <h3>A list of a plug-in's parameters</h3>
127 <p>
128   <code>/plugin/descriptor <em>ssid</em> <em>piid</em></code> will
129   return the plug-in parameters for ppid plug-in on the ssid strip. The
130   reply will contain the following information:
131   <ul>
132     <li>Ssid of the strip the plug-in is in</li>
133     <li>The plug-in id for the plug-in</li>
134     <li>The plug-in's name</li>
135     <li>Information about each parameter</li>
136     <ul>
137       <li>The parameter id</li>
138       <li>The parameter's name</li>
139       <li>A bitset of flags (see below)</li>
140       <li>Data type</li>
141       <li>Minimum value</li>
142       <li>Maximum value</li>
143       <li>The number of scale points</li>
144       <li>zero or more scale points of one value and one string each</li>
145       <li>The current parameter value</li>
146     </ul>
147   </ul>
148 </p>
149 <p>
150   The flag bitset above has been defined as (from lsb):
151   <ul>
152     <li>0&mdash;enumeration</li>
153     <li>1&mdash;integer step</li>
154     <li>2&mdash;logarithmic</li>
155     <li>3&mdash;max unbound</li>
156     <li>4&mdash;min unbound</li>
157     <li>5&mdash;sample rate dependent</li>
158     <li>6&mdash;toggled</li>
159     <li>7&mdash;controllable</li>
160   </ul>
161 </p>
162 <p>
163         While this seems complex, it is really not that bad. Minimum,
164         maximum and value will in most cases give you all you need.
165 </p>
166