

#include "ASW_Interface.h"
volatile uint16_T MainTaskDelayTime = 170U;

MSG_CHM_P1 COMR_strMsgCHM_P1;
MSG_CRM_P1 COMR_strMsgCRM_P1;
MSG_CML_P2 COMR_strMsgCML_P2;
MSG_CRO_P2 COMR_strMsgCRO_P2;
MSG_CCS_P3 COMR_strMsgCCS_P3;
MSG_CST_P3 COMR_strMsgCST_P3;
MSG_CSD_P4 COMR_strMsgCSD_P4;
MSG_CEM_ERR COMR_strMsgCEM_ERR;

/*******************************************************************************
**Variable Define
*******************************************************************************/
#define ASW1_OEM_START_SEC_DEFAULT_RAM2_INIT_UNSPECIFIED
#include "Asw1_OEM_MemMap.h"

volatile uint32_T COMR_verSoftwareVersion = 0xCBA780;
volatile uint16_T GcISP_VersionHashValue_numb = 0U;
volatile uint8_T GcRTE_VersionHashIndex_numb = 0U;
volatile uint8_T GcRTE_VersionHashValue_numb = 0U;
volatile real32_T BSW_uCC2Volt = 0.0F;
volatile real32_T BSW_uCCVolt = 0.0F;
volatile real32_T BSW_uIsoPosVolt = 0.0F;
volatile real32_T BSW_uKl30c = 0.0F;
volatile real32_T BSW_uKl30 = 0.0F;
volatile real32_T BSW_uMPosCtrHsdCurr = 0.0F;
volatile real32_T BSW_uDcChPosCtrHsdCurr = 0.0F;
volatile real32_T BSW_uMNegCtrHsdCurr = 0.0F;
volatile real32_T BSW_uDcChNegCtrHsdCurr = 0.0F;
volatile real32_T BSW_uCabCurr = 0.0F;
volatile real32_T BSW_uDcChPosCtrLsdVolt = 0.0F;
volatile real32_T BSW_uDcChNegCtrLsdVolt = 0.0F;
volatile real32_T BSW_uMPosCtrHsdVolt = 0.0F;
volatile real32_T BSW_uMNegCtrHsdVolt = 0.0F;
volatile real32_T BSW_uHwSplyVolt = 0.0F;
volatile real32_T BSW_uBattVolt = 0.0F;
volatile real32_T BSW_uDChrgVolt = 0.0F;
volatile real32_T BSW_uPackVolt = 0.0F;
volatile real32_T BSW_uNegVolt = 0.0F;
volatile real32_T BSW_uDchrgNegVolt = 0.0F;
volatile real32_T BSW_uClntUsT = 0.0F;
volatile real32_T BSW_uClntDsT = 0.0F;
volatile real32_T BSW_uDChrgNegTemp = 0.0F;
volatile real32_T BSW_uDChrgPosTemp = 0.0F;
volatile real32_T BSW_uReservedSig1 = 0.0F;
volatile real32_T BSW_uDCWkUp = 0.0F;
volatile real32_T BSW_uAdCurr = 0.0F;
volatile real32_T BSW_uReservedSig2 = 0.0F;
volatile real32_T BSW_uReservedSig3 = 0.0F;
volatile real32_T BSW_uReservedSig4 = 0.0F;
volatile real32_T BSW_uReservedSig5 = 0.0F;
volatile real32_T BSW_uReservedSig6 = 0.0F;
volatile real32_T BSW_uReservedSig7 = 0.0F;
volatile real32_T BSW_uReservedSig8 = 0.0F;
volatile real32_T BSW_dcHvilPwmDutyInp = 0.0F;
volatile real32_T BSW_fHvilPwmFrq = 0.0F;
volatile uint8_T BSW_stHVILInp = 0U;
volatile real32_T BSW_dcCrashPwmDuty = 0.0F;
volatile real32_T BSW_fCrashPwmFrq = 0.0F;
volatile uint8_T BSW_stCrashInpt = 0U;
volatile real32_T BSW_dcHvilPwmDutyOutDet = 0.0F;
volatile real32_T BSW_fHvilPwmFrqOutDet = 0.0F;
volatile uint8_T BSW_stHVILOutpFdbk = 0U;
volatile real32_T BSW_dcCrashPwmDutyOutDet = 0.0F;
volatile real32_T BSW_fCrashPwmFrqOutDet = 0.0F;
volatile uint8_T BSW_stCrashOutpFdbk = 0U;
volatile uint8_T BSW_stSysModeMag = 0U;
volatile uint16_T BSW_stSysWkUpSrc = 0U;
volatile uint8_T BSW_stSysNetWkUp = 0U;
volatile real32_T COMR_uMcuVolt = 0.0F;
volatile real32_T COMR_effObcChrg = 0.0F;
volatile real32_T COMR_iMaxCurrObcChrg = 0.0F;
volatile real32_T COMR_uMaxVoltObcChrg = 0.0F;
volatile real32_T COMR_iCurrObcChrg = 0.0F;
volatile real32_T COMR_uVoltObcChrg = 0.0F;
volatile uint8_T COMR_cntRCMsg2E6 = 0U;
volatile boolean_T COMR_stS2 = 0U;
volatile uint8_T COMR_valChkSumMsg2E6 = 0U;
volatile uint8_T COMR_stObcFaultLvl = 0U;
volatile uint8_T COMR_stObcElecLck = 0U;
volatile uint8_T COMR_stObcCP = 0U;
volatile uint8_T COMR_dcObcCP = 0U;
volatile uint8_T COMR_cntRCMsg2E1 = 0U;
volatile uint8_T COMR_valChkSumMsg2E1 = 0U;
volatile uint8_T COMR_stObcChrg = 0U;
volatile uint8_T COMR_stObcCC = 0U;
volatile uint8_T COMR_cntRCMsg2EB = 0U;
volatile uint8_T COMR_valChkSumMsg2EB = 0U;
volatile boolean_T COMR_bCabErrStatus = 0U;
volatile uint8_T COMR_stCabErrInfo = 0U;
//volatile real32_T COMR_iBattCurr = 0.0F;
volatile real32_T COMR_iBattCurr_mA = 0.0F;
volatile uint8_T COMR_flgAPPInvld = 0U;
volatile real32_T COMR_phiAPP = 0.0F;
volatile real32_T COMR_pwrChrgLdReq = 0.0F;
volatile uint8_T COMR_stPwrUpDwnVcuReq = 0U;
volatile uint8_T COMR_stPwrUpDwnVcuReqB = 0U;
volatile uint8_T COMR_stPreThmVcuPmt = 0U;
volatile boolean_T COMR_bBattChrgEnaA = 0U;
volatile boolean_T COMR_bBattChrgEnaB = 0U;
volatile uint8_T COMR_stVcuMutiPackDriveMode = 0U;
volatile uint8_T COMR_stVcuMutiPackPwrMode = 0U;
volatile boolean_T COMR_bVcuChrgDisable = 0U;
volatile boolean_T COMR_bLeadAcidChgHvOn = 0U;
volatile uint8_T COMR_stVcuIsoCtrEna = 0U;
volatile uint8_T COMR_cntRCMsg2A3 = 0U;
volatile uint8_T COMR_valChkSumMsg2A3 = 0U;
volatile uint8_T COMR_stElecMod = 0U;
volatile uint8_T COMR_stPreThmEna = 0U;
volatile uint8_T COMR_cntRCMsg2A5 = 0U;
volatile uint8_T COMR_valChkSumMsg2A5 = 0U;
volatile uint8_T COMR_stVcuFalutLvl = 0U;
volatile uint8_T COMR_stVcuWrk = 0U;
volatile boolean_T COMR_flgBrkPedInvld = 0U;
volatile boolean_T COMR_swtBrkPed = 0U;
volatile uint8_T COMR_cntRCMsg2A7 = 0U;
volatile uint8_T COMR_valChkSumMsg2A7 = 0U;
volatile uint8_T COMR_flgVcuSrceID = 0U;
volatile boolean_T VCU_NMRepeatReq = 0U;
volatile boolean_T VCU_NMActwake = 0U;
volatile boolean_T COMR_flgVcuRptFromSlp = 0U;
volatile boolean_T COMR_flgVcuRptFromPrepr = 0U;
volatile boolean_T COMR_flgVcuRptFromNorm = 0U;
volatile boolean_T COMR_flgVcuRptFromRdy = 0U;
volatile boolean_T COMR_flgVcuNormFromRpt = 0U;
volatile boolean_T COMR_flgVcuNormFromRdy = 0U;
volatile boolean_T COMR_flgVcuWkSrce = 0U;
volatile boolean_T COMR_flgVcuActSrce_A = 0U;
volatile boolean_T COMR_flgVcuActSrce_B = 0U;
volatile boolean_T COMR_flgVcuActSrce_C = 0U;
volatile boolean_T COMR_flgVcuActSrce_D = 0U;
volatile boolean_T COMR_flgVcuActSrce_E = 0U;
volatile real32_T COMR_VehSpd = 0.0F;
volatile boolean_T COMR_VehSpdVld = 0U;
volatile real32_T COMR_tEnvT = 0.0F;
volatile real32_T COMR_valAcmDist = 0.0F;
volatile boolean_T COMR_flgAcmDistVld = 0U;
volatile uint8_T COMR_valVinCode_A = 0U;
volatile uint8_T COMR_valVinCode_B = 0U;
volatile uint8_T COMR_valVinCode_C = 0U;
volatile uint8_T COMR_valVinCode_D = 0U;
volatile uint8_T COMR_valVinCode_E = 0U;
volatile uint8_T COMR_valVinCode_F = 0U;
volatile uint8_T COMR_valVinCode_G = 0U;
volatile uint8_T COMR_cntVinCodeNum = 0U;
volatile uint8_T COMR_stCrashSgl = 0U;
volatile uint8_T COMR_cntRCMsg050 = 0U;
volatile uint8_T COMR_valChkSumMsg050 = 0U;
volatile real32_T COMR_pPTCOptPwrReq = 0.0F;
volatile real32_T COMR_pCompOptPwrReq = 0.0F;
volatile boolean_T COMR_stPreCoolWk = 0U;
volatile boolean_T COMR_stPreHeatlWk = 0U;
volatile boolean_T COMR_bIviDischgOrd = 0U;
volatile uint16_T COMR_YearSet = 0U;
volatile uint8_T COMR_MonthSet = 0U;
volatile uint8_T COMR_DaySet = 0U;
volatile uint8_T COMR_HourSet = 0U;
volatile uint8_T COMR_MinSet = 0U;
volatile uint8_T COMR_SecondSet = 0U;
volatile uint8_T COMR_stAppChrgOrdCmd = 0U;
volatile uint8_T COMR_stAppChrgOrdStart = 0U;
volatile boolean_T COMR_bChrgStopActive = 0U;
volatile boolean_T COMR_stS2On = 0U;
volatile uint8_T COMR_stInletLock = 0U;
volatile uint8_T COMR_stCpState = 0U;
volatile uint8_T COMR_stLockAlarm = 0U;
volatile uint8_T COMR_stPdState = 0U;
volatile real32_T COMR_iMaxAChrgCurr = 0.0F;
volatile uint8_T COMR_stDcAcChgMode = 0U;
volatile real32_T COMR_uEvseOutputVolt = 0.0F;
volatile real32_T COMR_pwrEvseMaxPwrLmt = 0.0F;
volatile uint32_T COMR_numComVer = 0UL;
volatile uint32_T COMR_Reserved1 = 0UL;
volatile uint8_T COMR_stIdtfRstCrm = 0U;
volatile uint32_T COMR_Reserved2 = 0UL;
volatile uint8_T COMR_stChrgRdyCro = 0U;
// volatile real32_T COMR_tiDcChrgTimeActualCcs = 0.0F;
volatile uint8_T COMR_stDcChrgCmdCcs = 0U;
volatile uint8_T COMR_stRchSetCondCst = 0U;
volatile uint8_T COMR_stMnlStopCst = 0U;
volatile uint8_T COMR_stChrgErrStopCst = 0U;
volatile uint8_T COMR_stBmsStopActCst = 0U;
volatile uint8_T COMR_stChrgerOvrTempErrCst = 0U;
volatile uint8_T COMR_stChrgerCnntErrCst = 0U;
volatile uint8_T COMR_stChrgerInrOvrTempErrCst = 0U;
volatile uint8_T COMR_stEnrgTxAbnrmErrCst = 0U;
volatile uint8_T COMR_stChrgerSrmErrCst = 0U;
volatile uint8_T COMR_stOtherErrCst = 0U;
volatile uint8_T COMR_stChrgCurrAbnrmCst = 0U;
volatile uint8_T COMR_stChrgVoltAbnrmCst = 0U;
volatile uint32_T COMR_numChrgerNumCsd = 0UL;
volatile real32_T COMR_eOutpEnrgCsd = 0.0F;
volatile real32_T COMR_tiChrgTimeCsd = 0.0F;
volatile uint8_T COMR_stRcvBrmTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBcpTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBroOkTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBcsTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBclTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBstTimeOutCem = 0U;
volatile uint8_T COMR_stRcvBsdTimeOutCem = 0U;
volatile uint8_T COMR_stOtherErrCem = 0U;
//volatile boolean_T BSPR_bOutputVolt12vEna = 0U;
volatile boolean_T Ground = 0U;
//volatile boolean_T HVSR_bIsoSwt1Ena = 0U;
//volatile boolean_T HVSR_bIsoSwt2Ena = 0U;
//volatile boolean_T HVSR_bIsoSwt3Ena = 0U;
volatile uint8_T CNMR_flgBmsSrceID = 0U;
volatile boolean_T CNMR_flgBmsRptReq = 0U;
volatile boolean_T CNMR_flgBmsWkUp = 0U;
volatile boolean_T CNMR_flgBmsRptFromSlp = 0U;
volatile boolean_T CNMR_flgBmsRptFromPrepr = 0U;
volatile boolean_T CNMR_flgBmsRptFromNorm = 0U;
volatile boolean_T CNMR_flgBmsRptFromRdy = 0U;
volatile boolean_T CNMR_flgBmsNormFromRpt = 0U;
volatile boolean_T CNMR_flgBmsNormFromRdy = 0U;
volatile uint8_T CNMR_flgBmsWkSrce = 0U;
volatile boolean_T CNMR_flgBmsActSrce_A = 0U;
volatile boolean_T CNMR_flgBmsActSrce_B = 0U;

