Tool/software: Code Composer Studio
Dear Ti community
I'm developing PCMC on HVPSFB.
But I cannot understand the calculation of Kv.
For exemple about Vfbin.
- First, It's supposed that Vfbin =Vfbin [V]
- Then the input of ADC is lowered by gain Gfb . So the input of ADC is Gfb * Vfbin[V].
- The output of ADC is Gfb * Vfbin *2^12/3.3 (Q12).
- After that,Q12 change Q15 at line 827 in main.c. It means Q15 number is Gfb * Vfbin *2^12/3.3 * 2^3 = Gfb * Vfbin *2^15/3.3(Q15)
- Then,multipled Kv(Q15) and shift 15 at line 828 in main.c .It means Gui_Vfbin(Q15) = Gfb * Vfbin *2^15/3.3(Q15) * Kv(Q15) / 2^15.
- To display Vfbin [V] in GUI, Gui_Vfbin(Q15) = Vfbin * 2^15
- By 5. and 6. , Kv(Q15) = 2^15*3.3/Gfb
I want you to tell where it's wrong.