ofxOsc client over LAN

Hello, I’m having a hard time setting up an ofxOscRecevier so it’s able to get messages from an Android TV app that is serving them using JavaOSC.

There is no rooter and the Android device is directly connected to my machine through an Ethernet cable, sending packets to the broadcast IP, which, from what I understand should be somehow forwarded to my client machine (as stated here). The setup there looks right since I can capture the OSC messages flowing in Wireshark on both the ethernet and any interface. But somehow, I fail getting those with ofxOsc while using a simple setup like so:

  osc_receiver = make_unique<ofxOscReceiver>();
  osc_receiver->setup(OSC_PORT_IN);

Later on update:

 while (osc_receiver->hasWaitingMessages()) { // this is always false
    ofLogNotice() << "something to be done here";
    ofxOscMessage msg;
    osc_receiver->getNextMessage(&msg);

    ofLogNotice() << "next message: " << msg;
  }

Am I missing something like routing or port forwarding? Has anyone succeeded on implementing a similar setup?

1 Like

Have you tried your code without using a unique pointer for the ofxOscReceiver? While it seems like that should work OK, there may be some ownership reasons in the underlying code that will prevent them from working correctly. But this is just a guess, and wish I could help more!

Thanks, I tried what you’ve suggested but sadly no, that didn’t solved my issue.