Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="NativeSerialPortWrapper"/> class.
 /// </summary>
 /// <param name="config">The configuration settings.</param>
 public NativeSerialPortWrapper(ISerialPortConnectionConfiguration config)
 {
     Configuration = "Com Port: " + config.ComPort;
     port          = new SerialPort(config.ComPort)
     {
         Handshake = config.Handshake,
         BaudRate  = config.BaudRate,
         Parity    = config.Parity,
         DataBits  = config.DataBits,
         StopBits  = config.StopBits,
     };
 }
Пример #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EmvPedConnection"/> class.
 /// </summary>
 internal EmvPedConnection(ISerialPortConnectionConfiguration configuration)
     : this(new NativeSerialPortWrapper(configuration))
 {
 }