Commit fee6d590 刘韬

1

1 个父辈 036604ff
此文件类型无法预览
...@@ -82,6 +82,28 @@ public class PuYueRFID_FR540SP_C2S ...@@ -82,6 +82,28 @@ public class PuYueRFID_FR540SP_C2S
} }
} }
public bool ReOpen() {
try
{
tcpClient.Close();
}catch(Exception e)
{
}
tcpClient.Dispose();
tcpClient = new TcpClient();
tcpClient.ReceiveTimeout = 1000;
tcpClient.SendTimeout = 100;
try
{
Thread.Sleep(200);
tcpClient.Connect(this.IP, 502);
Thread.Sleep(200);
return true;
}
catch {
return false;
}
}
void Init() void Init()
{ {
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!