private static void Main(string[] args) { var consoleListener = new TextWriterTraceListener(Console.Out); Trace.Listeners.Add(consoleListener); var portName = args.Length > 1 ? args[1] : GetPortName(); using(var conn = new SerialConnection(portName)) { conn.Open(); //conn.WritePriorityMessage("Hello World!"); conn.SetDateTime(DateTime.Now); //conn.Send(Clear()); //Thread.Sleep(10000); //conn.Send(DemoPicture()); //DemoWriteTextCommands(conn); } Console.ReadLine(); }