two max app communicating

Jul 4, 2012 at 1:55pm

two max app communicating

Hi all,

I need two Max *applications* to communicate with each other.
Messages are bangs, or integers, so I don’t need any audio routing through Jack or Soundflower or the like…
So far the only solution i had is to use UDP, but it seems not to work.
Here’s the code.
Any tip highly welcomed!
Thanks!

– Pasted Max Patch, click to expand. –
#41783
Jul 4, 2012 at 2:05pm

i forgot to say… the two applications are within the very same computer! ;-)

#149014
Jul 4, 2012 at 2:26pm

works fine here…
MacBook Pro 10.7.4 – max5 and max6
Which platform are you on? Mac or PC?

#149015
Jul 4, 2012 at 2:49pm

really? interesting… I’m on a Mac max5 Lion btw
i use the localhost settings. And as said, trying to communicate from one application to another, made with Max with no results…
Are you using port 7400?

#149016
Jul 4, 2012 at 3:07pm

Did you check the Max window?
You should find an error message (such as “bind to port 7400 unsuccessful”), if it did not work as expected.

You have to be careful not to use two [udpreceive] objects with same port number.

#149017
Jul 4, 2012 at 3:32pm

There was a promising project by Nao Tokui for OSX years ago (2006), but unfortunately it doesn’t seem to be maintained. I never tried those objects between 2 standalones.

http://www.sonasphere.com/2002/01/maxmsp-objects-2002〜/

p

#149018
Jul 4, 2012 at 3:51pm

very naive from me… i had the same port set on the sending app as well, so as a result on the receiving app that port was already taken!
and yes, Nao project seems very interesting, I’ll tinker with it a bit asap i think
thanks everyone!

#149019
Jul 4, 2012 at 7:05pm

Along those lines, sort of, [send] and [receive] between patches works as expected (the same names will communicate to any active patch), BUT, between two standalones, same-named [send] and [receive] objects will NOT communicate with each other, only within their own standalone. The each have their own namespace, if I remember the terminology right.

So, don’t know if it applies in your case, but something to keep in mind if you have multiple standalones with s/r objects in them and they’re not doing what you might expect. That’s where the UDP comes in :)

#149020

You must be logged in to reply to this topic.