From c577bf4d0bb8e526b7ec3f749446fab6dbc65a25 Mon Sep 17 00:00:00 2001 From: michaelpalumbo Date: Thu, 19 Nov 2020 21:47:58 -0500 Subject: [PATCH] use a different port for listener --- app.js | 6 +++--- listener.pd | 43 ++++++++++++++++--------------------------- 2 files changed, 19 insertions(+), 30 deletions(-) diff --git a/app.js b/app.js index df47627..cf8ea83 100644 --- a/app.js +++ b/app.js @@ -18,7 +18,7 @@ if(mode === 'server'){ localSendPort = 7403 } else if (mode === 'listener'){ // localReceivePort = 7404 - localSendPort = 7403 + listenerModeSendPort = 7405 } // ***** Local UDP-Sender ******* // @@ -245,8 +245,8 @@ if (mode === "server"){ }); } else if (mode === 'listener'){ - const localSend = new Client('127.0.0.1', localSendPort); - console.log('Configure your local pd patch(es) to listen on UDP Port ' + localSendPort) + const localSend = new Client('127.0.0.1', listenerModeSendPort); + console.log('Configure your local pd patch(es) to listen on UDP Port ' + listenerModeSendPort) // run the app in client mode // ***** Websocket ******* // // WebSocket that will automatically attempt to reconnect if the connection is closed, or if the remote server goes down diff --git a/listener.pd b/listener.pd index 875c195..e3a634c 100644 --- a/listener.pd +++ b/listener.pd @@ -1,29 +1,18 @@ #N canvas 659 236 782 508 12; -#X obj 30 106 oscparse; -#X obj 30 78 netreceive -u -b; -#X msg 30 52 listen 7401; -#X obj 30 130 list trim; -#X obj 30 156 route fromClient; -#X floatatom 30 181 5 0 0 0 - - -; -#X obj 30 21 loadbang; -#X obj 396 107 oscparse; -#X obj 396 79 netreceive -u -b; -#X obj 396 131 list trim; -#X floatatom 396 182 5 0 0 0 - - -; -#X obj 396 22 loadbang; -#X msg 396 53 listen 7403; -#X obj 396 157 route fromServer; -#X text 70 182 Jen's Data; -#X text 438 182 Erin's Data; -#X connect 0 0 3 0; +#X obj 72 106 oscparse; +#X obj 72 78 netreceive -u -b; +#X obj 72 130 list trim; +#X floatatom 72 241 5 0 0 0 - - -; +#X obj 72 21 loadbang; +#X text 114 241 Erin's Data; +#X obj 72 156 route fromServer fromClient; +#X floatatom 279 241 5 0 0 0 - - -; +#X text 321 241 Jen's Data; +#X msg 72 52 listen 7405; +#X connect 0 0 2 0; #X connect 1 0 0 0; -#X connect 2 0 1 0; -#X connect 3 0 4 0; -#X connect 4 0 5 0; -#X connect 6 0 2 0; -#X connect 7 0 9 0; -#X connect 8 0 7 0; -#X connect 9 0 13 0; -#X connect 11 0 12 0; -#X connect 12 0 8 0; -#X connect 13 0 10 0; +#X connect 2 0 6 0; +#X connect 4 0 9 0; +#X connect 6 0 3 0; +#X connect 6 1 7 0; +#X connect 9 0 1 0;