This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F280039C:TMS320F280039C

Part Number: TMS320F280039C
Other Parts Discussed in Thread: SFRA, C2000WARE

Tool/software:

I am currently designing a program for an inverter, using PR control for the controller. However, after several tests, I found that my current command (ui) always stays at the saturation value I set, and the switching cannot modulate. Is there something wrong with my settings?

my pr conroller code:

 // --- voltage ---
    ev = v_ref - v_feedbackcorrect;
    uv = (b0_v * ev + b1_v * ev1 + b2_v * ev2) + (a1_v * uv1 - a2_v * uv2);
    ev2 = ev1 ; ev1= ev ; uv2 = uv1 ; uv1= uv;

    if (uv > 10000)
    {
        uv = 10000;
    }
    else if (uv < -10000)
    {
        uv = -10000;
    }

    i_ref = uv;  // 將電壓控制器輸出作為電流參考

    // --- current ---
    //ei =  i_test_phase - i_feedbackcorrect;
    ei =  i_ref - i_feedbackcorrect;
    ui = (b0_i * ei + b1_i * ei1 + b2_i * ei2) + (a1_i * ui1 - a2_i * ui2);
    //ui = 901.62;
    ei2 = ei1 ; ei1 = ei ; ui2 = ui1 ; ui1= ui;

    if (ui > 923*0.99)
    {
        ui = 923*0.99;
    }
    else if (ui < -923*0.99)
    {
        ui = -923*0.99;
    }
  • Check the open loop operation by applying applying same Vin and same PWM waveform to generate the same Vout you are trying to control in closed loop. If you cannot do this then your signal scaling needs to be adjusted.

    If this works, then it could be a PID controller issue. Run SFRA and then tune your loop. This is documented in our ref design docs. See C2000Ware Digital Power SDK for detail on many such ref designs

  • Check the open loop operation by applying the same Vin and the same PWM waveform to generate the same Vout you are trying to control in closed loop. Do you mean that I am simply testing the current loop? Thank you for your reply.

  • Yes, that will be a test for the inner current loop. As I understand, your outer volt loop generates the ref current command for the inner current loop