add unsConnectDone.WaitOne(); in function avls_WriteLine