private void Receiver() { while (IsRunningThread) { if (micomInput != null) { var receivedData = Subscribe(); micomInput.SetDataStream(receivedData); } ThreadWait(); } }
private void Receiver() { while (true) { if (micomInput == null) { continue; } var receivedData = Subscribe(); micomInput.SetDataStream(receivedData); Thread.SpinWait(5); } }