Hello, i'm currently working on a Project in which parameters have to be controlled over the PC (only for Prototyping later over an app -> so i can't use the Bela GUI). Does someone know how to set up the connection with OSC? On the PC i would like to use the Software "Open Stage Control". I modified the Osc-example so I could detect a message, but i'm not receiving anything.
Thanks in advance!
#include <Bela.h>
#include <libraries/OscSender/OscSender.h>
#include <libraries/OscReceiver/OscReceiver.h>
OscReceiver oscReceiver;
OscSender oscSender;
int localPort = 7000;
int remotePort = 7001;
const char* remoteIp = "127.0.0.1"; //Probably use the Address from whatismyipaddress.com?
void on_receive(oscpkt::Message msg, void arg)
{
printf("on_receive\n");
if(msg->match("/osc-test")){
printf("received a message\n");
}
}
bool setup(BelaContext context, void userData)
{
printf("setup\n");
oscReceiver.setup(localPort, on_receive);
oscSender.setup(remotePort, remoteIp);
oscSender.newMessage("/osc-setup").send();
return true;
}
