net.tcp.recv already bound to port?

xMonsta's icon

Hi,

I have an open port in another program which is sending/receiving a TCP stream on port 5555. I'm wondering why when set [mxj net.txp.recv @port 5555] it is giving me a "net.tcp.recv: there is already an object bound to port 5555" error?

Is it not possible to listen to a port that is already open from another program using net.tcp.recv?

sonichel's icon

it happens the same to me. managed to solve it?

gumi's icon

I have the same problem with [jit.net.rcv] and [udpreceive].

Is it not possible to listen to a port that is already open from another program using [these objects]?

Floating Point's icon

No, not possible, one port per socket. Instead you can do broadcasting so the same stream can be accessed on any port.

gumi's icon

Thanks for confirming! Do you mean [jit.broadcast] as the alternative? I'm having some issues getting that object to receive data but will keep tinkering...

Floating Point's icon

Sorry for taking long to get back to you-- I've never used jit.net.* objects, but have used the mxj net.* objects.
Have a look at [mxj net.maxhole]. Also try [mxj net.multi.send] and net.multi.receive and see how you go.