Other Parts Discussed in Thread: CONTROLSUITE
Hello !
I have some questions about HVPSFB kit in PCMC-mode:
1. I don't understand why it is need to change connection for PWM1,2,4 in PCMC and VMC mode by J2 and J3
What is the problem or may be what the reason is ?
2. The part of code in PCMC\HVPSFB-Main.c (lines 866 - 870 )
// Voltage setting calculated by:
// Vref = Gui_VfbSet * iK_Vfbout, where iK_Vfbout = 1/K_Vfbout (i.e. inverse K_Vfbout)
// view and set following variable in Watch Window as:
// Gui_VfbSet = Q10 (Used as Q15 below)
Vref = ( (long) Gui_VfbSet * (long) iK_Vfbout ) >> 5; // (Q15 * Q14) >> 5 = Q24
In this example the result Vref = (Q10 * Q14) >> 5 = Q24 >> 5 = Q19 so why Q24 ?
I'm not understand how Gui_VfbSet may be used as Q15 ? Where is conversion to Q15 ?
3. The another part of code in PCMC\HVPSFB-Main.c (lines 763 - 778 )
// This is an example code for implementing the slew rate control in
// a slower state machine instead of implementing it in the ISR.
// VfbSlewRate should be set as a positive value
Vfb_slew_temp = Vref - VfbSetSlewed;
if (Vfb_slew_temp >= VfbSlewRate) // Positive Command
{
VfbSetSlewed = VfbSetSlewed + VfbSlewRate;
}
else
{
if ((-1)*(Vfb_slew_temp) >= VfbSlewRate) // Negative Command
{
VfbSetSlewed = VfbSetSlewed - VfbSlewRate;
}
}
Question:
VfbSlewRate = 25600, it is 0.0015 (Q24)
What is the reason of correction of VfbSetSlewed value by so small value ?
Best regards, Grigory