|
@@ -332,30 +332,34 @@ int qca7000FlashCheck()
|
|
|
void ccsOverCurrentProtection(uint8_t gun_index)
|
|
|
{
|
|
|
if((ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'E') ||
|
|
|
- (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'T') ||
|
|
|
- (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'Z'))
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'T') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'Z') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'M') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'P') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'I') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'F'))
|
|
|
{
|
|
|
- Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) - 100;
|
|
|
- Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) - 200;
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- if(ShmCharger->gun_info[gun_index].targetCurrent > 20)
|
|
|
- {
|
|
|
- Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) + 0;
|
|
|
- Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) - 200;
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * 100) + 200;
|
|
|
- Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * 100) + 0;
|
|
|
- }
|
|
|
- }
|
|
|
+ Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) + 0;
|
|
|
+ Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) - 200;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if(ShmCharger->gun_info[gun_index].targetCurrent > 20)
|
|
|
+ {
|
|
|
+ Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) + 0;
|
|
|
+ Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * OCP_Magnification) - 200;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ Over_Current[gun_index].OC_BegThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * 100) + 200;
|
|
|
+ Over_Current[gun_index].OC_EndThreshold = (ShmCharger->gun_info[gun_index].targetCurrent * 100) + 0;
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
#ifdef isDebugPrint
|
|
|
- DEBUG_INFO("Gun-[%d] OC_BegThreshold: %d \n", gun_index, Over_Current[gun_index].OC_BegThreshold);
|
|
|
- DEBUG_INFO("Gun-[%d] OC_EndThreshold: %d \n", gun_index, Over_Current[gun_index].OC_EndThreshold);
|
|
|
- #endif
|
|
|
+ DEBUG_INFO("Gun-[%d] OC_BegThreshold: %d \n", gun_index, Over_Current[gun_index].OC_BegThreshold);
|
|
|
+ DEBUG_INFO("Gun-[%d] OC_EndThreshold: %d \n", gun_index, Over_Current[gun_index].OC_EndThreshold);
|
|
|
+ #endif
|
|
|
}
|
|
|
|
|
|
|
|
@@ -379,11 +383,15 @@ int main(void)
|
|
|
}
|
|
|
|
|
|
if((ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'E') ||
|
|
|
- (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'T') ||
|
|
|
- (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'Z'))
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'T') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'Z') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'M') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'P') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'I') ||
|
|
|
+ (ShmSysConfigAndInfo->SysConfig.ModelName[3] == 'F'))
|
|
|
{
|
|
|
// Europe
|
|
|
- OCP_Magnification = 125;
|
|
|
+ OCP_Magnification = 115;
|
|
|
}
|
|
|
else
|
|
|
{
|