예제 #1
0
 public void Connect(PrinterConfigurationModel printer)
 {
     if (SerialPortAdapterRef == null)
     {
         SerialPortAdapterRef = _serialPortAdapter.Connect(
             printer,
             new Action <SerialPortAdapterRef, string>(DataReceivedCallback));
         Printer = printer;
     }
 }
 private void InitailizeSerialPort(SerialPortViewModel serialPort)
 {
     _serialPortAdapter.Connect(serialPort);
     LogMessage(string.Format("Connected to {0}", serialPort.DisplayValue));
 }