|
|
@@ -2,6 +2,7 @@ package com.zd.netty.sdk;
|
|
|
|
|
|
import com.gg.reader.api.dal.GClient;
|
|
|
import com.gg.reader.api.dal.GServer;
|
|
|
+import com.gg.reader.api.protocol.gx.MsgBaseStop;
|
|
|
import com.zd.common.core.enums.HardwareOperate;
|
|
|
import com.zd.common.core.exception.ServiceException;
|
|
|
import com.zd.netty.service.IService;
|
|
|
@@ -56,7 +57,13 @@ public class DeJuRFIDListenerService implements IService {
|
|
|
String ipAddress = hardware.getIpAddress();
|
|
|
if (serverMap.containsKey(ipAddress)) {
|
|
|
GServer server = serverMap.get(ipAddress);
|
|
|
- server.onGClientConnected= (client, s) -> DeJuRFIDService.stopGpo(client,0);
|
|
|
+ server.onGClientConnected= (client, s) -> {
|
|
|
+ DeJuRFIDService.stopGpo(client,0);
|
|
|
+ MsgBaseStop msg = new MsgBaseStop();
|
|
|
+ // 停止读卡,空闲态
|
|
|
+ client.sendSynMsg(msg);
|
|
|
+ client.close();
|
|
|
+ };
|
|
|
server.close();
|
|
|
log.info(ipAddress + "---监听结束");
|
|
|
}
|