protected override byte[] Transmit(byte[] data) { this.BeginAtomic(); try { if (this.connected) { IntPtr Handle = this.AcquireHandle(); byte[] Response = ScpCommands.SendApdu(Handle, data); this.ReleaseHandle(); return(Response); } else { throw new SmartCardNotConnectedException(this.SmartCard); } } finally { this.EndAtomic(); } }