PingResponse
PingResponse

Represents the response to a Long Ping Node command

Functions
PingResponse
PingResponse()

Creates a PingResponse with default values

PingResponse
PingResponse(
bool success,
int16 nodeRssi,
int16 baseRssi
)

Creates a PingResponse with the given parameters

Parameters
success
bool

Whether or not the Long Ping response was a success

nodeRssi
int16

The node RSSI value received in the Long Ping response

baseRssi
int16

The base station RSSI value received in the Long Ping response

ResponseSuccess
static PingResponse ResponseSuccess(
int16 nodeRssi,
int16 baseRssi
)

Creates a PingResponse with a successful response

Parameters
nodeRssi
int16

the node RSSI from the response

baseRssi
int16

the base station RSSI from the response

Returns

A PingResponse representing a success response from the LongPing node command

ResponseFail
static PingResponse ResponseFail()

Creates a PingResponse with a fail response

Returns

A PingResponse representing a failed response from the LongPing Node command

Variables
m_success
bool m_success

Whether or not the Long Ping response was a success

m_nodeRssi
int16 m_nodeRssi

The node RSSI value received in the Long Ping response

m_baseRssi
int16 m_baseRssi

The base station RSSI value received in the Long Ping response

Functions
success
bool success() const

Gets whether or not the Long Ping command was a success (the node responded).

Returns

true if the Long Ping command was a success, false otherwise.

nodeRssi
int16 nodeRssi() const

Gets the node RSSI that was returned with the response (if success() returns true).  This is the signal strength at which the Node received the BaseStation's command packet.

Returns

The node RSSI that was returned with the response

baseRssi
int16 baseRssi() const

Gets the base station RSSI that was returned with the response (if success() returns true).  This is the signal strength at which the BaseStation received the Nodes's response packet.

Returns

The base station RSSI that was returned with the response.