/// <summary> /// 响应注册数据或心跳数据 /// </summary> /// <param name="protocol"></param> /// <param name="socket"></param> /// <param name="tel"></param> /// <returns></returns> public static bool ResponseRegisterOrHeart(string protocol, Socket socket, string tel) { if (protocol == DTU._ZG_DTU) { return(ZG_DTU.HeartbeatDataHandler(socket)); } else if (protocol == DTU._HD_DTU) { return(HD_DTU.ResponseRegister(socket, tel)); } else if (protocol == DTU._JBT_DTU) { return(JBT_DTU.Response_Reigster(socket, tel)); } else { return(false); } }