volatile boolean_T BCMR_bPlugLockPrms = 0U;
volatile boolean_T BCMR_bBmsSleepReq = 0U;
volatile boolean_T BCMR_bWeldDetReq = 0U;
volatile boolean_T BCMR_bS2OnReq = 0U;
volatile real32_T BCMR_uMaxPmtdChrgPackVoltBhm = 0.0F;
volatile real32_T BCMR_uMaxPmtdChrgPackCurrBhm = 0.0F;
volatile real32_T BCMR_uMaxPmtdChrgPackCurrEna = 0.0F;

volatile uint8_T COMR_stEuroChrgMode = 0U;
volatile uint8_T CNMR_stDebugOut = 0U;
volatile uint8_T CNMR_stTransferRoute = 0U;
//volatile boolean_T BCMR_bAcDischgFobd = 0U;
volatile boolean_T BCMR_bAChrgPortOvrTemp = 0U;
volatile boolean_T DSMR_DChrgPreChTOut = 0U;
volatile boolean_T BCMR_bAChgUnclockTmOut = 0U;
volatile boolean_T BCMR_bEVCCSelfChkFlt = 0U;
volatile boolean_T BCMR_bAChgS2ClsdTmOut = 0U;

volatile boolean_T DSMR_DChrgMsgTimeout = 0U;
volatile boolean_T DSMR_Obc2E1Tmt = 0U;
volatile boolean_T DSMR_CscCellVoltOpenLine = 0U;
volatile boolean_T DSMR_CscCellTempOpenLine = 0U;
volatile boolean_T BCMR_stChrgCnntBoth = 0U;
volatile boolean_T COMR_stConnectPackB = 0U;
// volatile uint8_T BCMR_stDChrgElockReq = 0U;
//volatile uint8_T BCMR_stIviDischg = 0U;
//volatile uint8_T BCMR_stV2xMod = 0U;
//volatile boolean_T BCMR_flgDischgCmd = 0U;
volatile uint8_T BCCR_stBmsRelayCtrStatus = 0U;
volatile uint8_T COMR_stEol = 0U;
volatile boolean_T VCAN_NMMsgRx = 0U;
volatile boolean_T BAAR_flagAutoAdrsEna = 0U;
volatile boolean_T BSWBusHVDataMsgRx = 0U;
volatile boolean_T InCan_BusOff = 0U;
volatile boolean_T BSWVECANBusFastRecoveryFail = 0U;
//volatile uint8_T BCMR_stBmsRdyBro = 0U;
volatile real32_T BCMR_vDcChrgVoltReqBcl = 0.0F;
volatile real32_T BCMR_stDcChrgModeBcl = 0.0F;
volatile real32_T BCMR_iDcChrgCurrReqBcl = 0.0F;
volatile real32_T BCMR_tBattMinTempBsm = 0.0F;
volatile uint8_T BCMR_stBattCellVoltErrBsm = 0U;
volatile uint8_T BCMR_stChrgEnaBsm = 0U;
volatile uint8_T BCMR_stBattInsulationErrBsm = 0U;
volatile uint8_T BCMR_numMaxCellVoltAddrBsm = 0U;
volatile uint8_T BCMR_stBattOutputContErrBsm = 0U;
volatile uint8_T BCMR_stBattChrgCurrOvrErrBsm = 0U;
volatile uint8_T BCMR_stBattTempOvrErrBsm = 0U;
volatile uint8_T BCMR_stBattSocErrBsm = 0U;
volatile uint8_T BCMR_numBattMaxTemptAddrBsm = 0U;
volatile uint8_T BCMR_numBattMinTemptAddrBsm = 0U;
volatile real32_T BCMR_tBattMaxTempBsm = 0.0F;
volatile uint8_T BCMR_stRchSocLmtBst = 0U;
volatile uint8_T BCMR_stRchPackVoltLmtBst = 0U;
volatile uint8_T BCMR_stRchCellVoltLmtBst = 0U;
volatile uint8_T BCMR_stChrgerActStopBst = 0U;
volatile uint8_T BCMR_stBattInsulationErrBst = 0U;
volatile uint8_T BCMR_stOutpCnntOvrTempErrBst = 0U;
volatile uint8_T BCMR_stPcbOvrTempErrBst = 0U;
volatile uint8_T BCMR_stChrgCnntErrBst = 0U;
volatile uint8_T BCMR_stBattOvrTempErrBst = 0U;
volatile uint8_T BCMR_stMainRelayErrBst = 0U;
volatile uint8_T BCMR_stCC2ChkVoltErrBst = 0U;
volatile uint8_T BCMR_stOtherErrBst = 0U;
volatile uint8_T BCMR_stChrgCurrAbnrmBst = 0U;
volatile uint8_T BCMR_stChrgVoltAbnrmBst = 0U;
volatile real32_T BCMR_tBattMaxTempBsd = 0.0F;
volatile real32_T BCMR_tBattMinTempBsd = 0.0F;
volatile uint16_T BCMR_vBattMaxCellVoltBsd = 0U;
volatile uint16_T BCMR_vBattMinCellVoltBsd = 0U;
volatile uint8_T BCMR_rBattSocBsd = 0U;
//volatile uint8_T BCMR_stSpn3901TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3902TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3903TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3904TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3905TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3906TimeoutBem = 0U;
//volatile uint8_T BCMR_stSpn3907TimeoutBem = 0U;
//volatile uint8_T BCMR_stOtherErrBem = 0U;

