|
|
|
@ -31,7 +31,6 @@ namespace Emergency_platform{
@@ -31,7 +31,6 @@ namespace Emergency_platform{
|
|
|
|
|
string picPath = $"D:/Picture/{DateTime.Now:yyyyMMddHHmmss}.jpeg"; |
|
|
|
|
string videoPath = $"D:/Video/{DateTime.Now:yyyyMMddHHmmss}.mp4"; |
|
|
|
|
//调用轨道机方法 |
|
|
|
|
Console.WriteLine(cabinetId); |
|
|
|
|
using (var httpClient = new HttpClient()) |
|
|
|
|
{ |
|
|
|
|
//发送post请求 |
|
|
|
@ -63,12 +62,19 @@ namespace Emergency_platform{
@@ -63,12 +62,19 @@ namespace Emergency_platform{
|
|
|
|
|
bool guidaoji = true; |
|
|
|
|
while (guidaoji) |
|
|
|
|
{ |
|
|
|
|
if (gui != null && gui.data.type == "0") |
|
|
|
|
|
|
|
|
|
if (gui != null) |
|
|
|
|
{ |
|
|
|
|
guidaoji = false; |
|
|
|
|
CHNetHelp.SetCameraProcess(OperationType.PTZ, poseP, poseT, poseZ, 1, videoPath); |
|
|
|
|
CHNetHelp.JPEG(1, picPath); |
|
|
|
|
if(gui.data.type == "0"){ |
|
|
|
|
guidaoji = false; |
|
|
|
|
CHNetHelp.SetCameraProcess(OperationType.PTZ, poseP, poseT, poseZ, 1, videoPath); |
|
|
|
|
CHNetHelp.JPEG(1, picPath); |
|
|
|
|
}else{ |
|
|
|
|
Console.WriteLine(gui.data.type); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
await Task.Delay(1000); |
|
|
|
|
gui = TcpClientWrapper.SendDataRead(); |
|
|
|
|
} |
|
|
|
|
Console.WriteLine("轨道机运动成功"); |
|
|
|
|
} |
|
|
|
@ -92,6 +98,7 @@ namespace Emergency_platform{
@@ -92,6 +98,7 @@ namespace Emergency_platform{
|
|
|
|
|
this.EGSendMessage(requestPatrol,sender,protocolType); |
|
|
|
|
//socket_commu.Send(dataBytes); |
|
|
|
|
Console.WriteLine("发送成功"); |
|
|
|
|
await Task.Delay(5000); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|