How can I connect multiple devices to my server with TCP / IP protocol?

Alcin 1 Reputation point
2022-02-08T07:57:14.933+00:00

I need to write a program that allows many devices to connect to my server at the same time and communicate with the TCP / IP protocol.

The devices will send their imei numbers first, and if I have this imei number in my database, I will connect that client to the server.

Then I have to send and receive information to the appropriate clients using that imei number.

But I do not know how to do it. Can you help me with what I need to do?

Developer technologies .NET Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Lan Huang-MSFT 30,186 Reputation points Microsoft External Staff
    2022-02-08T09:53:07.503+00:00

    Hi @Alcin ,
    You can read these documents to help you.
    WCF uses a Windows service called the Net.TCP Port Sharing Service to facilitate the sharing of TCP ports across multiple processes.
    https://learn.microsoft.com/en-us/dotnet/framework/wcf/feature-details/how-to-enable-the-net-tcp-port-sharing-service
    The WCF TCP transport is optimized for scenarios where WCF is used at both ends of the communication.
    https://learn.microsoft.com/en-us/dotnet/framework/wcf/feature-details/choosing-a-transport#when-to-use-the-tcp-transport
    Queues and reliable sessions are WCF features that enable reliable messaging.
    https://learn.microsoft.com/en-us/dotnet/framework/wcf/feature-details/queues-and-reliable-sessions
    Best regards,
    Lan Huang


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.