volatile boolean_T BSWBatteryHVDataMsgRx = 0U;
volatile boolean_T BSPR_bACWkUp = 0U;
volatile boolean_T BSPR_bKl15WkUp = 0U;
volatile boolean_T BCMR_bAChgLockingTmOut = 0U;
//volatile uint8_T BSPR_stBmsSelfChk = 0U;
volatile boolean_T DcCan_BusOff = 0U;
volatile boolean_T BSWLinCommunicationFault = 0U;
volatile boolean_T VeCan_BusOff = 0U;
volatile boolean_T BSWBoardTempMsgRx[2] = {0U, 0U};
volatile boolean_T BSWCellTempMsgRx[6] = {0U, 0U, 0U, 0U, 0U, 0U};
volatile boolean_T BSWCellVoltageMsgRx[24] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile boolean_T BSWCellBalanceCircuitStatusMsgRx[2] = {0U, 0U};
volatile boolean_T BSWModuleVoltageMsgRx[2] = {0U, 0U};
volatile boolean_T BSWVCU2A3DataAvailable = 0U;
volatile boolean_T BSWVCU2A5DataAvailable = 0U;
volatile boolean_T BSWVCU2A7DataAvailable = 0U;
volatile boolean_T BSWACCharger0x2E0MessageAvailable = 0U;
volatile boolean_T BSWACCharger0x2E1MessageAvailable = 0U;
volatile boolean_T BSWABM050DataAvailable = 0U;
volatile boolean_T BSWGW2ADDataAvailable = 0U;
volatile boolean_T BSWGW2BBDataAvailable = 0U;
volatile boolean_T BSWVCU2A3CheckSum = 0U;
volatile boolean_T BSWABM050CheckSum = 0U;
volatile boolean_T BSWOBC2E0CheckSum = 0U;
volatile boolean_T BSWOBC2E1CheckSum = 0U;
volatile boolean_T BSPR_bRSocNvmVldFlg = 0U;
volatile real32_T COMR_tCmcBordTemp_A[8] = {0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F};
volatile boolean_T COMR_bBattTempWireStt_A[2] = {0U, 0U};
volatile real32_T BCCR_dcDcChNegCtrLsdPwmDuty = 0.0F;
volatile boolean_T COMR_bCellVoltWireStt_A[2] = {0U, 0U};
volatile real32_T BSPR_uIsoNegVolt = 0.0F;
volatile uint8_T COMR_cntRCMsg2E0 = 0U;
volatile boolean_T COMR_bClrAllDtc = 0U;
volatile boolean_T BSWIVI37FDataAvailable = 0U;
volatile uint32_T BMCR_tiSetWakeUpTime = 0UL;
// volatile uint32_T COMR_tiStopTimeUint = 0UL;
volatile real32_T COMR_iDcChrgCurrReqBcl = 0.0F;
volatile uint8_T BSW_stOTAMode = 0U;
/**********************************/

