JS8Call-Improved master
Loading...
Searching...
No Matches
APRSISClient Class Reference

APRS-IS client responsible for sending and receiving APRS frames. More...

#include <APRSISClient.h>

Inheritance diagram for APRSISClient:
Collaboration diagram for APRSISClient:

Public Slots

void setIncomingRelayEnabled (bool enabled)
 Enable or disable persistent inbound message relay.
void setSkipPercent (float skipPercent)
void setServer (QString host, quint16 port)
void setPaused (bool paused)
void setLocalStation (QString mycall, QString passcode)
void enqueueSpot (QString by_call, QString from_call, QString grid, QString comment)
 Enqueue a spot frame for APRS-IS.
void enqueueThirdParty (QString by_call, QString from_call, QString text)
 Enqueue a third-party message frame for APRS-IS.
void enqueueMessageAck (QString from_call, QString to_call, QString messageId)
 Enqueue a standard APRS message ACK frame.
void sendReports ()

Signals

void messageReceived (QString from, QString to, QString message, QString messageId)
 Emitted when a parsed APRS-IS message is received.

Public Member Functions

 APRSISClient (QString host, quint16 port, QObject *parent=nullptr)
 Construct a new APRSISClient object.
bool isPasscodeValid ()
void enqueueRaw (QString aprsFrame)
 Enqueue a raw APRS frame for APRS-IS.
void processQueue (bool disconnect=true)
 Process the APRS-IS frame queue.

Static Public Member Functions

static quint32 hashCallsign (QString callsign)
 Compute APRS-IS passcode for a callsign.
static QString loginFrame (QString callsign, QString filter=QString())
 Build an APRS-IS login frame.
static QPair< float, float > grid2deg (QString grid)
 Convert grid locator to degrees.
static QPair< QString, QString > grid2aprs (QString grid)
 Convert grid locator to APRS format.
static QString stripSSID (QString call)
 Strip SSID from callsign.
static QString replaceCallsignSuffixWithSSID (QString call, QString base)
 Replace callsign suffix with SSID.

Detailed Description

APRS-IS client responsible for sending and receiving APRS frames.

Constructor & Destructor Documentation

◆ APRSISClient()

APRSISClient::APRSISClient ( QString host,
quint16 port,
QObject * parent = nullptr )

Construct a new APRSISClient object.

Construct a new APRSISClient::APRSISClient object.

Parameters
hostAPRS-IS server host.
portAPRS-IS server port.
parentQObject parent.
host
port
parent

Member Function Documentation

◆ enqueueMessageAck

void APRSISClient::enqueueMessageAck ( QString from_call,
QString to_call,
QString messageId )
slot

Enqueue a standard APRS message ACK frame.

Enqueue a standard APRS message ACK frame for APRS-IS.

Parameters
from_callSource callsign for the ACK message.
to_callDestination callsign being acknowledged.
messageIdAPRS message identifier to acknowledge.
from_callSource callsign (appears as the message sender).
to_callDestination callsign to acknowledge.
messageIdAPRS message identifier (preserved exactly).
Here is the call graph for this function:
Here is the caller graph for this function:

◆ enqueueRaw()

void APRSISClient::enqueueRaw ( QString aprsFrame)

Enqueue a raw APRS frame for APRS-IS.

Parameters
aprsFrame
Here is the caller graph for this function:

◆ enqueueSpot

void APRSISClient::enqueueSpot ( QString by_call,
QString from_call,
QString grid,
QString comment )
slot

Enqueue a spot frame for APRS-IS.

Parameters
by_call
from_call
grid
comment
Here is the call graph for this function:
Here is the caller graph for this function:

◆ enqueueThirdParty

void APRSISClient::enqueueThirdParty ( QString by_call,
QString from_call,
QString text )
slot

Enqueue a third-party message frame for APRS-IS.

Parameters
by_call
from_call
text
Here is the call graph for this function:
Here is the caller graph for this function:

◆ grid2aprs()

QPair< QString, QString > APRSISClient::grid2aprs ( QString grid)
static

Convert grid locator to APRS format.

Parameters
grid
Returns
QPair<QString, QString>
Here is the call graph for this function:
Here is the caller graph for this function:

◆ grid2deg()

QPair< float, float > APRSISClient::grid2deg ( QString locator)
static

Convert grid locator to degrees.

Parameters
locator
Returns
QPair<float, float>
Here is the call graph for this function:
Here is the caller graph for this function:

◆ hashCallsign()

quint32 APRSISClient::hashCallsign ( QString callsign)
static

Compute APRS-IS passcode for a callsign.

Parameters
callsignCallsign to hash.
Returns
APRS-IS passcode.
Parameters
callsign
Returns
quint32
Here is the caller graph for this function:

◆ loginFrame()

QString APRSISClient::loginFrame ( QString callsign,
QString filter = QString() )
static

Build an APRS-IS login frame.

Create a login frame for APRS-IS.

Parameters
callsignLocal station callsign.
filterOptional APRS-IS filter string.
Returns
Login frame string.
Parameters
callsign
filter
Returns
QString
Here is the call graph for this function:
Here is the caller graph for this function:

◆ messageReceived

void APRSISClient::messageReceived ( QString from,
QString to,
QString message,
QString messageId )
signal

Emitted when a parsed APRS-IS message is received.

Parameters
fromAPRS sender callsign.
toAPRS destination callsign.
messageAPRS message payload without message ID suffix.
messageIdAPRS message identifier (if present).
Here is the caller graph for this function:

◆ processQueue()

void APRSISClient::processQueue ( bool disconnect = true)

Process the APRS-IS frame queue.

Parameters
disconnect
Here is the caller graph for this function:

◆ replaceCallsignSuffixWithSSID()

QString APRSISClient::replaceCallsignSuffixWithSSID ( QString call,
QString base )
static

Replace callsign suffix with SSID.

Parameters
call
base
Returns
QString

◆ setIncomingRelayEnabled

void APRSISClient::setIncomingRelayEnabled ( bool enabled)
slot

Enable or disable persistent inbound message relay.

Enable or disable persistent inbound relay connections.

Parameters
enabledTrue to keep a connected session for inbound relay.

When enabled, the client keeps an active connection so inbound APRS messages can be received and relayed. When disabled, connections are closed once the outbound queue drains.

Parameters
enabled
Here is the call graph for this function:
Here is the caller graph for this function:

◆ stripSSID()

QString APRSISClient::stripSSID ( QString call)
static

Strip SSID from callsign.

Parameters
call
Returns
QString

The documentation for this class was generated from the following files: