bin 3 vuotta sitten
vanhempi
commit
ced9175e10
4 muutettua tiedostoa jossa 18 lisäystä ja 13 poistoa
  1. +7
    -2
      src/main/java/com/ssjl/zhaobiao/guizhou/controller/IotController.java
  2. +2
    -2
      src/main/java/com/ssjl/zhaobiao/guizhou/handle/GZResponseHandle.java
  3. +1
    -1
      src/main/java/com/ssjl/zhaobiao/guizhou/quartz/job/GZSyncSetting.java
  4. +8
    -8
      src/main/resources/application.properties

+ 7
- 2
src/main/java/com/ssjl/zhaobiao/guizhou/controller/IotController.java Näytä tiedosto

@@ -293,10 +293,15 @@ public class IotController {
}
log.info(imei + ",wifi ,v=" + JSON.toJSONString(wifi));
GpsDeviceStatus gpsDeviceStatus = gpsDeviceStatusMapper.selectByImei(imei);
IOTDeviceStatus iotDeviceStatus = IOTDeviceStatus.build(gpsDeviceStatus.getDeviceStatus());
int batty = 50;
if(gpsDeviceStatus != null){
IOTDeviceStatus iotDeviceStatus = IOTDeviceStatus.build(gpsDeviceStatus.getDeviceStatus());
batty = iotDeviceStatus.getBattery();
}

GZDevicePower power = new GZDevicePower();
power.setCharge(false);
power.setPower(iotDeviceStatus.getBattery());
power.setPower(batty);
GZDeviceStatus deviceStatus = new GZDeviceStatus();
LocalDateTime time = LocalDateTime.now();
GZLocationExtend extend = new GZLocationExtend();


+ 2
- 2
src/main/java/com/ssjl/zhaobiao/guizhou/handle/GZResponseHandle.java Näytä tiedosto

@@ -71,9 +71,9 @@ public class GZResponseHandle {
gzRs.setPhone(phone);
gzRs.setImei(sourceImei);
gzRs.setErrorCode(GZResponseStatus.RECEIVE_SUCCESS);
log.info("应答报文:" + ByteUtil.bytesToHexString(gzRs.toBytes()));
// log.info("应答报文:" + ByteUtil.bytesToHexString(gzRs.toBytes()));
byte[] responseRs = gzHttpUtil.send(gzRs.getImei(), gzRs.getPhone(), gzRs);
log.info("应答回复:" + ByteUtil.bytesToHexString(responseRs));
// log.info("应答回复:" + ByteUtil.bytesToHexString(responseRs));
return serviceRs;
// byte[] result = content.process(deviceFlag, flagType, msgIndex, status);



+ 1
- 1
src/main/java/com/ssjl/zhaobiao/guizhou/quartz/job/GZSyncSetting.java Näytä tiedosto

@@ -38,7 +38,7 @@ public class GZSyncSetting extends QuartzJobBean {
GZAskSetting askSetting = new GZAskSetting();
try {
byte[] res = httpUtil.send(device.getImei(), device.getPhone(), askSetting);
System.out.println(ByteUtil.bytesToHexString(res));
// System.out.println(ByteUtil.bytesToHexString(res));
res = (byte[]) responseHandle.process(device.getImei(), res);
// System.out.println(ByteUtil.bytesToHexString(res));
} catch (IOException e) {


+ 8
- 8
src/main/resources/application.properties Näytä tiedosto

@@ -45,15 +45,15 @@ guizhou.protocol=T01.4
#guizhou.device.version=ACB_1001
#guizhou.device.testList= [{ "imei": "862622050253671","phone": "" },{ "imei": "862622050253358","phone": "" },{ "imei": "800115470000678","phone": "" }]

#guizhou.factory=zhizhong
#guizhou.device.model=RZL600
#guizhou.device.version=RZL_2021
#guizhou.device.testList= [{ "imei": "862622050654340","phone": "" },{ "imei": "862622050317740","phone": "" }]
guizhou.factory=zhizhong
guizhou.device.model=RZL600
guizhou.device.version=RZL_2021
guizhou.device.testList= [{ "imei": "862622050654340","phone": "" },{ "imei": "862622050317740","phone": "" }]

guizhou.factory=zhanneng
guizhou.device.model=TPE390
guizhou.device.version=TPE_0056
guizhou.device.testList= [{ "imei": "862622050925104","phone": "" },{ "imei": "862622050927027","phone": "" }]
#guizhou.factory=zhanneng
#guizhou.device.model=TPE390
#guizhou.device.version=TPE_0056
#guizhou.device.testList= [{ "imei": "862622050925104","phone": "" },{ "imei": "862622050927027","phone": "" }]


guizhou.http.url=http://120.24.195.54:24183


Loading…
Peruuta
Tallenna