volatile real32_T BSWCC2Voltage = 0.0F;
volatile real32_T BSWHVILDriveVoltage = 0.0F;
volatile real32_T BSWSystemVoltage = 0.0F;
volatile real32_T BSWMPRHSDCoilCurrent = 0.0F;
volatile real32_T BSWMPCHSDCoilCurrent = 0.0F;
volatile real32_T BSWDCPHSDCoilCurrent = 0.0F;
volatile real32_T BSWMNCHSDCoilCurrent = 0.0F;
volatile real32_T BSWDCNHSDCoilCurrent = 0.0F;
volatile real32_T BSWCSCSupplyCurrent = 0.0F;
volatile real32_T BSWDCPLSDOutputVoltage = 0.0F;
volatile real32_T BSWHwIsolationVoltage = 0.0F;
volatile real32_T BSWACPTempVoltage = 0.0F;
volatile real32_T BSWDCNLSDOutputVoltage = 0.0F;
volatile real32_T BSWCCWakeVoltage = 0.0F;
volatile real32_T BSWInletVoltage = 0.0F;
volatile real32_T BSWOutletVoltage = 0.0F;
volatile real32_T BSWHwSupplyVoltage = 0.0F;
volatile real32_T BSWMPCHSDOutputVoltage = 0.0F;
volatile real32_T BSWMNCHSDOutputVoltage = 0.0F;
volatile real32_T BSWMNCLSDOutputVoltage = 0.0F;
volatile real32_T BSWMPCLSDOutputVoltage = 0.0F;
volatile real32_T BSWKL30CVoltage = 0.0F;
volatile real32_T BSWHSDInputVoltage = 0.0F;
volatile real32_T BSWMPRHSDOutputVoltage = 0.0F;
volatile real32_T BSWDCPHSDOutputVoltage = 0.0F;
volatile real32_T BSWDCNHSDOutputVoltage = 0.0F;
volatile real32_T BSWCrashPWMDuty = 0.0F;
volatile real32_T BSWCrashPWMFrequency = 0.0F;
volatile real32_T BSWDCNTempVoltage = 0.0F;
volatile real32_T BSWDCPTempVoltage = 0.0F;
volatile real32_T BSWAutoAddressDuty = 0.0F;
volatile real32_T BSWAutoAddressFrequency = 0.0F;
volatile boolean_T Switch1Control = 0U;
volatile real32_T BSWHVILDrivePWMDuty = 0.0F;
volatile real32_T BSWHVILDrivePWMFrequency = 0.0F;
//volatile boolean_T BCMR_bAcDischgRdy = 0U;
volatile boolean_T BSWVCANComError = 0U;
volatile boolean_T BSWChargeCANComError = 0U;
volatile boolean_T HSD1FaultStatus = 0U;
volatile boolean_T HSD2FaultStatus = 0U;
volatile boolean_T BSWACCPWakeup = 0U;
volatile boolean_T BSWACCWakeup = 0U;
volatile boolean_T BSWDCWakeup = 0U;
volatile boolean_T BSWIGNWakeup = 0U;
volatile boolean_T BSWACCCWakeup = 0U;
volatile uint8_T BSWNVMReadStatus = 0U;
volatile uint8_T BSWSPEReadStatus = 0U;

