Beispiel #1
0
 private void ProcessDeviceEvent(object sender, FeedbackReceivedFromDeviceEventArgs e)
 {
     lock (commandQueue) {
         commandQueue.Add(new ReceivedCommand(sender, e.Command, DateTime.Now, e.Parameters));
         if (Zones != null)
         {
             InvokeTriggerIfFound();
         }
     }
     if (DeviceEventOccurred != null)
     {
         DeviceEventOccurred(sender, e);
     }
 }
        private void processor_irReceivedUpdate(object sender, FeedbackReceivedFromDeviceEventArgs e)
        {
            string paramString = "";

            if (e.Parameters != null)
            {
                foreach (object obj in e.Parameters)
                {
                    paramString = paramString + obj.ToString() + "; ";
                }
            }
            else
            {
                paramString = "N/A";
            }

            AddItemToReceivedBox("Remote: " + sender.ToString() + "; Command: " + e.Command +
                                 "; Parameters: " + paramString + "; Timestamp: " + DateTime.Now.ToString("dd/MM HH:mm"));
        }