Client-Server Socket Connection between HoloLens and PC?

FraDepaFraDepa
edited December 6 in Questions And Answers

I am trying to develop two different applications that can exchange data using sockets. The PC is the Server, whereas the HoloLens is the Client. I have been able to develop them using Unity3D for both applications and the LiteNetLib library.(https://github.com/RevenantX/LiteNetLib). Now I would like to achieve the same result without using the LiteNetLib library. I tried with System.Net.Sockets (https://docs.microsoft.com/it-it/dotnet/framework/network-programming/asynchronous-client-socket-example) but it does not compile. Did anyone try to make socket connections using c# libraries? Moreover, did anyone try to make a socket connection between a HoloLens Client and a Java Server?
Thank you in advance :)

Tagged:

Answers

  • It's a little old now but I wrote a simple example of communication between a desktop (i.e. 2D XAML UI) app and a HoloLens app (i.e. 3D Unity UI) here on my site a while ago.

    If I remember right, this tries to take an "automatic" approach to connecting the socket client to the socket server by advertising the details of the server over bluetooth so that the client can just 'magically' find it. If you don't want those pieces (or any other pieces) you should be able to just remove them. This code looks to be using Windows.Networking.Sockets to function.

    I hope that helps :smile:

Sign In or Register to comment.