Examples/applications
10.1 Basic principles of socket programming, exemplary in C
RF182C communication module
82
Operating Instructions, 10/2010
10.1.2
Basic client/server principle
$FWLYDWLRQRIWKHVHUYHU
(VWDEOLVKFRQQHFWLRQ
5HFHLYHZULWHGDWD
&ORVHFRQQHFWLRQ
6HUYHU
&OLHQW
6RFNHW
%LQG
/LVWHQ
$FFHSW
&ORVH
5HFY6HQG
6RFNHW
&RQQHFW
&ORVH
5HFY6HQG
Figure 10-1 Basic client/server principle
10.1.3
Important basic commands
Commands/functions
Description
Socket()
Initialization and parameter transfer of a new socket
Bind()
Assignment of a user (IP address and port number) to a socket
Lists()
Ready to connect
Connect()
Function for connecting the client to the server via TCP/IP
Accept()
Wait function of server until a client connects
Send()
Sending data
Recv()
Receiving data
Close()
Closing the socket after completing data transmission.
When working with the RF182C, a Close usually only occurs when the
system is shut down.
Note
No parameters or return values of the individual functions are listed here since they may
differ in the different operating systems/programming languages.
The names of the functions are examples only, they may differ in the operating
systems/programming languages. These function examples are limited to the basic
principles of the client/server representation – only a partial example of the functions is
shown.
Содержание RF182C
Страница 12: ...Description RF182C communication module 12 Operating Instructions 10 2010 ...
Страница 20: ...Mounting 3 5 Disassembling the RF182C RF182C communication module 20 Operating Instructions 10 2010 ...
Страница 66: ...Maintenance and Service 7 3 Reader update RF182C communication module 66 Operating Instructions 10 2010 ...
Страница 70: ...Diagnostics 8 1 Diagnostics using LEDs RF182C communication module 70 Operating Instructions 10 2010 ...
Страница 122: ...Command and acknowledgement telegrams RF182C communication module 122 Operating Instructions 10 2010 ...
Страница 128: ...Service support RF182C communication module 128 Operating Instructions 10 2010 ...