getnamo / SocketIOClient-Unreal

Socket.IO client plugin for the Unreal Engine.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LuminOS untested

getnamo opened this issue · comments

Latest version (v1.0.0) appears to compile for Lumin platform, but it would be helpful to have someone with the actual device test that it works as expected.

Built for Lumin.
Added whitelisting for the modules so that it loads the library for Lumin.
UATHelper: Packaging (Lumin): [3/9] Compile Module.SIOJson.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [6/9] Compile Module.CoreUtility.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [1/9] Compile Module.SocketIOClient.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [4/9] Compile Module.SIOJson.gen.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [5/9] Compile Module.SocketIOLib.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [7/9] Compile Module.CoreUtility.gen.cpp [arm64-lumin]
UATHelper: Packaging (Lumin): [2/9] Compile Module.SocketIOClient.gen.cpp [arm64-lumin]

However, the following error message appears:
"socketio invalid appears to have lost connection"

UE: 4.24.3-11590370+++UE4+Release-4.24
Lumin: 0.98.01

Changes made from master:

--- a/SocketIOClient.uplugin
+++ b/SocketIOClient.uplugin
@@ -26,7 +26,8 @@
"Linux",
"Mac",
"Android",

  •                           "IOS"
    
  •                           "IOS",
    
  •                           "Lumin"
                      ]
              },
              {
    

@@ -39,7 +40,8 @@
"Linux",
"Mac",
"Android",

  •                           "IOS"
    
  •                           "IOS",
    
  •                           "Lumin"
                      ]
              },
              {
    

@@ -52,7 +54,8 @@
"Linux",
"Mac",
"Android",

  •                           "IOS"
    
  •                           "IOS",
    
  •                           "Lumin"
                      ]
              },
              {
    

@@ -65,7 +68,8 @@
"Linux",
"Mac",
"Android",

  •                           "IOS"
    
  •                           "IOS",
    
  •                           "Lumin"
                      ]
              },
              {
    

diff --git a/Source/SocketIOClient/SocketIOClient.Build.cs b/Source/SocketIOClient/SocketIOClient.Build.cs
index d6dccf0..e7c6e9d 100644
--- a/Source/SocketIOClient/SocketIOClient.Build.cs
+++ b/Source/SocketIOClient/SocketIOClient.Build.cs
@@ -47,6 +47,10 @@ public bool LoadLib(ReadOnlyTargetRules Target)
{
isLibrarySupported = true;
}

  •        else if (Target.Platform == UnrealTargetPlatform.Lumin)
    
  •        {
    
  •            isLibrarySupported = true;
    
  •        }
    
           return isLibrarySupported;
       }
    

Interesting, thanks for checking and those are the expected changes for it to run. Though the message socketio invalid appears to have lost connection may just point to a missing server, is this despite a confirmed working server for the client to connect to?

That's correct. I've created a local server and the UE app works when run from the editor. I've also enabled external connections to be made from the server.
Any log files that I should look into?

Keep in mind localhost won't work for a separate device, you'll need your LAN ip at the least e.g. if you're on the 192.168.1.x subnet and let's say your server is on 192.168.1.3, you'd need to input that (e.g. http://191.168.1.3:3000 instead of http://localhost:3000) on the lumin device SocketIOClient component when it's on the same wifi for it connect to it. Either that or a internet reachable IP/domain where the service is hosted.

Yup. I had given the IP address of the local server running on a mac.
Checking with a Windows machine as a client to test now.
That worked.
I've given a http.listen(3000, "0.0.0.0") in the server code.
Isn't that enough to enable external connections?

That should work, in which case I suspect lumin is doing something extra about external internet connections, possibly blocking them. Do you know if e.g. https://github.com/getnamo/socketio-client-ue4#http-json-requests works?

Shouldn't the socketio client be bound for this to work?

The components auto-connect on beginplay so you should see it on the server side if you log connections before sending/binding any events. If it's not connecting, everything else won't work.

For http-json-requests, this doesn't use socket.io at all, just regular http get/post. So if that's not reachable it suggests something on the os level is blocking the connection.

Lumin is a custom fork of android if I remember correctly, so maybe there are some permissions to set?

I saw this post in the Magic Leap documentation:
https://developer.magicleap.com/learn/guides/sdk-unreal-package-third-party-plugin-libraries

What all libraries should be included?

Hmm.. weird.. I hosted a simple server in an AWS EC2 instance.. the MagicLeap connected to it.
I'm really surprised. The server doesn't have any HTTPS support. So in that sense, should be similar to what I have on my laptop, isn't it?
But the bottom line is that your library worked!
Thanks a lot for your responses and over all, making this great library!
If you are still interested in debugging the local server issue, I'm all ears to suggestions.

Maybe your router blocks ports internally? otherwise double check the local ip you're connecting to, great to see it connect though, it should narrow down the configs/setup causing the error for LAN hosted server.

I mean, I had tested it locally with two computers on my LAN. That had worked. A server hosted in a Mac was able to receive connections from a client running on windows in the same WiFi network.

Platform unlikely to be supported.