<div dir="ltr"><div>Hi Miller and IOhannes,</div><div><br></div><div>Thanks for the extremely informative replies!<br><br>The -guicmd option seems to work but will not meet my needs unfortunately. I'm specifically interested in a way to connect the GUI to an existing running instance of the DSP without interrupting the patch.<br><br>IOhannes, I came across your suggestion of using a proxy server in an old Google Groups post from 2010:<br><a href="https://groups.google.com/forum/#!topic/linux.debian.bugs.dist/lKMEPX417h4">https://groups.google.com/forum/#!topic/linux.debian.bugs.dist/lKMEPX417h4</a><br><br>By doing the following,<br><br></div><div><b>Terminal 1</b><br><div>$ cd /tmp</div><div>$ mknod backpipe p</div><div>$ netcat -l -p 8000 0<backpipe | netcat -l -p 7000 1>backpipe</div><div><b>Terminal 2</b></div><div>$ /usr/bin/pd -guiport 8000</div><div><b>Terminal 3</b></div><div>$ /usr/lib/pd/bin/pd-gui 7000<br><br>I was able to get it working successfully. However, the problem is that until the GUI is started, the DSP does not start running. So the DSP cannot run independently of the GUI (if I start the DSP with -nogui then the -guiport command no longer works).<br><br>Do you think it would be difficult to write a patch for PD to create the following behaviour?<br><b><br class="gmail-Apple-interchange-newline">Terminal 1</b><div>$ /usr/bin/pd -nogui -guiport 8000<br>(sound starts playing)</div><div><b>Terminal 2</b></div><div>$ /usr/lib/pd/bin/pd-gui 8000<br><br>Regards,<br>Jerry</div></div></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span style="font-size:12.8px">From: IOhannes m zmölnig <</span><a href="mailto:zmoelnig@iem.at" style="font-size:12.8px">zmoelnig@iem.at</a><span style="font-size:12.8px">></span><br style="font-size:12.8px"><span style="font-size:12.8px">To: </span><a href="mailto:pd-list@lists.iem.at" style="font-size:12.8px">pd-list@lists.iem.at</a><span style="font-size:12.8px">, 20160904152103.GD5414@</span><wbr style="font-size:12.8px"><span style="font-size:12.8px">localhost.localdomain</span><br style="font-size:12.8px"><span style="font-size:12.8px">Subject: Re: [PD] connecting pd-gui to pd</span><br style="font-size:12.8px"><span style="font-size:12.8px">Message-ID: <</span><a href="mailto:4ff4b5f6-084c-912c-1b82-b20729308e9e@iem.at" style="font-size:12.8px">4ff4b5f6-084c-912c-1b82-<wbr>b20729308e9e@iem.at</a><span style="font-size:12.8px">></span><br style="font-size:12.8px"><span style="font-size:12.8px">Content-Type: text/plain; charset="utf-8"</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">On 09/10/2016 04:23 PM, Miller Puckette wrote:</span><br style="font-size:12.8px"><span style="font-size:12.8px">> This might help (the subject line is confusing but I think this answers</span><br style="font-size:12.8px"><span style="font-size:12.8px">> your question too :)</span><br style="font-size:12.8px"><span style="font-size:12.8px">></span><br style="font-size:12.8px"><span style="font-size:12.8px">> </span><a href="https://lists.puredata.info/pipermail/pd-list/2016-09/116052.html" rel="noreferrer" target="_blank" style="font-size:12.8px">https://lists.puredata.info/<wbr>pipermail/pd-list/2016-09/<wbr>116052.html</a><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">actually, i think the answer is not entirely correct.</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">at least i'm pretty confident that it still works the same as it used to</span><br style="font-size:12.8px"><span style="font-size:12.8px">back in - hm, hm - 2006 (and later), when we did the "peer data" thing.</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">what i did back then was:</span><br style="font-size:12.8px"><span style="font-size:12.8px">use a proxy that listens to two different tcp/ip ports (say 8001 and</span><br style="font-size:12.8px"><span style="font-size:12.8px">8002; with all messages that are received on one port being forwarded to</span><br style="font-size:12.8px"><span style="font-size:12.8px">the other port - in both directions)</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">start Pd like "pd -guiport 8001" (so it uses the proxy as it's "GUI").</span><br style="font-size:12.8px"><span style="font-size:12.8px">start Pd-gui like "pd-gui pdhost:8002" (so it uses the proxy as it's</span><br style="font-size:12.8px"><span style="font-size:12.8px">"DSP" engine).</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">unfortunately the proxy needs a bit of magic built in, for all that to</span><br style="font-size:12.8px"><span style="font-size:12.8px">work properly.</span><br style="font-size:12.8px"><span style="font-size:12.8px">what i remember from back then:</span><br style="font-size:12.8px"><span style="font-size:12.8px">- if you want to do some audio-configuration via the menu, the proxy</span><br style="font-size:12.8px"><span style="font-size:12.8px">MUST record a few messages at the beginning of the session (after</span><br style="font-size:12.8px"><span style="font-size:12.8px">connection to the DSP), when all the necessary data is sent to the GUI</span><br style="font-size:12.8px"><span style="font-size:12.8px">- the proxy must store all the active window IDs, so when the pd-gui</span><br style="font-size:12.8px"><span style="font-size:12.8px">connects anew, it can tell the DSP to redraw all the windows.</span><br style="font-size:12.8px"><span style="font-size:12.8px">- i *think* the proxy needs to do a bit of handshake when connecting to</span><br style="font-size:12.8px"><span style="font-size:12.8px">the DSP.</span><br style="font-size:12.8px"><span style="font-size:12.8px">- for sanities reasons, it might make sense to disallow Ctrl-Q to</span><br style="font-size:12.8px"><span style="font-size:12.8px">shut-down the DSP</span><br style="font-size:12.8px"><span style="font-size:12.8px">- you might need to handle the watchdog events in the proxy (if running</span><br style="font-size:12.8px"><span style="font-size:12.8px">with "-rt")</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">i also remember a bit of problems when using Pd-GUI on OSX (and we never</span><br style="font-size:12.8px"><span style="font-size:12.8px">tried on W32), but i cannot remember the nature of these problems (and</span><br style="font-size:12.8px"><span style="font-size:12.8px">bear in mind that the main objective of that project was to have</span><br style="font-size:12.8px"><span style="font-size:12.8px">*multiple* GUIs talk to a single DSP)</span><br style="font-size:12.8px"><br style="font-size:12.8px"><span style="font-size:12.8px">mdgfdsa</span><br style="font-size:12.8px"><span style="font-size:12.8px">IOhannes</span><br></blockquote><div class="gmail_extra"><br><div class="gmail_quote">On 11 September 2016 at 00:23, Miller Puckette <span dir="ltr"><<a href="mailto:msp@ucsd.edu" target="_blank">msp@ucsd.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">This might help (the subject line is confusing but I think this answers<br>
your question too :)<br>
<br>
<a href="https://lists.puredata.info/pipermail/pd-list/2016-09/116052.html" rel="noreferrer" target="_blank">https://lists.puredata.info/<wbr>pipermail/pd-list/2016-09/<wbr>116052.html</a><br>
<br>
cheers<br>
Miller<br>
<div><div class="gmail-h5"><br>
On Sat, Sep 10, 2016 at 05:17:45PM +1000, Jeremiah Rose wrote:<br>
> Hi there, I've already asked this question over at the pdpatchrepo forums<br>
> but I get the feeling you guys really know your stuff so I wanted to ask<br>
> here too.<br>
><br>
> Here's the situation -<br>
><br>
> Computer 1: a raspberry pi with no screen, keyboard or mouse that<br>
> automatically runs a headless instance of pure data when it boots up:<br>
> pd -nogui mypatch.pd<br>
><br>
> Computer 2: my laptop. I want to start the GUI separetly and connect it to<br>
> the existing pd instance on the raspberry pi so that I can program the<br>
> patch, alter it, save it, and watch it in action. I believe the command<br>
> should be something like:<br>
> pd-gui HOST:PORT<br>
><br>
> But I can't seem to make it work and there is no documentation to speak of<br>
> anywhere. Can anyone help?<br>
><br>
> I'd be happy to document this on the pd wiki and forums once I figure it<br>
> out, as there currently seems to be no reference.<br>
<br>
</div></div>> ______________________________<wbr>_________________<br>
> <a href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br>
> UNSUBSCRIBE and account-management -> <a href="https://lists.puredata.info/listinfo/pd-list" rel="noreferrer" target="_blank">https://lists.puredata.info/<wbr>listinfo/pd-list</a><br>
<br>
</blockquote></div><br></div></div>