static void r_SerialDataReceived(object sender, SerialArduinoMessageEventArgs e) { Console.WriteLine(e.Packet.ToString()); Console.WriteLine("Received:{0} Corrupt: {1}",r.Statistics.ReceivedPackets, r.Statistics.CorruptPackets); }
void wr_SerialMessageReceived(object sender, SerialArduinoMessageEventArgs e) { Dispatcher.Invoke( DispatcherPriority.Send, new Action( () => { lbPackets.Items.Insert(0, e.Packet); } ) ); }