|
@@ -142,7 +142,7 @@ namespace MesAdaptor
|
|
if (string.IsNullOrEmpty(msg))
|
|
if (string.IsNullOrEmpty(msg))
|
|
return false;
|
|
return false;
|
|
|
|
|
|
- msg += $"{errorCode};";
|
|
+ msg += $"{GetMesCodeString(errorCode)};";
|
|
|
|
|
|
#if DEBUG
|
|
#if DEBUG
|
|
return true;
|
|
return true;
|
|
@@ -234,5 +234,45 @@ namespace MesAdaptor
|
|
{
|
|
{
|
|
return SajetConnectAdapter.SajetTransData((int)command, ref data);
|
|
return SajetConnectAdapter.SajetTransData((int)command, ref data);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ private string GetMesCodeString(MesErrorCode mesError)
|
|
|
|
+ {
|
|
|
|
+ switch (mesError)
|
|
|
|
+ {
|
|
|
|
+ case MesErrorCode.ChargerConnectFail:
|
|
|
|
+ return "A081";
|
|
|
|
+ case MesErrorCode.ModelNameUpadateFail:
|
|
|
|
+ return "A082";
|
|
|
|
+ case MesErrorCode.SerilaNumberUpadateFail:
|
|
|
|
+ return "A083";
|
|
|
|
+ case MesErrorCode.UtcDatetimeUpdateFail:
|
|
|
|
+ return "A084";
|
|
|
|
+ case MesErrorCode.FourthGenModelVersionMismatch:
|
|
|
|
+ return "A085";
|
|
|
|
+ case MesErrorCode.FourthGenSimInstartionMismatch:
|
|
|
|
+ return "A086";
|
|
|
|
+ case MesErrorCode.FourthGenSimInfoMismatch:
|
|
|
|
+ return "A087";
|
|
|
|
+ case MesErrorCode.WifiModeNotClient:
|
|
|
|
+ return "A088";
|
|
|
|
+ case MesErrorCode.WifiRssiLow:
|
|
|
|
+ return "A089";
|
|
|
|
+ case MesErrorCode.FirmwareUploadFail:
|
|
|
|
+ return "A090";
|
|
|
|
+ case MesErrorCode.FirmwareUpdateTimeout:
|
|
|
|
+ return "A091";
|
|
|
|
+ case MesErrorCode.FirmwareVersionCheckFail:
|
|
|
|
+ return "A092";
|
|
|
|
+ case MesErrorCode.EmergencyButtonTestFail:
|
|
|
|
+ return "A093";
|
|
|
|
+ case MesErrorCode.GreenButtonTestFail:
|
|
|
|
+ return "A094";
|
|
|
|
+ case MesErrorCode.BlueButtonTestFail:
|
|
|
|
+ return "A095";
|
|
|
|
+ case MesErrorCode.FactoryResetFail:
|
|
|
|
+ return "A096";
|
|
|
|
+ }
|
|
|
|
+ return "A081";
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|