Exemple #1
0
    DiagnosticPacket::DiagnosticPacket(const WirelessPacket& packet)
    {
        //construct the data packet from the wireless packet passed in
        m_nodeAddress              = packet.nodeAddress();
        m_deliveryStopFlags        = packet.deliveryStopFlags();
        m_type                     = packet.type();
        m_nodeRSSI                 = WirelessTypes::UNKNOWN_RSSI;
        m_baseRSSI                 = packet.baseRSSI();
        m_frequency                = packet.frequency();
        m_payload                  = packet.payload();

        //parse the data sweeps in the packet
        parseSweeps();
    }
    BufferedLdcPacket::BufferedLdcPacket(const WirelessPacket& packet)
    {
        //construct the data packet from the wireless packet passed in
        m_nodeAddress        = packet.nodeAddress();
        m_deliveryStopFlags = packet.deliveryStopFlags();
        m_type                = packet.type();
        m_nodeRSSI            = WirelessTypes::UNKNOWN_RSSI;
        m_baseRSSI            = packet.baseRSSI();
        m_frequency            = packet.frequency();
        m_payload            = packet.payload();
        m_payloadOffsetChannelData = PAYLOAD_OFFSET_CHANNEL_DATA;

        //parse the data sweeps in the packet
        parseSweeps();
    }
	HclSmartBearing_RawPacket::HclSmartBearing_RawPacket(const WirelessPacket& packet)
	{
		//construct the data packet from the wireless packet passed in
		m_nodeAddress		= packet.nodeAddress();
		m_deliveryStopFlags = packet.deliveryStopFlags();
		m_type				= packet.type();
		m_nodeRSSI			= packet.nodeRSSI();
		m_baseRSSI			= packet.baseRSSI();
		m_frequency			= packet.frequency();
		m_payload			= packet.payload();
		m_payloadOffsetChannelData = 0;	//not used for these packets

		//parse the data sweeps in the packet
		parseSweeps();
	}