Home > Back-end >  GPRS communication module, PC development train of thought
GPRS communication module, PC development train of thought

Time:10-20

I have a GPRS module, remote send information network host by IP or domain name

Now I want to do with c + + builder PC that the software to accept information available UDP/TCP can

What do I use? The Socket? Or the UDP module??

GPRS module address is not fixed, it is to belong to the kind of dynamic distribution,


Always use it to provide the development kit of secondary development, I want to do myself, studies in this regard, ask the great spirit guide!
]

CodePudding user response:

Can use TIdTcpServer controls

CodePudding user response:

LAN can use UDP

CodePudding user response:

GPRS module fewer words, such as in the order of a few hundred, can consider to use TIdTCPServer

CodePudding user response:

Thank you very much!!
I'll find TIdTCPServer use

CodePudding user response:

reference 1st floor songhtao response:
can use TIdTcpServer controls


reference gzliudan reply: 3/f
GPRS module number less, for example in the order of a few hundred, is can consider to use TIdTCPServer


There is a problem, I used the TIdTCPServer and TIdTCPClient, LAN can be internal communication (Server can receive data, the Client end don't know how to receive data, the Status and no incident in)

But the Service client configuration on the router port mapping [set good, normal communication with development kit before doing program], then GPRS terminal display connection host successful but not registered, but the Service did not produce OnRead produce no OnStatus events, excuse me this what should I do?

For the first time I use, online information is too little, can you help with? Thank you very much!

CodePudding user response:

Description:

I'm native IP 192.168.1.68
IP networks outside 114.252.253.17

On my router configuration DMZ host and port forwarding rules in mapping: 5008

Host the default port 5008,
IdUDPServer1 - & gt; DefaultPort=5008;
IdUDPServer1 - & gt; Active=true;

Then the two events IdUDPServer1UDPRead and IdUDPServer1Status all have no reaction,

[using IdUDPClient send data in the local area network (LAN) is can receive]

CodePudding user response:

TIdTCPClient TIdTCPServer and receive data using the Read series function, the Write function to send data series,

CodePudding user response:

refer to 7th floor gzliudan response:
TIdTCPClient TIdTCPServer and receive data using the Read series function, the Write function to send data series,


Have the data in it should be a IdUDPServer1UDPRead event.
But the bottom access Service, but the Service without the event happened

CodePudding user response:

No OnRead events
The Client want to make a thread
Server is mainly write code in OnExecute events
  • Related