volatile boolean_T BSWVCANWakeup = 0U;

volatile boolean_T BSWHandShakeCHMMsgRx = 0U;
volatile boolean_T BSWHandShakeCRMMsgRx = 0U;
volatile boolean_T BSWParameterCMLMsgRx = 0U;
volatile boolean_T BSWParameterCROMsgRx = 0U;
volatile boolean_T BSWParameterCCSMsgRx = 0U;
volatile boolean_T BSWChargingCSTMsgRx = 0U;
volatile boolean_T BSWEndCSDMsgRx = 0U;
volatile boolean_T BSWEndCEMMsgRx = 0U;
volatile boolean_T BSWDCCANPassive = 0U;
volatile boolean_T COMR_bStopTimeVldFlg = 0U;

volatile uint16_T COMR_BMSYear = 0U;
volatile uint8_T COMR_BMSMonth = 0U;
volatile uint8_T COMR_BMSDay = 0U;
volatile uint8_T COMR_BMSHour = 0U;
volatile uint8_T COMR_BMSMinute = 0U;
volatile uint8_T COMR_BMSSecond = 0U;

volatile uint16_T BSW_BMSYear = 0U;
volatile uint8_T BSW_BMSMonth = 0U;
volatile uint8_T BSW_BMSDay = 0U;
volatile uint8_T BSW_BMSHour = 0U;
volatile uint8_T BSW_BMSMinute = 0U;
volatile uint8_T BSW_BMSSecond = 0U;

volatile uint16_T EolYear = 0U;
volatile uint8_T EolMonth = 0U;
volatile uint8_T EolDay = 0U;
volatile uint8_T EolHour = 0U;
volatile uint8_T EolMinute = 0U;
volatile uint8_T EolSecond = 0U;

volatile real32_T BSWPowerOffNormal = 0.0F;
volatile real32_T BSWPowerOffCase = 0.0F;

volatile uint8_T BMUState = 0U;

volatile uint8_T COMR_cntRCMsg2C0 = 0U;
volatile uint8_T COMR_valChkSumMsg2C0 = 0U;
volatile uint8_T COMR_cntRCMsg2C5 = 0U;
volatile uint8_T COMR_valChkSumMsg2C5 = 0U;

volatile uint8_T COMR_cntRCMsg2C2 = 0U;
volatile uint8_T COMR_valChkSumMsg2C2 = 0U;

volatile uint8_T COMR_cntRCMsg2CA = 0U;
volatile uint8_T COMR_valChkSumMsg2CA = 0U;
volatile uint8_T COMR_cntRCMsg09D = 0U;
volatile uint8_T COMR_valChkSumMsg09D = 0U;

volatile real32_T BSER_rSoh = 100.0F;

volatile uint8_T COMR_cntRCMsg2C8 = 0U;
volatile uint8_T COMR_valChkSumMsg2C8 = 0U;

volatile boolean_T BCMR_stBmsCCFdbk = 0U;
volatile uint8_T COMR_cntRCMsg2C7 = 0U;
volatile uint8_T COMR_valChkSumMsg2C7 = 0U;
volatile boolean_T BSPR_bBattTempSnsrFault = 0U;

volatile boolean_T BCMR_tDChrgIfcOvrTemp = 0U;
volatile boolean_T BCMR_bCurrOutRngFault = 0U;

volatile boolean_T BCMR_bVoltOutRngFault = 0U;
volatile boolean_T BSPR_bBattTempFault = 0U;

volatile boolean_T BSPR_bBoardUndrTempFault = 0U;
volatile boolean_T BSPR_bBoardOvrTempFault = 0U;
volatile boolean_T BSPR_bCellTempCnstFault = 0U;
volatile boolean_T BSPR_bBoardDiffTempFault = 0U;

volatile boolean_T BSPR_bClntUsTHiFault = 0U;
volatile boolean_T BSPR_bClntUsTLoFault = 0U;
volatile boolean_T BSPR_bClntDsTHiFault = 0U;
volatile boolean_T BSPR_bClntDsTLoFault = 0U;

volatile boolean_T COMR_bSysMishFault = 0U;
volatile boolean_T BSER_bOvrChrgFault = 0U;

volatile real32_T BTMR_tClntTgtTemp = 0.0F;
volatile real32_T BTMR_tHtTgtTemp = 0.0F;

volatile real32_T BTMR_tDiffClntTgtUsT = 0.0F;
volatile real32_T BTMR_tDiffHtTgtUsT = 0.0F;

volatile uint8_T COMR_cntDtcQtty = 0U;
volatile uint8_T COMR_cntDtcInd = 0U;
volatile uint32_T COMR_cntDtcCode_A = 0UL;
volatile uint32_T COMR_cntDtcCode_B = 0UL;
volatile uint8_T COMR_flgBmsSrceID = 0U;
volatile boolean_T COMR_flgBmsWkUp = 0U;
volatile boolean_T COMR_flgBmsRptReq = 0U;
volatile boolean_T COMR_flgBmsRptFromSlp = 0U;
volatile boolean_T COMR_flgBmsRptFromPrepr = 0U;
volatile boolean_T COMR_flgBmsRptFromNorm = 0U;
volatile boolean_T COMR_flgBmsRptFromRdy = 0U;
volatile boolean_T COMR_flgBmsNormFromRpt = 0U;
volatile boolean_T COMR_flgBmsNormFromRdy = 0U;
volatile uint8_T COMR_flgBmsWkSrce = 0U;
volatile boolean_T COMR_flgBmsActSrce_A = 0U;
volatile boolean_T COMR_flgBmsActSrce_B = 0U;

//Dummy for BCMR

volatile boolean_T COMR_flgObcNetWkup = 0U;

volatile boolean_T COMR_bDcCanBusOff = 0U;
volatile boolean_T BSER_bSocFaultVldFlg = 0U;
volatile boolean_T COMR_flgObcWkUp = 0U;

//Dummy for BSPR_RTE

