using System;
|
using System.Text;
|
|
namespace HDL_ON.DriverLayer
|
{
|
public class A_Protocal_Common
|
{
|
|
|
|
}
|
|
/// <summary>
|
/// 本地通讯数据
|
/// </summary>
|
public class LocalCommunicationData
|
{
|
public string Topic;
|
public int Length;
|
|
public string BodyDataString;
|
|
}
|
|
/// <summary>
|
/// 通讯回复有效数据
|
/// </summary>
|
public class ResponsePack
|
{
|
public string id;
|
public string code;
|
public string time_stamp;
|
public object objects;
|
}
|
|
/// <summary>
|
/// 通讯主题
|
/// </summary>
|
public class CommunicationTopic
|
{
|
static CommunicationTopic _ct;
|
public static CommunicationTopic ct
|
{
|
get
|
{
|
if (_ct == null)
|
{
|
_ct = new CommunicationTopic();
|
}
|
return _ct;
|
}
|
}
|
/// <summary>
|
/// 搜索本地网关
|
/// </summary>
|
public const string SearchLoaclGateway = "/user/all/custom/gateway/search";
|
/// <summary>
|
/// 搜索网关回复
|
/// </summary>
|
public const string SearchLoaclGatewayReply = "/user/all/custom/gateway/search_reply";
|
/// <summary>
|
/// 调试软件上传oid列表
|
/// </summary>
|
public const string AddDeviceOids = "/user/onpro/custom/device/add";
|
/// <summary>
|
/// 调试软件上传功能列表
|
/// </summary>
|
public const string AddFunctions = "/user/onpro/custom/function/attribute/add";
|
/// <summary>
|
/// 调试软件获取appOid列表
|
/// </summary>
|
public const string BusPcGetAppOids = "/user/onpro/custom/device/list/get";
|
/// <summary>
|
/// 调试软件获取appSid列表
|
/// </summary>
|
public const string BusPcGetAppSids = "/user/onpro/custom/function/list/get";
|
|
/// <summary>
|
/// 本地控制功能状态主题
|
/// </summary>
|
public string ControlFunctionTopic
|
{
|
get
|
{
|
return $"/base/{Control.Ins.GatewayId}/thing/property/down";
|
}
|
}
|
/// <summary>
|
/// 读取功能状态
|
/// </summary>
|
public string ReadStatus
|
{
|
get
|
{
|
return $"/base/{Control.Ins.GatewayId}/thing/property/read";
|
}
|
}
|
/// <summary>
|
/// 网关上报设备状态
|
/// </summary>
|
public string GatewayUpStatus
|
{
|
get
|
{
|
return $"/base/{Control.Ins.GatewayId}/thing/property/up";
|
}
|
}
|
}
|
}
|