Compare commits
2 Commits
f8ccef77d8
...
cfb888ee99
Author | SHA1 | Date |
---|---|---|
|
cfb888ee99 | |
|
b9c7ebb4fc |
|
@ -2882,17 +2882,25 @@ static char ptz_hori_get_angle_a()
|
||||||
// tem4 = tem4 + 360.0;
|
// tem4 = tem4 + 360.0;
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
if(tem4 == 360.0)///////˝âžöźČĎÔĘž360ÓÖĎÔĘž˝ÇśČ0ľÄÎĘĚâ
|
//避免出现异常
|
||||||
|
for(uint8_t i = 0; i < 3; i++)
|
||||||
{
|
{
|
||||||
tem4 = 0;
|
if(tem4 == 360.0)///////解决既显示360又显示角度0的问题
|
||||||
}
|
{
|
||||||
if(tem4 < 0)
|
tem4 = 0;
|
||||||
{
|
}
|
||||||
tem4 = tem4 + 360.0;
|
else if( tem4 < 0 )
|
||||||
}
|
{
|
||||||
if(tem4>360.0)
|
tem4 = tem4 + 360.0;
|
||||||
{
|
}
|
||||||
tem4 = tem4 - 360.0;
|
else if( tem4 > 360.0 )
|
||||||
|
{
|
||||||
|
tem4 = tem4 - 360.0;
|
||||||
|
}
|
||||||
|
if (tem4 >=0 && tem4 <= 360.0)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
g_ptz.hori_angle_actual = tem4;
|
g_ptz.hori_angle_actual = tem4;
|
||||||
|
|
||||||
|
|
|
@ -485,7 +485,7 @@ static char ptz_heat_data_collect_task()
|
||||||
{
|
{
|
||||||
ptz_heat_collect_adc1_task();
|
ptz_heat_collect_adc1_task();
|
||||||
|
|
||||||
if ( g_ptz.electric_current > 4.0 ) //过流
|
if ( g_ptz.electric_current > 5.5 ) //过流
|
||||||
{
|
{
|
||||||
overCurrTime++;
|
overCurrTime++;
|
||||||
}
|
}
|
||||||
|
@ -503,7 +503,7 @@ static char ptz_heat_data_collect_task()
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ( g_ptz.electric_current < 2.0 ) //电流恢复正常
|
if ( g_ptz.electric_current < 3.5 ) //电流恢复正常
|
||||||
{
|
{
|
||||||
currTime++;
|
currTime++;
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,7 +36,7 @@ static char ptz_temp_volt_current_fault_detect_task()
|
||||||
hori_fault = 0;
|
hori_fault = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(V_ADC_Collect.Phase_curr_V >= PHASE_CURRENT ||V_ADC_Collect.Phase_curr_U >= PHASE_CURRENT ||V_ADC_Collect.Phase_curr_W >= PHASE_CURRENT )
|
if(V_ADC_Collect.Phase_curr_V >= PHASE_CURRENT_VERT ||V_ADC_Collect.Phase_curr_U >= PHASE_CURRENT_VERT ||V_ADC_Collect.Phase_curr_W >= PHASE_CURRENT_VERT )
|
||||||
{//堵转检测,防止电机堵转烧坏,结合电机卡死故障监测,与云台工作电流监测。
|
{//堵转检测,防止电机堵转烧坏,结合电机卡死故障监测,与云台工作电流监测。
|
||||||
if ( g_ptz.fault_detect.Phase_curr_V != FAULT )
|
if ( g_ptz.fault_detect.Phase_curr_V != FAULT )
|
||||||
{
|
{
|
||||||
|
|
|
@ -107,7 +107,7 @@
|
||||||
#define PTZ_VOLT_DETECT_MIN 18.0//30.0
|
#define PTZ_VOLT_DETECT_MIN 18.0//30.0
|
||||||
|
|
||||||
//工作电流阈值
|
//工作电流阈值
|
||||||
#define PTZ_CURRENT_DETECT 5.5//5.0
|
#define PTZ_CURRENT_DETECT 7.0//5.0
|
||||||
|
|
||||||
//霍尔故障阈值
|
//霍尔故障阈值
|
||||||
#define PTZ_HALL_DETECT 30//30
|
#define PTZ_HALL_DETECT 30//30
|
||||||
|
@ -115,6 +115,7 @@
|
||||||
//相电流运行最大值
|
//相电流运行最大值
|
||||||
// #define PHASE_CURRENT 5.0
|
// #define PHASE_CURRENT 5.0
|
||||||
#define PHASE_CURRENT 10.0
|
#define PHASE_CURRENT 10.0
|
||||||
|
#define PHASE_CURRENT_VERT 20.0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//L6235D涡轮蜗杆重型云台
|
//L6235D涡轮蜗杆重型云台
|
||||||
|
|
Loading…
Reference in New Issue