close serial connection