volatile real32_T BCCR_fDcChPosCtrLsdPwmFrq = 0.0F; /* '<Root>/BCCR_fDcChPosCtrLsdPwmFrq' */
volatile real32_T BCCR_fMPosCtrLsdPwmFrq = 0.0F;    /* '<Root>/BCCR_fMPosCtrLsdPwmFrq' */
volatile real32_T BCCR_fMNegCtrLsdPwmFrq = 0.0F;    /* '<Root>/BCCR_fMNegCtrLsdPwmFrq' */
volatile real32_T BCCR_fDcChNegCtrLsdPwmFrq = 0.0F;
//volatile real32_T BAAR_dcAutoAddDuty = 0.0F;    /* '<Root>/BAAR_dcAutoAddDuty' */
//volatile real32_T BAAR_fAutoAddFrq = 0.0F;

//Dummy for CAN
volatile boolean_T BSER_bSocHopFault = 0U;
volatile boolean_T BSER_bSocResFault = 0U;

volatile boolean_T BSER_bBattOvrVoltFault = 0U;
volatile boolean_T BSER_bBattUndrVoltFault = 0U;
volatile boolean_T BSER_bBattOvrCurrFault = 0U;

//Dummy for BCCR
volatile boolean_T BSER_flgCtrCtrlFault = 0U;
volatile boolean_T BSER_bBattCurrSglFault = 0U;

volatile boolean_T BSER_flgDChrgVoltSnsrFault = 0U;
volatile boolean_T BSER_flgDChrgCtrCtrlFault = 0U;

//Dummy for Balance
volatile uint8_T BSPR_bWkSrc = 0U;

//Dummy for HVSR

volatile boolean_T DSMR_bFaultRankVldFlg = 1U;
volatile boolean_T BSPR_bCurrVldFlg = 1U;
volatile real32_T BSPR_iCurrOfsAdap_nvm = 0.0F;

volatile real32_T BSPR_rNvmSocAvrg = 0.0F;
volatile real32_T BSPR_rNvmSocMax = 0.0F;
volatile real32_T BSPR_rNvmSocMin = 0.0F;
volatile real32_T BSPR_rDsplNvmSoc = 0.0F;

volatile uint16_T COMR_BMSYear_nvm = 0U;
volatile uint8_T COMR_BMSMonth_nvm = 0U;
volatile uint8_T COMR_BMSDay_nvm = 0U;
volatile uint8_T COMR_BMSHour_nvm = 0U;
volatile uint8_T COMR_BMSMinute_nvm = 0U;
volatile uint8_T COMR_BMSSecond_nvm = 0U;

//Dummuy for BSER
volatile boolean_T BSPR_bCellVoltVldFlg = 1U;
volatile boolean_T BSER_bBattCapVldFlg = 1U;

volatile boolean_T BCMR_bChrgFulVldFlg = 1U;

//Dummy for BSPR_BattVoltDiag
volatile boolean_T BSPR_flgBattVoltErr = 0U;
volatile boolean_T BSPR_flgDChrgVoltErr = 0U;
volatile boolean_T BSPR_flgPackVoltErr = 0U;

volatile uint8_T UDSR_bBalReqEx[96] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                       0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                       0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                       0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

//Dummy for DSMR
volatile uint8_T DFC_CscCellTempOpenLine_ASW = 0U;
volatile uint8_T DFC_CscCellVoltOpenLine_ASW = 0U;
volatile boolean_T COMR_bIsoResCalShieldCmd = 0U;

//volatile uint8_T DFC_OutClntOverTmp_ASW = 0U;
//volatile uint8_T DFC_CurrRngErr_ASW = 0U;
//volatile uint8_T DFC_BattVoltRngErr_ASW = 0U;
//volatile uint8_T DFC_FuseNpl_ASW = 0U;
//volatile uint8_T DFC_DChrgTCnntMax_ASW = 0U;
volatile uint8_T DFC_CmcBordOTMax_ASW = 0U;

//Dummuy for DFC
// volatile uint8_T DFC_CrashHwNpl_ASW = 0U;
volatile uint8_T DFC_AChgPileRdyTmt_ASW = 0U;
volatile uint8_T DFC_BalStuckMax_ASW = 0U;
volatile uint8_T DFC_DChrgCableChk_ASW = 0U;
volatile uint8_T DFC_BalStuckMin_ASW = 0U;
volatile uint8_T DFC_AChgS2ClsdTmt_ASW = 0U;
volatile uint8_T DFC_CcuSelfChkErr_ASW = 0U;
volatile uint8_T DFC_DChrgCnntErr_ASW = 0U;
volatile uint8_T DFC_DChrgLckErr_ASW = 0U;
volatile uint8_T DFC_AChrgPortOvrTemp_ASW = 0U;
volatile uint8_T DFC_AChgLckTmt_ASW = 0U;
volatile uint8_T DFC_AChgUnlckTmt_ASW = 0U;
volatile uint8_T DFC_DChrgSLACTOut_ASW = 0U;

//Dummy for CAN_Pro
volatile uint8_T BCMR_stAppChgMode = 0U;
volatile uint8_T BCMR_stDChrgRchSocLmt = 0U;
volatile uint8_T BCMR_stDChrgRchPackVoltLmt = 0U;
volatile uint8_T BCMR_stPcbOvrTempErr = 0U;

// volatile boolean_T BTMR_bThmRunAway = 0U;
volatile boolean_T BCMR_bDChrgStVoltOut = 0U;
volatile boolean_T BCMR_bObcRdyReq = 0U;

volatile uint8_T COMR_stUdsMainHvClsReq = 0U;
volatile uint8_T COMR_stUdsDcCircuitClsReq = 0U;

volatile boolean_T COMR_stChrgEn = true;
volatile boolean_T COMR_bChrgDisable = 0U;
volatile uint8_T DFC_IsoChkLv3_ASW = 0U;

volatile boolean_T COMR_DFC_DcCanBusOff = 0U;
volatile boolean_T COMR_DFC_VeCanBusOff = 0U;

