> 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/library-specific-guides/motor-drives/modify-a-drive-block.md).

# Modify a Drive Block

If you have to change electrical connections or control modules, you can do so by modifying a drive block. In the following example, the three‑phase electrical source is replaced with a battery.

Open the **ac6\_example** by typing ac6\_example in the MATLAB® Command window. The drive is fed by a three-phase voltage source.

## Break the link of the drive block

1. Simulate the model (in accelerator mode) and observe the results.
2. Break the link between the drive block and its library.
3. Right-click the block, and then select **Library Link** > **Disable Link**.
4. Right-click the block again, and then select **Library Link** > **Break Link**

## Modify the drive block

1. Right-click the drive block and select **Mask** > **Look Under Mask**.
2. Delete the three-phase electrical connections, the diode rectifier, and the braking chopper.

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

3. Right-click the Permanent Magnet Synchronous Machine block and select **Mask** > **Look Under Mask**. Select the A and B Connection Port block, and copy them to the top-level model. Connect the blocks to the positive and negative terminals of the Three-Phase Inverter block. Add a Simulink<sup>®</sup> Ground block and connect it to the output port Conv.

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

## Use the Customized Drive Block

1. Save the model as ac6\_example2.
2. In the diagram, delete the three-phase source. Replace it with a 300Vdc/1Ah/NiMH Battery block and a 100 µF capacitor block connected in parallel.
3. Connect the Conv output of the block to a Terminator block. Remove the DC bus voltage blocks that are in the Demux block.

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

4. Add a Bus Selector block and then select the **Voltage (V)** bus signal coming from the `m` output of the Battery block.

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


---

# 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/library-specific-guides/motor-drives/modify-a-drive-block.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.
