> For the complete documentation index, see [llms.txt](https://www.opal-rt.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.opal-rt.com/docs/smart-power-simulation-software-sps/example-models/motor-drives/speed-regulation-of-a-brushless-dc-motor-drive-using-a-variable-dc-link-six-step-inverter.md).

# Speed Regulation of a Brushless DC Motor Drive Using a Variable DC Link Six Step Inverter

This example demonstrates the speed regulation of a brushless DC (BLDC) motor drive using a variable DC link six-step inverter.

<figure><img src="https://799605156-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdlNg8IbOdahCpFCyzxSN%2Fuploads%2Fgit-blob-9f704e35e8f693dfa405833251b5a46ea6367334%2Fspeed_regul_brushlessDCmotor_variableDClink_6stepinverter.png?alt=media" alt=""><figcaption></figcaption></figure>

## Description

In its basic form, BLDC motors consist of a trapezoidal back-EMF permanent magnet synchronous motor fed by a three-phase inverter. A position sensor attached to the rotor provides the position signals required to synchronize the stator currents with the back-EMFs so that the motor operates as a synchronous motor at all times. Because the voltage magnitude is proportional to the motor speed, the speed can then be regulated by varying the DC link voltage connected to the three-phase inverter.

### Electrical Model

A DC/DC converter is fed by an ideal DC source and its output filter allows you to vary the DC link voltage. The DC bus is connected to a three-phase, two-level converter. This converter generates the appropriate three-phase voltage for the operation of the 300 W, 4000 rpm BLDC motor.

### Control System

The main components of the control system are:

1. Speed Regulator - The regulator compares the actual motor speed to the speed reference and generates the DC voltage reference.
2. Voltage Regulator - The measured DC link voltage is compared to the reference value. The resulting error is fed to the anti-windup PI regulator. To correct the error, the regulator outputs the required duty cycle (D) value to the DC-DC converter.
3. Commutation Sequences and Pulses Generation - Because the back-EMFs are of trapezoidal form (with a flat area of 120o), the maximum torque with the lowest ripple develops if the currents are kept constant during the time intervals when the back-EMFs are also constant. This condition implies a six-step operation for the inverter where only two phases are conducting at a time. Based on the rotor position (obtained from the Hall Effect sensors) and the motor rotation direction, this block generates appropriate pulses to the three-phase inverter feeding the motor.

This table lists the six possible commutation sequences for the counterclockwise rotation of the motor:

<figure><img src="https://799605156-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdlNg8IbOdahCpFCyzxSN%2Fuploads%2Fgit-blob-c595268076118dde74c42ffd17f9bcfc4f3795d2%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

This figure shows two commutation sequences for the counterclockwise rotation of the motor.

<figure><img src="https://799605156-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdlNg8IbOdahCpFCyzxSN%2Fuploads%2Fgit-blob-315d34e9e5d58fa75137ae92a69ebe10a7e9b91d%2Fcommutation_seq_rotation_motor.png?alt=media" alt=""><figcaption></figcaption></figure>

For proper operation of a BLDC motor, it is necessary to keep the angle between the stator and rotor flux close to 90 degrees. With six-step control, the motor has a total of six possible stator flux vectors. The stator flux vector must be changed at a certain rotor position. However, with a six-step control technique it is not possible to keep the angle between the rotor flux and the stator flux at 90 degrees. The real angle varies from 60 degrees to 120 degrees.

For the \[C- B+] sequence, you can verify from the left image in the diagram that the position of the rotor north pole varies from 60 degrees to 120 degrees ahead of the stator north pole, with repulsion between poles of same polarity producing a counterclockwise rotation. At the same time, the position of the rotor south pole varies from 120 degrees to 60 degrees behind the stator north pole, with attraction between two opposite poles still producing counterclockwise rotation.

## Simulation

Run the simulation and observe the waveforms on Scope 1. Initially, the motor rotates at 4000 rpm with no load.

At 0.1 s, a load torque of 0.6 N.m is applied to the motor. The control system increases the DC link voltage reference in order to maintain the motor speed at 4000 rpm.

At 0.25 s, the speed reference is reduced to 1000 rpm. The control system significantly decreases the DC link voltage reference in order to respect the new speed reference. Notice the reduced frequency of the motor phase currents.

On Scope 2, you can observe the DC regulator output (D) as well as the DC link voltage variations.

## Command

Example model name: power\_motordrive\_BLDC\_SixStepInverter

{% code lineNumbers="true" %}

```matlab
open('power_motordrive_BLDC_SixStepInverter')
```

{% endcode %}

## References

Musil, J. *3-Phase BLDC Drive Using Variable DC Link Six-Step Inverter.* Freescale Czech Systems Laboratories. 2006.

Motor Control (Part 1): An Introduction to Brushless DC Motors, Melda Ulusoy, MathWorks


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://www.opal-rt.com/docs/smart-power-simulation-software-sps/example-models/motor-drives/speed-regulation-of-a-brushless-dc-motor-drive-using-a-variable-dc-link-six-step-inverter.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