volatile boolean_T COMR_DFC_Msg17DTmt = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2EBErr = 0U;
volatile boolean_T COMR_DFC_Msg2EBTmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2E6Mis = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2E6Err = 0U;
volatile boolean_T COMR_DFC_Msg2E6Tmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2E1Mis = 0U;
volatile boolean_T COMR_DFC_Msg28CTmt = 0U;
volatile boolean_T COMR_DFC_Msg37FTmt = 0U;
volatile boolean_T COMR_DFC_Msg195Tmt = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2E1Err = 0U;
volatile boolean_T COMR_DFC_Msg2F1Tmt = 0U;
volatile boolean_T COMR_DFC_RcMsg050Mis = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg050Err = 0U;
volatile boolean_T COMR_DFC_Msg050Tmt = 0U;
volatile boolean_T COMR_DFC_Msg3AATmt = 0U;
volatile boolean_T COMR_DFC_Msg2DFTmt = 0U;
volatile boolean_T COMR_DFC_Msg2BBTmt = 0U;
volatile boolean_T COMR_DFC_Msg2ADTmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2A7Mis = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2A7Err = 0U;
volatile boolean_T COMR_DFC_Msg2E1Tmt = 0U;
volatile boolean_T COMR_DFC_Msg2A7Tmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2A5Mis = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2A5Err = 0U;
volatile boolean_T COMR_DFC_Msg2A5Tmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2A3Mis = 0U;
volatile boolean_T COMR_DFC_ChkSumMsg2A3Err = 0U;
volatile boolean_T COMR_DFC_Msg2A3Tmt = 0U;
volatile boolean_T COMR_DFC_Msg0B5Tmt = 0U;
volatile boolean_T COMR_DFC_MsgCABTmt = 0U;
volatile boolean_T COMR_DFC_RcMsg2EBMis = 0U;
volatile boolean_T COMR_DFC_Msg130Tmt = 0U;

volatile boolean_T BMCR_bOutputVolt12vEna = TRUE;
volatile uint8_T GcRTE_BIDNumbIndex_numb = 1U;
volatile uint8_T GcRTE_AfeIndex_numb = 0U;

/* Diag */
volatile boolean_T GbRTE_MainPwrUpReq_flg = FALSE;
volatile boolean_T GbRTE_DChrgPwrUpReq_flg = FALSE;

volatile uint32_T COMR_BMSSleepScndTime = 0UL;
volatile boolean_T COMR_bBMSScndVldFlg = FALSE;

uint32 CDM3_DIAGTimeStamp = 0UL;
uint32 CDM2_DIAGTimeStamp = 0UL;
uint32 CDM1_DIAGTimeStamp = 0UL;
uint32 CSD_P4TimeStamp = 0UL;
uint32 CST_P3TimeStamp = 0UL;
uint32 CCS_P3TimeStamp = 0UL;
uint32 CRO_P2TimeStamp = 0UL;
uint32 CML_P2TimeStamp = 0UL;
uint32 CTS_P2TimeStamp = 0UL;
uint32 CEM_ERRTimeStamp = 0UL;
uint32 CDM6_DIAGTimeStamp = 0UL;
uint32 CDM5_DIAGTimeStamp = 0UL;
uint32 CDM4_DIAGTimeStamp = 0UL;
uint32 CHM_P1TimeStamp = 0UL;
uint32 CRM_P1TimeStamp = 0UL;

volatile boolean PIN28_State = 0U;

volatile real32_T BSER_rBattRes = 0.0F;
volatile uint16_T GcRTE_EvccDtc_numb = 0U;

