I think you accidently swapped the 1.2 and 0.48 in the Ki calculation:
double PID_ATune::GetKi()
{
return controlType==1? 1.2*Ku / Pu : 0.48 * Ku / Pu; // Ki = Kc/Ti
}
Should be like this for Ziegler & Nichols (closed loop):
double PID_ATune::GetKi()
{
return controlType==1? 0.48 * Ku / Pu : 1.2 * Ku / Pu; // Ki = Kc/Ti
}
/Thanks