mmmm
mmmm

Reputation: 2471

Should TIdCmdTCPServer and TIdCmdTCPClient be used together?

I am trying to write a server and a set of clients that talk to the server. The server will maintain the status of different clients and allow them to alert the central server when there is a status change. A specialist client will allow the control of the other connected clients.

I have the server as a TIdCmdTCPServer and the clients (at the moment) connect using TIdTCPClient.

If the clients are sending and recieving commands, should they use TIdCmdTCPClient? I have read that the CmdTCPServer and CmdTCPClient are not really used together - is it that they don't have to be used together?

So apologies for the general vagueness of the question, but I have only really just started looking at this and need a sort of heads out before I get bogged down in details.

Thanks for any help

Mark H

Upvotes: 4

Views: 2876

Answers (3)

user3342925
user3342925

Reputation: 9

TIdTCPServer does not receive anything on Android (Bug), The android can only send the data from i tidtcpclient to windows TidTCPServer and not reverse.

Upvotes: 0

Remy Lebeau
Remy Lebeau

Reputation: 597016

It is technically possible to use use TIdCmdTCPClient and TIdCmdTCPServer together, but in general it is not advisable. Those components are designed for processing inbound commands asynchronously. It does not make sense to have a client waiting for server commands, but to have a server waiting for client commands at the same time. That is a good way to deadlock your connection, as they are both waiting for data from each other, and neither is actually sending anything without input first.

Upvotes: 5

Hugues Van Landeghem
Hugues Van Landeghem

Reputation: 6808

Perhaps, you can start by testing demos

Upvotes: 2

Related Questions