volatile uint8 GaISP_AFEComLost_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFECellVoltUpdErr_numb[112] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                    0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                    0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                    0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                    0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFECellTempUpdErr_numb[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                   0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint16 GaISP_AFESampleErr_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFECellVoltLineOpen_numb[112] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                      0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                      0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                      0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                      0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFEGpioLineOpen_numb[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFEAdcRelatedErr_numb[112] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                   0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                   0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                   0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                   0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8 GaISP_AFEDiagModeExitErr_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint16 GaISP_AFEOtherErr_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint8_T COMR_stBalCirOpenFlt_A[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint8_T COMR_stBalCirShortFlt_A[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint8_T COMR_stHVSmplComFlt = 0U;

volatile uint16_T BSPR_stMPosLsdSta = 0U;
volatile uint16_T BSPR_stMNegLsdSta = 0U;
volatile uint16_T BSPR_stDcPosLsdSta = 0U;
volatile uint16_T BSPR_stDcNegLsdSta = 0U;

volatile boolean_T GaBSW_CellVoltVld_flg[96] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile real32_T GaBSW_CellTempVolt_V[48] = {0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F,
                                              0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F};

volatile real32_T GaBSW_BusbarTempVolt_V[48] = {0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F,
                                                0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F};

volatile boolean_T GaBSW_CellTempVld_flg[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile boolean_T GaBSW_BusbarTempVld_flg[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile boolean_T GeBSW_CellTempThmRnwyVld_enum[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                        0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile boolean_T GeBSW_BusbarTempThmRnwyVld_enum[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                          0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};


volatile boolean_T GbBSW_CellVoltVldAll_flg = FALSE;
volatile boolean_T GbBSW_CellTempVldAll_flg = FALSE;
volatile boolean_T GbBSW_BusbarTempVldAll_flg = FALSE;
volatile boolean_T GbBSW_ModTempVldAll_flg = FALSE;

volatile uint16 GaBSW_VAFETmp_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint8 GaBSW_VAFETmpDiag_numb[8] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
volatile uint8 GbBSW_VAFETmpVld_flg = E_NOT_OK;

/* 项目变量 */
volatile uint8 GeRTE_PrjEdition_enum = 0U; /* 8611: 0, 891: 1 */
/* 国欧标定 */
volatile uint8 GeRTE_AreaEdition_enum = 0U; /* 国版 0, 欧版 1 */
/* 电芯标定 */
volatile uint8 GeRTE_CapEdition_enum = 3U; /* 电芯标定 */
/* 电芯温度个数 */
volatile uint8 GcRTE_CellTempNumb_numb = 0U;
/* Busbar温度个数 */
volatile uint8 GcRTE_BusbarTempNumb_numb = 24U;
/* 电芯温度点AFE MAP*/
volatile uint8 GaRTE_CellTempAFEMap_numb[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};
/* Busbar温度点AFE MAP*/
volatile uint8 GaRTE_BusbarTempAFEMap_numb[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint8_T GeRTE_LastShutdownState_enum = 0U;

volatile boolean_T DFC_ThmRnwyWarn_ASW = FALSE;
volatile boolean_T DFC_CalCANBusOff_ASW = FALSE;
volatile boolean_T DFC_SBCSplyPwrOvrCurr_ASW = FALSE;
volatile boolean_T DFC_SBCSplyPwrOvrVolt_ASW = FALSE;
volatile boolean_T DFC_SBCSplyPwrUnderVolt_ASW = FALSE;
volatile boolean_T DFC_HVSmplSigErr_ASW = FALSE;
volatile boolean_T DFC_HVSmplSplyFlt_ASW = FALSE;
// volatile boolean_T DFC_BMSSplyPwrAbnToCAB_ASW = FALSE;
volatile boolean_T DFC_BattSohChk_ASW = FALSE;
volatile boolean_T DFC_PchgOvrCurrFlt_ASW = FALSE;

volatile boolean_T DFC_MCUResetFlt_ASW = FALSE;
volatile boolean_T DFC_AFESplyFlt_ASW = FALSE;
volatile boolean_T DFC_NVMReadError_ASW = FALSE;
volatile boolean_T DFC_KL30Shutdown_ASW = FALSE;

volatile boolean_T BTMR_flgHighCellVoltRd = 0U;
volatile boolean_T BTMR_flgLowCellVoltRd = 0U;
volatile uint8_T BTMR_idxMaxEndVoltRd = 0U;
volatile uint8_T BTMR_idxMinEndVoltRd = 0U;
volatile real32_T BTMR_uMaxVoltRd = 0.0F;
volatile real32_T BTMR_uMinVoltRd = 0.0F;

volatile uint8_T GeBSW_StopTimeStd_enum = 0U;
volatile boolean_T GbBSW_NvmShutdownVld_flg = TRUE;
volatile boolean_T GbBSW_NvmRealtimeVld_flg = TRUE;

volatile uint16_T COMR_YearSetNvmRd = 0U;
volatile uint8_T COMR_MonthSetNvmRd = 0U;
volatile uint8_T COMR_DaySetNvmRd = 0U;
volatile uint8_T COMR_HourSetNvmRd = 0U;
volatile uint8_T COMR_MinSetNvmRd = 0U;

volatile uint16_T GaISP_CellVoltUpdCnt_numb[112] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                  0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile uint16_T GaISP_ModTempUpdCnt_numb[48] = {0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U,
                                                0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U, 0U};

volatile boolean_T GbBSW_DispSOCOverWrite_flg = FALSE;
volatile uint8_T GcBSW_DispSOCOverWrite_pct = 0U;
volatile boolean_T GbBSW_RealSOCOverWrite_flg = FALSE;
volatile uint8_T GcBSW_RealSOCOverWrite_pct = 0U;

volatile uint8_T DFC_AFEResetFlt_ASW = 0U;
volatile uint8_T DFC_PreHeatErr_ASW = 0U;
volatile uint8_T DFC_MposRlyDrvOvrCurr_ASW = 0U;
volatile uint8_T DFC_MNegRlyDrvOvrCurr_ASW = 0U;
volatile uint8_T DFC_DChrgPosRlyDrvOvrCurr_ASW = 0U;
volatile uint8_T DFC_DChrgNegRlyDrvOvrCurr_ASW = 0U;
volatile uint8_T DFC_PreRlyDrvScb_ASW = 0U;
volatile uint8_T DFC_PreRlyDrvScg_ASW = 0U;
volatile uint8_T DFC_PreRlyDrvOL_ASW = 0U;
volatile uint8_T DFC_PrRlyDrvOvrCurr_ASW = 0U;
volatile uint8_T DFC_ChrgCmuLost_ASW;      /* Max fault of battery soc out of range high */
volatile uint8_T DFC_DisChrgCmuLost_ASW;   /* Min fault of battery soc out of range high */
volatile uint16_T COMR_pMaxpwrObcChrg = 0U;


volatile uint8_T COMR_stHoldTempVcuPermit = 0U;
volatile uint8_T COMR_stHoldTempEna = 0U;
volatile boolean_T COMR_bIviHoldTempSW = 0U;
volatile boolean_T COMR_bIviHoldTempTimer = 0U;

volatile uint8_T COMR_stHoldTempReq = 0U;
volatile real32_T COMR_tiPreThemaltime = 0.0F;

volatile uint8_T BCMR_stHoldTempMode = 0U;
// volatile uint8_T BCMR_stHoldTempReq = 0U;
volatile uint32_T BSPR_TotalOdometer = 0UL;

volatile uint8_T DFC_ThmRnwyAlarm_ASW = 0U;

volatile boolean_T GbISP_CellVoltUpd_flg = FALSE;
volatile boolean_T GbISP_CellTempUpd_flg = FALSE;
volatile boolean_T GbISP_BusbarTempUpd_flg = FALSE;

volatile uint32_T BSER_rSocAvrg_Nvm = 0UL;
volatile uint32_T BSER_rSocMax_Nvm = 0UL;
volatile uint32_T BSER_rSocMin_Nvm = 0UL;
volatile uint32_T BSER_rSocDspl_Nvm = 0UL;

volatile uint32_T BCCR_uDChrgNegVoltStgFrstMax_Nvm = 0UL;
volatile uint32_T BSPR_uPackVoltRawEnd_Nvm = 0UL;
volatile uint32_T BSER_cSocDchAhFulRev_Nvm = 0UL;

volatile uint32_T BSPR_iCurrOfsAdap_Nvm = 0UL;
volatile uint8_T BSW_stNvmShutDown;
volatile uint8_T BSW_stNvmRunning;

volatile uint8_T GeISP_CellVoltValid_enum = 0U;  /* 电芯电压有效性原始bit位 */
volatile uint8_T GeISP_CellTempValid_enum = 0U;  /* 电芯温度有效性原始bit位 */

volatile uint8_T GcISP_Diag10MainID_numb = 0U;
volatile uint8_T GcISP_Diag10SubID_numb = 0U;
volatile uint8_T GcISP_Diag11MainID_numb = 0U;
volatile uint8_T GcISP_Diag11SubID_numb = 0U;

volatile uint8_T GbISP_Diag10EOK_flg = FALSE;
volatile uint8_T GbISP_Diag11EOK_flg = FALSE;

volatile uint32_T BTMR_tiShortRuntimeSumRd = 0UL;
volatile uint8_T BTMR_idxShrtLowVoltIDRd = 0U;
volatile real32_T BTMR_uShrtCellVoltDiffRd = 0.0F;
volatile boolean_T BTMR_bShrtLowVoltIDFitRd = FALSE;
volatile uint16_T BTMR_tiRuntimeCalRd = 0UL;

volatile boolean_T GbRTE_BMSChgModeHold_flg = FALSE;
volatile uint8_T BMS_GB_ChgMode_last = 0U;
#define ASW1_OEM_STOP_SEC_DEFAULT_RAM2_INIT_UNSPECIFIED
#include "Asw1_OEM_MemMap.h"

/*<--------EOF-------->*/