I recently downloaded the .NET MsgConnect and started looking through the demos.
Using the SendNote, I compiled for UDP.
I set the destination IP to 255.255.255.255 for broadcast, and hit 'Send'.
The message was received in the mcQueue_OnUnhandledMessage event.
However, once the first message is received, no subsequent messages are received. It's almost as if the Queue is still waiting for a reply/confirmation.
If I set the Queue to incactive, then back to active, it will receive one message (as before).
Are there additional settings that need to be in place to be able to receive multiple UDP broadcasts?
Please let me know if you need more information.
Thanks.

If you are building the assembly from source, you can fix the issue easily - in MCUDPSocket.cs find MCUDPReceiverThread.Execute() method and remove the call to Close() method in finally section of try/finally block. I have no idea how it got there.

If you use the shipped assemblies, please wait for an update, which is expected next week with MacOS X support for C++.

I recompiled the source dll.
I made the following change to MCUDPSocket.cs:
(line 1083) FRecvSocket.Close(false); => //FRecvSocket.Close(false);
With the new dll built into the SentNote example, I am now able to receive multiple UDP broadcasts.
However, now for each message I send (using PostMessage since UDP), I receive 3 identical messages.
For example:
Address: 255.255.255.255
Port: 14583
Message: Test Message

Yes, this happens because the message is sent via all available network interfaces. To be able to send only via specific interface, you need to adjust MessengerAddress property. For example, if you set it to 127.0.0.1, you should be able to receive only messages sent to localhost and also receive broadcasts once.

More Info:
I'm running SendNote on Two machines (My local xp64 and a VM XP 32).
Both machines are configured to broadcast using 255.255.255.255.
When I send a message using SendNote on my local machine, I receive three messages (as described in previous post). However, on the 32-bit VM, I only receive one message (as expected).
When I send a message using SendNote on the 32-bit VM, both machines only receive one message.

Sorry for the multiple posts, trying figure this all out.
I changed the mcUDPTransport.MessengerAddress from 0.0.0.0 (default) to 127.0.0.1.
When the destination address is 127.0.0.1, the application receives its own broadcast.
When the destination address is 255.255.255.255, the application does not receive its own broadcast.
More importantly, the application on the 32-bit VM did not receive any of the broadcasts from my local machine (its messengeraddress was changed to 127.0.0.1).

We use cookies to help provide you with the best possible online experience. By using this site, you agree that we may store and access cookies on your device. You can find out more about and set your own preferences here.