gw.UplinkRxInfo
*/
class UplinkRxInfo extends \Google\Protobuf\Internal\Message
{
/**
* Gateway ID.
*
* Generated from protobuf field string gateway_id = 1;
*/
protected $gateway_id = '';
/**
* Uplink ID.
*
* Generated from protobuf field uint32 uplink_id = 2;
*/
protected $uplink_id = 0;
/**
* Gateway RX time (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Timestamp gw_time = 3;
*/
protected $gw_time = null;
/**
* Network Server RX time (set by the NS on receiving the uplink).
*
* Generated from protobuf field .google.protobuf.Timestamp ns_time = 17;
*/
protected $ns_time = null;
/**
* RX time as time since GPS epoch (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 4;
*/
protected $time_since_gps_epoch = null;
/**
* Fine-timestamp.
* This timestamp can be used for TDOA based geolocation.
*
* Generated from protobuf field .google.protobuf.Duration fine_time_since_gps_epoch = 5;
*/
protected $fine_time_since_gps_epoch = null;
/**
* RSSI.
*
* Generated from protobuf field int32 rssi = 6;
*/
protected $rssi = 0;
/**
* SNR.
* Note: only available for LoRa modulation.
*
* Generated from protobuf field float snr = 7;
*/
protected $snr = 0.0;
/**
* Channel.
*
* Generated from protobuf field uint32 channel = 8;
*/
protected $channel = 0;
/**
* RF chain.
*
* Generated from protobuf field uint32 rf_chain = 9;
*/
protected $rf_chain = 0;
/**
* Board.
*
* Generated from protobuf field uint32 board = 10;
*/
protected $board = 0;
/**
* Antenna.
*
* Generated from protobuf field uint32 antenna = 11;
*/
protected $antenna = 0;
/**
* Location.
*
* Generated from protobuf field .common.Location location = 12;
*/
protected $location = null;
/**
* Gateway specific context.
* This value must be returned to the gateway on (Class-A) downlink.
*
* Generated from protobuf field bytes context = 13;
*/
protected $context = '';
/**
* Additional gateway meta-data.
*
* Generated from protobuf field map metadata = 15;
*/
private $metadata;
/**
* CRC status.
*
* Generated from protobuf field .gw.CRCStatus crc_status = 16;
*/
protected $crc_status = 0;
/**
* Constructor.
*
* @param array $data {
* Optional. Data for populating the Message object.
*
* @type string $gateway_id
* Gateway ID.
* @type int $uplink_id
* Uplink ID.
* @type \Google\Protobuf\Timestamp $gw_time
* Gateway RX time (set if the gateway has a GNSS module).
* @type \Google\Protobuf\Timestamp $ns_time
* Network Server RX time (set by the NS on receiving the uplink).
* @type \Google\Protobuf\Duration $time_since_gps_epoch
* RX time as time since GPS epoch (set if the gateway has a GNSS module).
* @type \Google\Protobuf\Duration $fine_time_since_gps_epoch
* Fine-timestamp.
* This timestamp can be used for TDOA based geolocation.
* @type int $rssi
* RSSI.
* @type float $snr
* SNR.
* Note: only available for LoRa modulation.
* @type int $channel
* Channel.
* @type int $rf_chain
* RF chain.
* @type int $board
* Board.
* @type int $antenna
* Antenna.
* @type \Chirpstack\Common\Location $location
* Location.
* @type string $context
* Gateway specific context.
* This value must be returned to the gateway on (Class-A) downlink.
* @type array|\Google\Protobuf\Internal\MapField $metadata
* Additional gateway meta-data.
* @type int $crc_status
* CRC status.
* }
*/
public function __construct($data = NULL) {
\GPBMetadata\Chirpstack\Gateway\Gw::initOnce();
parent::__construct($data);
}
/**
* Gateway ID.
*
* Generated from protobuf field string gateway_id = 1;
* @return string
*/
public function getGatewayId()
{
return $this->gateway_id;
}
/**
* Gateway ID.
*
* Generated from protobuf field string gateway_id = 1;
* @param string $var
* @return $this
*/
public function setGatewayId($var)
{
GPBUtil::checkString($var, True);
$this->gateway_id = $var;
return $this;
}
/**
* Uplink ID.
*
* Generated from protobuf field uint32 uplink_id = 2;
* @return int
*/
public function getUplinkId()
{
return $this->uplink_id;
}
/**
* Uplink ID.
*
* Generated from protobuf field uint32 uplink_id = 2;
* @param int $var
* @return $this
*/
public function setUplinkId($var)
{
GPBUtil::checkUint32($var);
$this->uplink_id = $var;
return $this;
}
/**
* Gateway RX time (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Timestamp gw_time = 3;
* @return \Google\Protobuf\Timestamp|null
*/
public function getGwTime()
{
return $this->gw_time;
}
public function hasGwTime()
{
return isset($this->gw_time);
}
public function clearGwTime()
{
unset($this->gw_time);
}
/**
* Gateway RX time (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Timestamp gw_time = 3;
* @param \Google\Protobuf\Timestamp $var
* @return $this
*/
public function setGwTime($var)
{
GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
$this->gw_time = $var;
return $this;
}
/**
* Network Server RX time (set by the NS on receiving the uplink).
*
* Generated from protobuf field .google.protobuf.Timestamp ns_time = 17;
* @return \Google\Protobuf\Timestamp|null
*/
public function getNsTime()
{
return $this->ns_time;
}
public function hasNsTime()
{
return isset($this->ns_time);
}
public function clearNsTime()
{
unset($this->ns_time);
}
/**
* Network Server RX time (set by the NS on receiving the uplink).
*
* Generated from protobuf field .google.protobuf.Timestamp ns_time = 17;
* @param \Google\Protobuf\Timestamp $var
* @return $this
*/
public function setNsTime($var)
{
GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
$this->ns_time = $var;
return $this;
}
/**
* RX time as time since GPS epoch (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 4;
* @return \Google\Protobuf\Duration|null
*/
public function getTimeSinceGpsEpoch()
{
return $this->time_since_gps_epoch;
}
public function hasTimeSinceGpsEpoch()
{
return isset($this->time_since_gps_epoch);
}
public function clearTimeSinceGpsEpoch()
{
unset($this->time_since_gps_epoch);
}
/**
* RX time as time since GPS epoch (set if the gateway has a GNSS module).
*
* Generated from protobuf field .google.protobuf.Duration time_since_gps_epoch = 4;
* @param \Google\Protobuf\Duration $var
* @return $this
*/
public function setTimeSinceGpsEpoch($var)
{
GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
$this->time_since_gps_epoch = $var;
return $this;
}
/**
* Fine-timestamp.
* This timestamp can be used for TDOA based geolocation.
*
* Generated from protobuf field .google.protobuf.Duration fine_time_since_gps_epoch = 5;
* @return \Google\Protobuf\Duration|null
*/
public function getFineTimeSinceGpsEpoch()
{
return $this->fine_time_since_gps_epoch;
}
public function hasFineTimeSinceGpsEpoch()
{
return isset($this->fine_time_since_gps_epoch);
}
public function clearFineTimeSinceGpsEpoch()
{
unset($this->fine_time_since_gps_epoch);
}
/**
* Fine-timestamp.
* This timestamp can be used for TDOA based geolocation.
*
* Generated from protobuf field .google.protobuf.Duration fine_time_since_gps_epoch = 5;
* @param \Google\Protobuf\Duration $var
* @return $this
*/
public function setFineTimeSinceGpsEpoch($var)
{
GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class);
$this->fine_time_since_gps_epoch = $var;
return $this;
}
/**
* RSSI.
*
* Generated from protobuf field int32 rssi = 6;
* @return int
*/
public function getRssi()
{
return $this->rssi;
}
/**
* RSSI.
*
* Generated from protobuf field int32 rssi = 6;
* @param int $var
* @return $this
*/
public function setRssi($var)
{
GPBUtil::checkInt32($var);
$this->rssi = $var;
return $this;
}
/**
* SNR.
* Note: only available for LoRa modulation.
*
* Generated from protobuf field float snr = 7;
* @return float
*/
public function getSnr()
{
return $this->snr;
}
/**
* SNR.
* Note: only available for LoRa modulation.
*
* Generated from protobuf field float snr = 7;
* @param float $var
* @return $this
*/
public function setSnr($var)
{
GPBUtil::checkFloat($var);
$this->snr = $var;
return $this;
}
/**
* Channel.
*
* Generated from protobuf field uint32 channel = 8;
* @return int
*/
public function getChannel()
{
return $this->channel;
}
/**
* Channel.
*
* Generated from protobuf field uint32 channel = 8;
* @param int $var
* @return $this
*/
public function setChannel($var)
{
GPBUtil::checkUint32($var);
$this->channel = $var;
return $this;
}
/**
* RF chain.
*
* Generated from protobuf field uint32 rf_chain = 9;
* @return int
*/
public function getRfChain()
{
return $this->rf_chain;
}
/**
* RF chain.
*
* Generated from protobuf field uint32 rf_chain = 9;
* @param int $var
* @return $this
*/
public function setRfChain($var)
{
GPBUtil::checkUint32($var);
$this->rf_chain = $var;
return $this;
}
/**
* Board.
*
* Generated from protobuf field uint32 board = 10;
* @return int
*/
public function getBoard()
{
return $this->board;
}
/**
* Board.
*
* Generated from protobuf field uint32 board = 10;
* @param int $var
* @return $this
*/
public function setBoard($var)
{
GPBUtil::checkUint32($var);
$this->board = $var;
return $this;
}
/**
* Antenna.
*
* Generated from protobuf field uint32 antenna = 11;
* @return int
*/
public function getAntenna()
{
return $this->antenna;
}
/**
* Antenna.
*
* Generated from protobuf field uint32 antenna = 11;
* @param int $var
* @return $this
*/
public function setAntenna($var)
{
GPBUtil::checkUint32($var);
$this->antenna = $var;
return $this;
}
/**
* Location.
*
* Generated from protobuf field .common.Location location = 12;
* @return \Chirpstack\Common\Location|null
*/
public function getLocation()
{
return $this->location;
}
public function hasLocation()
{
return isset($this->location);
}
public function clearLocation()
{
unset($this->location);
}
/**
* Location.
*
* Generated from protobuf field .common.Location location = 12;
* @param \Chirpstack\Common\Location $var
* @return $this
*/
public function setLocation($var)
{
GPBUtil::checkMessage($var, \Chirpstack\Common\Location::class);
$this->location = $var;
return $this;
}
/**
* Gateway specific context.
* This value must be returned to the gateway on (Class-A) downlink.
*
* Generated from protobuf field bytes context = 13;
* @return string
*/
public function getContext()
{
return $this->context;
}
/**
* Gateway specific context.
* This value must be returned to the gateway on (Class-A) downlink.
*
* Generated from protobuf field bytes context = 13;
* @param string $var
* @return $this
*/
public function setContext($var)
{
GPBUtil::checkString($var, False);
$this->context = $var;
return $this;
}
/**
* Additional gateway meta-data.
*
* Generated from protobuf field map metadata = 15;
* @return \Google\Protobuf\Internal\MapField
*/
public function getMetadata()
{
return $this->metadata;
}
/**
* Additional gateway meta-data.
*
* Generated from protobuf field map metadata = 15;
* @param array|\Google\Protobuf\Internal\MapField $var
* @return $this
*/
public function setMetadata($var)
{
$arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING);
$this->metadata = $arr;
return $this;
}
/**
* CRC status.
*
* Generated from protobuf field .gw.CRCStatus crc_status = 16;
* @return int
*/
public function getCrcStatus()
{
return $this->crc_status;
}
/**
* CRC status.
*
* Generated from protobuf field .gw.CRCStatus crc_status = 16;
* @param int $var
* @return $this
*/
public function setCrcStatus($var)
{
GPBUtil::checkEnum($var, \Chirpstack\Gateway\CRCStatus::class);
$this->crc_status = $var;
return $this;
}
}