EasyManuals Logo

R&S SMB100A User Manual

R&S SMB100A
528 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #269 background imageLoading...
Page #269 background image
Remote Control Basics
R&S
®
SMB100A
254Operating Manual 1407.0806.32 ─ 21
int currentSocketDescr;
SockAddrStruct serverAddress;
HostInfoStruct * currentHostInfo;
bool clientIsConnected;
int receiveBufferSize;
};
TcpClient.cpp
#include <string>
//defines structs for socket handling
#include <netinet/in.h>
using namespace std;
typedef struct sockaddr_in SockAddrStruct;
typedef struct hostent HostInfoStruct;
class TcpClient
{
public:
TcpClient();
~TcpClient();
void connectToServer( string &hostname, int port );
void disconnect( );
void transmit( string &txString );
void receive( string &rxString );
string getCurrentHostName( ) const;
int getCurrentPort( ) const;
private:
string currentHostName;
int currentPort;
int currentSocketDescr;
SockAddrStruct serverAddress;
HostInfoStruct * currentHostInfo;
bool clientIsConnected;
int receiveBufferSize;
};
#include <netdb.h>
#include <netinet/in.h>
#include <unistd.h>
#include "TcpClient.h"
TcpClient::TcpClient()
: currentHostName( "" )
, currentPort( 0 )
, currentSocketDescr( 0 )
, serverAddress ( )
, currentHostInfo( NULL )
, clientIsConnected( false )
, receiveBufferSize( 1024 )
{
}
Starting a Remote Control Session

Table of Contents

Other manuals for R&S SMB100A

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the R&S SMB100A and is the answer not in the manual?

R&S SMB100A Specifications

General IconGeneral
BrandR&S
ModelSMB100A
CategoryInverter
LanguageEnglish