|
@@ -85,10 +85,6 @@ static webSocketManager *webSocketManagerInstance = nil;
|
|
|
}
|
|
|
|
|
|
KWeakSelf
|
|
|
- //初始化指令通道
|
|
|
- self.commandChannelManager = [[RCCommandChannelManager alloc] init];
|
|
|
- [self initOtherFun];//timer 检测链接情况
|
|
|
-
|
|
|
NSString *wsPort = @"";
|
|
|
if([connectDeviceManager shareInstance].isPingOk
|
|
|
&& [AFNetworkReachabilityManager sharedManager].networkReachabilityStatus == AFNetworkReachabilityStatusReachableViaWiFi){
|
|
@@ -109,6 +105,10 @@ static webSocketManager *webSocketManagerInstance = nil;
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
+ //初始化指令通道
|
|
|
+ self.commandChannelManager = [[RCCommandChannelManager alloc] init];
|
|
|
+ [self initOtherFun];//timer 检测链接情况
|
|
|
+
|
|
|
NSString *instructionsChannelUrl = [NSString stringWithFormat:@"ws://%@:%@/businessChannel",_curIp,wsPort];
|
|
|
|
|
|
if (instructionsChannelUrl && instructionsChannelUrl.length > 0) { //当都有值才可连接
|