<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[space in OSC node identifier?]]></title><description><![CDATA[<p>I'm trying to write an OSC control message for Qlab and one of the nodes in the path is supposed to be &quot;patch 1&quot;.  Yes, that's a space between the 'h' and the '1'.  Is that legal OSC, and if so, how do you coax [oscformat] to emit it?</p>
<p><img src="/uploads/files/1693683589209-space-in-osc-message.png" alt="space in osc message.png" class="img-responsive img-markdown" /></p>
<p>edit:  Oh duh, I can just change the name of the patch to not have spaces.  I'd still like to know if spaces are legal and possible with [oscformat] though.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier</link><generator>RSS for Node</generator><lastBuildDate>Sat, 15 Aug 2026 10:11:54 GMT</lastBuildDate><atom:link href="http://forum.pdpatchrepo.info/topic/14464.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 02 Sep 2023 19:41:50 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to space in OSC node identifier? on Sat, 02 Sep 2023 21:07:27 GMT]]></title><description><![CDATA[<p>I'm trying to write an OSC control message for Qlab and one of the nodes in the path is supposed to be &quot;patch 1&quot;.  Yes, that's a space between the 'h' and the '1'.  Is that legal OSC, and if so, how do you coax [oscformat] to emit it?</p>
<p><img src="/uploads/files/1693683589209-space-in-osc-message.png" alt="space in osc message.png" class="img-responsive img-markdown" /></p>
<p>edit:  Oh duh, I can just change the name of the patch to not have spaces.  I'd still like to know if spaces are legal and possible with [oscformat] though.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier</guid><dc:creator><![CDATA[jameslo]]></dc:creator><pubDate>Sat, 02 Sep 2023 21:07:27 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 01:30:30 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/jameslo">@jameslo</a> said:</p>
<blockquote>
<p>I'd still like to know if spaces are legal and possible with [oscformat] though.</p>
</blockquote>
<p>I'm a bit surprised to see this, but in fact, according to the OSC spec 1.0, spaces are not allowed in OSC command paths.</p>
<p><a href="https://ccrma.stanford.edu/groups/osc/spec-1_0.html#osc-address-spaces-and-osc-addresses" rel="nofollow">https://ccrma.stanford.edu/groups/osc/spec-1_0.html#osc-address-spaces-and-osc-addresses</a></p>
<blockquote>
<p>Each OSC Method and each OSC Container other than the root of the tree has a symbolic name, an ASCII string consiting of printable characters other than the following:</p>
<table>
<thead>
<tr>
<th>-character-</th>
<th>-name-</th>
<th>-ASCII code (decimal)-</th>
</tr>
</thead>
<tbody>
<tr>
<td>’ ’</td>
<td>space</td>
<td>32</td>
</tr>
<tr>
<td>#</td>
<td>number sign</td>
<td>35</td>
</tr>
<tr>
<td>*</td>
<td>asterisk</td>
<td>42</td>
</tr>
<tr>
<td>,</td>
<td>comma</td>
<td>44</td>
</tr>
<tr>
<td>/</td>
<td>forward slash</td>
<td>47</td>
</tr>
<tr>
<td>?</td>
<td>question mark</td>
<td>63</td>
</tr>
<tr>
<td>[</td>
<td>open bracket</td>
<td>91</td>
</tr>
<tr>
<td>]</td>
<td>close bracket</td>
<td>93</td>
</tr>
<tr>
<td>{</td>
<td>open curly brace</td>
<td>123</td>
</tr>
<tr>
<td>}</td>
<td>close curly brace</td>
<td>125</td>
</tr>
</tbody>
</table>
</blockquote>
<p>So Pd has no obligation to support spaces here.</p>
<p>I suppose it depends on the software's OSC handler. SuperCollider doesn't complain (contrary to the OSC spec):</p>
<pre><code>n = NetAddr.localAddr;  // send to myself

o = OSCFunc({ |msg|
    msg.postln;
    o.free;
}, '/test space');

n.sendMsg('/test space', 1);

prints: [ /test space, 1 ]
</code></pre>
<p>I did some other tests:</p>
<ul>
<li>&quot;symbol patch 1&quot; --&gt; [list fromsymbol]: escape char 92 is not in the ASCII list.</li>
<li>list &quot;112 97 116 99 104 32 49&quot; --&gt; [list tosymbol]: resulting symbol prints with a backslash. I don't know if the backslash is stored internally, or if it's inserted only for the printed output. A quick look at the source code in x_list.c suggests that the backslash is <em>not</em> stored internally.</li>
<li>list &quot;112 97 116 99 104 32 49&quot; --&gt; [list tosymbol] --&gt; [list prepend set] --&gt; [list trim] --&gt; [oscformat]: The printed bytes from oscformat <em>do</em> include char 92. But I couldn't see in the source code where the space is being escaped. (This long way around to build the &quot;set&quot; message is to be certain that there's no backslash in my input -- the backslash <em>must</em> be generated internally somewhere..)</li>
</ul>
<p>So [oscformat] seems to be where the problem is happening -- but the OSC spec makes no promises that spaces will work, so there wouldn't be any justification to log a bug.</p>
<p>hjh</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/2</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/2</guid><dc:creator><![CDATA[ddw_music]]></dc:creator><pubDate>Sun, 03 Sep 2023 01:30:30 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 08:11:14 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/jameslo">@jameslo</a> There can be spaces in the address.... the [oscformat] help is full of them between symbols.<br />
Pretty sure [set patch 1( will correctly set the header although I cannot test with Qlab.<br />
I think the &quot;backslashes&quot; were always in the workings of Pd..... just that up to version 0.4? they were totally reserved.....we could not type them (as is also the case in this forum) and they were not displayed.<br />
David.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/3</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/3</guid><dc:creator><![CDATA[whale-av]]></dc:creator><pubDate>Sun, 03 Sep 2023 08:11:14 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 10:33:28 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/whale-av">@whale-av</a> said:</p>
<blockquote>
<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/jameslo">@jameslo</a> There can be spaces in the address.... the [oscformat] help is full of them between symbols.</p>
</blockquote>
<p>Between symbols is different from what I'm asking--I'm asking about within a symbol (i.e. &quot;Container&quot;).  [oscformat patch 1] outputs &quot;/patch/1&quot; but what the Qlab OSC dictionary seems to imply it wants is &quot;.../patch 1/...&quot;.  From their documentation:<br />
<img src="/uploads/files/1693736473951-screenshot-2023-09-03-062053.png" alt="Screenshot 2023-09-03 062053.png" class="img-responsive img-markdown" /> and the default name for the one uneditable audio patch you are allowed in the free version is &quot;patch 1&quot;.  (Did that sound like a complaint?  In no way am I looking a gift horse in the mouth!  Technically you have to buy a license to be able to adjust that level in the GUI, but for some reason it's adjustable via OSC and it works.  I guess their license fee is a tax on non-hackers <img class="emoji emoji-extended" src="http://forum.pdpatchrepo.info/plugins/nodebb-plugin-emoji-extended/images/grinning.png" title=":)" alt=":)" />)</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/4</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/4</guid><dc:creator><![CDATA[jameslo]]></dc:creator><pubDate>Sun, 03 Sep 2023 10:33:28 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 13:05:52 GMT]]></title><description><![CDATA[<p>Hi,<br />
if the 92 backslash is added by oscformat let's try to don't use it<br />
<img src="/uploads/files/1693746070003-image.png" alt="image.png" class="img-responsive img-markdown" /></p>
<p>32 is space<br />
47 is slash<br />
I deduce the required end of the message from oscformat output</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/5</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/5</guid><dc:creator><![CDATA[FFW]]></dc:creator><pubDate>Sun, 03 Sep 2023 13:05:52 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 13:34:22 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/ffw">@FFW</a> He he he....or since the backslash is always at a fixed position in the complete OSC control message, take the output of [oscformat] and just remove the byte at that position  <img class="emoji emoji-extended" src="http://forum.pdpatchrepo.info/plugins/nodebb-plugin-emoji-extended/images/grinning.png" title=":)" alt=":)" />  Oh wait, no, I think I'd have to also add some padding to the end to meet some message length requirement.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/6</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/6</guid><dc:creator><![CDATA[jameslo]]></dc:creator><pubDate>Sun, 03 Sep 2023 13:34:22 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 15:26:34 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/jameslo">@jameslo</a> said:</p>
<blockquote>
<p>I think I'd have to also add some padding to the end to meet some message length requirement.</p>
</blockquote>
<p>Yes I don't read the doc but I think the message should be a 8 bytes words multiple and ends with 44 0 0 0. So you need to add as many zero as required before this.</p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/7</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/7</guid><dc:creator><![CDATA[FFW]]></dc:creator><pubDate>Sun, 03 Sep 2023 15:26:34 GMT</pubDate></item><item><title><![CDATA[Reply to space in OSC node identifier? on Sun, 03 Sep 2023 20:32:38 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-a" href="http://forum.pdpatchrepo.info/user/ffw">@FFW</a> BWAH HA HA HA HA HA ... I just tested this insane version with Qlab and it worked:</p>
<p><img src="/uploads/files/1693756084182-screenshot-2023-09-03-114551.png" alt="Screenshot 2023-09-03 114551.png" class="img-responsive img-markdown" /><br />
Note to self: must get a life</p>
<p>Edit:  a more modern version:</p>
<p><img src="/uploads/files/1693773145494-screenshot-2023-09-03-163133.png" alt="Screenshot 2023-09-03 163133.png" class="img-responsive img-markdown" /></p>
]]></description><link>http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/8</link><guid isPermaLink="true">http://forum.pdpatchrepo.info/topic/14464/space-in-osc-node-identifier/8</guid><dc:creator><![CDATA[jameslo]]></dc:creator><pubDate>Sun, 03 Sep 2023 20:32:38 GMT</pubDate></item></channel></rss>