Пример #1
0
        private void M_client_MqttMsgPublishReceived(object sender, uPLibrary.Networking.M2Mqtt.Messages.MqttMsgPublishEventArgs e)
        {
            var msg = TTNMessage.DeserialiseMessage(e);

            if (m_msgReceived != null)
            {
                m_msgReceived(msg);
            }
        }
Пример #2
0
        private void M_client_MqttMsgPublishReceived(object sender, uPLibrary.Networking.M2Mqtt.Messages.MqttMsgPublishEventArgs e)
        {
            try
            {
                var msg = TTNMessage.DeserialiseMessage(e);

                if (m_msgReceived != null)
                {
                    m_msgReceived(msg);
                }
            }
            catch
            {
                // Swallow any exceptions during message receive
            }
        }