KatanaNativeInterface
$VERSION$
|
Go to the documentation of this file.
41 #include <sys/types.h>
42 #include <sys/socket.h>
43 #include <netinet/in.h>
44 #include <arpa/inet.h>
49 #endif //WIN32 else LINUX
75 SOCKADDR_IN _socketAddr;
84 struct sockaddr_in _socketAddr;
86 #endif //WIN32 else LINUX
93 static char digit(
const int _val) {
94 return (
char)((int)
'0' + _val);
113 virtual int send(
const void* _buf,
int _size);
117 virtual int recv(
void* _buf,
int _size);
121 virtual int disconnect();
125 #endif //_CDLSOCKET_H_
static char digit(const int _val)
Converts an integer to a char.
int _socketfd
File handler for the socket.
char * _ipAddr
IP Address of the Robot or simulation environment.
virtual int send(const void *_buf, int _sz)=0
Pure function to send data.
Abstract base class for devices.
int _port
Port number of the KNI communication socket.
int _len
Length of the message.
Encapsulates the socket communication device.
virtual int recv(void *_buf, int _sz)=0
Pure function to receive data.