|
|
@@ -29,7 +29,7 @@ namespace HBLConsole.Business |
|
|
|
else MessageLog.GetInstance.Show($"设备{InternetInfo.DeviceName}阿里云连接失败.不能上报业务信息"); |
|
|
|
string NameSpace = $"HBLConsole.{GeneralConfig.DeviceType}";//Load 加载的是dll的名称,GetType获取的是全命名空间下的类 |
|
|
|
Type type = Assembly.Load(NameSpace).GetType($"{NameSpace}.Control_{GeneralConfig.DeviceType}"); |
|
|
|
control = Activator.CreateInstance(type) as IControl; |
|
|
|
control = (IControl)type?.GetProperty("Instance").GetValue(null); |
|
|
|
} |
|
|
|
/// <summary> |
|
|
|
/// 是否连接成功 |
|
|
@@ -67,13 +67,14 @@ namespace HBLConsole.Business |
|
|
|
new DevSXBase { SXMC="设备软件",SXLX="上位机",SXStatus=true } |
|
|
|
} |
|
|
|
}); |
|
|
|
|
|
|
|
bool IsAllowRun = GetTypeValue<bool>("AllowRun"); |
|
|
|
bool TemperatureReached = GetTypeValue<bool>("TemperatureReached"); |
|
|
|
bool MissingBowl = GetTypeValue<bool>("MissingBowl"); |
|
|
|
bool TurntableLowerLimit = GetTypeValue<bool>("TurntableLowerLimit"); |
|
|
|
|
|
|
|
//设置扩展属性与状态,连接上机器人后才会处罚 |
|
|
|
if (IsAllowRun) |
|
|
|
if (GeneralConfig.Healthy) |
|
|
|
{ |
|
|
|
iOTDevSXModel.SetKZSX(new DevSX |
|
|
|
{ |
|
|
@@ -117,7 +118,7 @@ namespace HBLConsole.Business |
|
|
|
{ |
|
|
|
ThreadOperate.GetInstance.StartLong(new Action(() => |
|
|
|
{ |
|
|
|
if (iSLinks && GeneralConfig.DeviceType.ToString() == "MO7RKS") |
|
|
|
if (iSLinks && GeneralConfig.DeviceType.ToString() == "MORKS") |
|
|
|
{ |
|
|
|
SetData(); |
|
|
|
IOTDev.GetInstance().IOT_Publish(IOTDev.PubTopic, iOTDevSXModel.Tojson()); |
|
|
|