@nathanblanchard12 wrote:
This is my code and for some reason it doesn't work.
Basically I'm using port 20 to send and receive messages but c++ is not getting it. I tested it using java and it worked fine. Why isn't this working.void ofApp::setup()
{
udpConnection.Create();
udpConnection.Bind(20);
udpConnection.SetNonBlocking(true);
}//--------------------------------------------------------------
void ofApp::update(){
char udpMessage[1000];
udpConnection.Receive(udpMessage, 20);
string message = udpMessage;
ofLog() << udpMessage;
}
Posts: 3
Participants: 1