| | |
| | | package com.mes.service; |
| | | |
| | | import com.baomidou.dynamic.datasource.annotation.DS; |
| | | import com.mes.entity.GlassInfo; |
| | | import com.mes.entity.userInfo.SysError; |
| | | import com.mes.common.PlcTools.S7control; |
| | | import com.mes.entity.Tempering; |
| | | import com.mes.entity.device.PLCAutoMes; |
| | | import com.mes.entity.device.PlcParameterObject; |
| | | import com.mes.mapper.TemperingMapper; |
| | | import com.mes.mapper.userInfo.SysErrorMapper; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import java.util.List; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service |
| | | @DS("glass_info") |
| | | public class TemperingOverService { |
| | | private final TemperingMapper temperingMapper; |
| | | |
| | | //PlcParameterObject plcmes=PLCAutoMes.PlcMesObject; |
| | | public TemperingOverService(TemperingMapper temperingMapper) { |
| | | this.temperingMapper = temperingMapper; |
| | | } |
| | | //接收出炉信号和炉号 |
| | | public GlassInfo SelectOutGlass (String glassid) { |
| | | GlassInfo GlassInfo = temperingMapper.SelectOutGlass(glassid); |
| | | return GlassInfo; |
| | | } |
| | | //发送确认收到 |
| | | public String SelectOutSignal () { |
| | | |
| | | S7control.getinstance().WriteWord("出炉信号", (short)1); |
| | | return "GlassInfo"; |
| | | } |
| | | //发送确认收到信号 |
| | | public void OverSignal () { |
| | | S7control.getinstance().WriteWord("确认字", (short)1); |
| | | } |
| | | //显示钢化出炉后的版图信息 |
| | | public List <Tempering> SelectOutGlass () { |
| | | return temperingMapper.SelectOutGlass(); |
| | | } |
| | | |
| | | |
| | | } |