最近在做一個電源,用單片機實現恒功率輸出,但是上板發現,,電壓都變化了,電流還沒怎么變化,不知何故,還請高人指導。貼出部分代碼,還請大家多多指導~
temp=P_Set_Value/U_AD_Value;
if( temp < Set_Value[1])
{
I_Set_Value=temp;
}
else
{
I_Set_Value=Set_Value[1];
}
STATUS1.I_Ctr_BZ=1;
STATUS1.U_Ctr_BZ=0;