private void FInClient_Connected(object sender, PinConnectionEventArgs args) { if (FInClient.Count() > 0 && FInClient[0] != null) { FClient = FInClient[0]; FClient.MqttMsgPublished += FClient_MqttMsgPublished; } }