Message bus not working over network

Hi,

I’ve been studying the McLaren Message Bus code by Max Preussner and have been able to get it working in a simplfied version. But I can only get it to work between two instances of the engine on the same computer. When trying to make a connection between two computers (or a computer and an Android phone) on the same subnet, it doesn’t work. I’ve tried setting the EMessageScope to Network ( although that is the default scope ). Now I’m not sure where to look to get this working.

Any suggestions?

Are you running the games with -messaging on the command line?

Hi Max, yes I tried that as well. I’m also wondering how to do that on an Android mobile ( Samsung S6 ).
If there’s no other options to be set, could it be the network itself? Should I check the access point or router settings?

If you’re connecting via WiFi then your wireless network needs to be in the same subnet. In most default router configurations the wireless network is in a separate subnet, i.e. your LAN may be 192.168.x.x and your wireless is 172.x.x.x

When devices are in separate subnets, they will not be able to discover each other, because the multicast group doesn’t cross subnet boundaries (unless you have a special configuration in your router, which most consumer grade routers don’t make available).

In that case, the easiest option is to add the IP address of your Android device to the Static Endpoints list in the Editor’s UdpMessaging plug-in settings. If your device’s IP address is, say, 172.168.1.10 then you would add 172.168.1.10:6666

Thanks Max, I’m aware of all that and all my devices/computers are in the same subnet. So that could not be the problem

Is the UDP Transport enabled in the UdpMessaging plug-in settings?
Do you have a firewall blocking traffic?
Can you fire up the Messaging Debugger and see if you have any instances of FMessageBridge?
Can you see your published messages in the messaging debugger?
Do these messages have any recipients listed?
Is anything in the log?

I’ll check your questions later this week and come back with the results.

Hi Max,

I did some more expiriments and did get it to work on the same subnet, but only when launching the companion to the mobile device.

Looking at the message debugger it showed me the commands over the FMessageBridge but the scope was always “Process”. But when closing the app on the mobile device and starting it disconnected from the computer it still works.

So what could be different between putting the app on the device through “Launch” and packaging and installing the app?

Launch appends -messaging on the command line. We currently require this in game builds, because the UDP transport may not be 100% stable yet and offers no safety nets.

Ok, so how would I start the mobile app on the device with -messaging? I thought messaging was enabled by default on packaged applications?

No, it is disabled by default. We currently use Messaging only for debugging & development purposes. It is not ready for production yet. If you want to enable it, you’ll have to modify FUdpMessagingModule::SupportsNetworkedTransport, I’m afraid.

For 4.13 I’m planning to make it a project setting, so you don’t have to hack Engine code.

Ok, cool. Thats fine for now. So now I know why it was not working in the first place. And now I can extend my test application.
Thanks for your help!

You said you’ve got it to work, cou ld you tell me what you’ve done? Im having the same problem as you had, I hope you remember or someone else can help me out

Hi, I need help, Messenger Bus run on windows and android is ok, but run on IOS ( ipad air 2 ) not work.

So I guess some permissions or something like that are missing to allow the UE4 application to receive data from wifi? Like permission.INTERNET in Android?

Please help me, thank you so much.

Hi gmpreussner , can you help me? I need help, Messenger Bus run on windows and android is ok, but run on IOS ( ipad air 2 ) not work.

So I guess some permissions or something like that are missing to allow the UE4 application to receive data from wifi? Like permission.INTERNET in Android?

Did you figure this out? I have the same problem