Initial commit of files
This commit is contained in:
65
include/libgps++/NtripClient.h
Normal file
65
include/libgps++/NtripClient.h
Normal file
@ -0,0 +1,65 @@
|
||||
//
|
||||
// Linux GPS
|
||||
//
|
||||
|
||||
/* prevent multiple inclusions */
|
||||
#ifndef __NtripClient__
|
||||
#define __NtripClient__
|
||||
|
||||
/* includes *****************************************************************/
|
||||
|
||||
#include "TcpClient.h"
|
||||
#include "netlib.h"
|
||||
|
||||
/* defines ******************************************************************/
|
||||
|
||||
/* macros *******************************************************************/
|
||||
|
||||
/* structs & typedefs *******************************************************/
|
||||
|
||||
|
||||
/* c class definitions ******************************************************/
|
||||
|
||||
//
|
||||
// GpsLinux because it depennds on GPSd, the HAMLIB and NMEAP libraries
|
||||
//
|
||||
class NtripClient : public TcpClient {
|
||||
// public data
|
||||
public:
|
||||
char Uri[1024];
|
||||
|
||||
protected:
|
||||
unsigned long count;
|
||||
|
||||
// private data
|
||||
private:
|
||||
|
||||
// private methods
|
||||
|
||||
// static data
|
||||
|
||||
// public methods
|
||||
public:
|
||||
// constructors
|
||||
NtripClient();
|
||||
|
||||
// destructor
|
||||
virtual ~NtripClient();
|
||||
|
||||
// virtual functions
|
||||
|
||||
// public methods
|
||||
int NtripConnect( const char *host, const char *service,
|
||||
const char *user = "anonymous", const char *pass = "",
|
||||
const char *path = "" );
|
||||
int NtripConnect( const char *uri );
|
||||
int NtripReconnect( void ) {return NtripConnect( Uri ); };
|
||||
void NtripClose(void) {Close();};
|
||||
|
||||
int NtripRead( unsigned char *buf, int max );
|
||||
int NtripWrite( const unsigned char *buf, int max )
|
||||
{return TcpClient::Send((const char *)buf,max);};
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user