STM32 MCSDK Discontinuous PWM support (new in V5.Y)

Revision as of 20:47, 22 April 2021 by Registered User


1. Discontinuous PWM overview (DPWM)

DPWM feature allows to user to reduce the switching losses by using an additional modulation technique according to their application.

This new approach will be added to the current default 3-phase modulation.

It will be deployed in all supported configurations:

  • 3Shunt
  • 1Shunt
  • ICS
  • with sensor or sensor less.

DPWM mode is available for overall MCU family supported by MCSDK5.x

Target market:

  • Home appliances / High voltage applications: Air-conditioner fan, Air-conditioner compressor, Refrigerator compressor

2. DPWM / 2-phase description

By suppressing (0,0,0) state then 2 switching per cycle can be removed (here named with low side – usually high side) :

Duty A is enlarged by PWM period – Duty A, in order to cover the whole PWM period.

As (1,1,1) state has been enlarged of duty A, in that case:

  • Duty B = Duty B + Duty A
  • Duty C = Duty C + Duty A

3. 2-phase vs 3-phase modulation

CCR1,CCR2,CCR3 – applied PWM duty on U,V,W

4. DPWM activation via Cube Mx setting

As the activation of DPWM is not yet supported by the WB, it is needed to edit the .ioc file with STM32 Cube Mx.

To enable the DPWM mode, set to “ON” the DISCONTINUOUS_PWM in parameter settings of Motor Control as shown below.

5. FW changes DPWM

When a project is generated with the DPWM, the activation of 2-phase modulation will be effective at startup phase (just after the calibration).

The DPWM is enabled all time in 3Shunt case, while it is not the case in 1Shunt.

In 1-Shunt case, since in Boundary 2 or 3, the phase A & B are used for current sensing, in this specific situation it is not possible to work on 2-phase SVPWM. The workaround consists to switch automatically on 3-phase during this transition phases.

6. DPWM API functions

FW API specific to DPWM:

  • void PWMC_DPWM_ModeEnable( PWMC_Handle_t * pHandle )
    • enables the Discontinuous PWM mode by setting the global variable.
  • void PWMC_DPWM_ModeDisable( PWMC_Handle_t * pHandle )
    • disables the Discontinuous PWM mode by setting the global variable.
  • bool PWMC_GetDPWM_Mode( PWMC_Handle_t * pHandle )
    • returns the status of Discontinuous mode activation 

// annexe ???

7. 2 phase vs 3 phase modulation

Dynamically moving between 3 phase modulation to 2 phase modulation:

  • At 10W:
  • At 50W:

Legend: Ch1: Current (Ia) Ch2: UL Ch3: VL Ch4: WL

8. 2 phase modulation: Startup in 3 shunt mode!

Can Start Successfully: