public IGH615MDeviceInfo GetDeviceInfo()
 {
     if (_deviceInfo == null)
     {
         if (!IsConnected)
         {
             return(null);
         }
         using (var session = new SerialPortSession(_commport))
         {
             var cmd = new GetDeviceInfoCommand();
             cmd.Execute(session.Port);
             _deviceInfo = cmd.GetDeviceInfo();
         }
     }
     return(_deviceInfo);
 }
 public IGH615MDeviceInfo GetDeviceInfo()
 {
     if (_deviceInfo == null)
     {
         if (!IsConnected)
         {
             return null;
         }
         using (var session = new SerialPortSession(_commport))
         {
             var cmd = new GetDeviceInfoCommand();
             cmd.Execute(session.Port);
             _deviceInfo = cmd.GetDeviceInfo();
         }
     }
     return _deviceInfo;
 }