修改苏安院实体设备逻辑

This commit is contained in:
joylink_zhangsai 2023-03-12 19:36:30 +08:00
parent c2f3ddc9a0
commit a571e1b897

View File

@ -58,10 +58,10 @@ public class SaySwitchServiceImpl implements RealDeviceService {
boolean r_db = RealDeviceConfig.getBitOf(deviceStatus, configVO.getR_db());
boolean r_fb = RealDeviceConfig.getBitOf(deviceStatus, configVO.getR_fb());
vrSwitch.apply(r_db, r_fb);
config.sync(r_db, r_fb);
//以下操作实体设备的逻辑中防止继电器长期接通的逻辑将定反操视为技能共用3秒冷却技能持续时间也是3秒
if (config.isEnd()) { //此判断既可视为操作是否冷却也可视为持续时间是否耗尽
config.sync(r_db, r_fb);
release(deviceStatus, baseAddr, configVO, channel); //操作持续时间耗尽后断开所有继电器
if (vrSwitch.isTurning()) {
switch (vrSwitch.getCommand()) {