Prosoft-technology MVI69-ADMNET Manuale Utente Pagina 105

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 122
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 104
MVI-ADMNET 'C' Programmable WATTCP API Functions
'C' Programmable Application Development Module with Ethernet Developer's Guide
ProSoft Technology, Inc. Page 105 of 122
February 20, 2013
6.6 ADMNET API Receive Socket Functions
This section describes the ADMNET API Receive Socket functions.
sock_read
Syntax
int sock_read( sock_type *skType, byte *data, int len);
Parameters
skType
Socket that will be used to receive data.
data
Pointer to a buffer that contains data that is received.
len
Length of the data specified to receive.
Description
This function reads data from the socket being passed to the function. The
function will wait until the all the data is read.
Return Value
Number of Bytes that are read to the socket or -1 if an error occurs.
Example
sock_type *socket;
char theBuffer [512];
int len, bytes_receive;
. . .
bytes_receive = sock_read(socket, (byte*)theBuffer, len);
See Also
sock_fastread (page 106)
Vedere la pagina 104
1 2 ... 100 101 102 103 104 105 106 107 108 109 110 ... 121 122

Commenti su questo manuale

Nessun commento