> 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/rt-lab/simulink-blocks-reference/rt-lab-library/opasyncgenctrl.md).

# OpAsyncGenCtrl

## Description

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

The **OpAsyncGenCtrl** block, located in the **RT-LAB/Communication/Asynchronous** library, configures the settings of a user-defined asynchronous executable. All asynchronous Send and Receive blocks that share the same Controller ID reference this block. The controller provides generic fields to pass parameters to the executable it launches. Refer to the section **RT-LAB Asynchronous process** of chapter **RT-LAB Connectivity** of the **User Guide** for more details.

## Mask parameters

<figure><img src="https://96827845-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNRdpSk8kjn20gXAexnt6%2Fuploads%2Fgit-blob-b88389c96c10f91753fae4c424d9c356f73f361e%2FRTE_opasyncgen_ctrl_mask.png?alt=media" alt="" width="375"><figcaption></figcaption></figure>

<table><thead><tr><th width="195.8182373046875">Parameter</th><th>Description</th></tr></thead><tbody><tr><td><strong>Controller ID</strong></td><td>Specifies the controller ID associated with each OpAsyncSend and OpAsyncRecv block.</td></tr><tr><td><strong>Parameter page</strong></td><td>Displays the Float/String parameters page by page.</td></tr><tr><td><strong>Float parameter 1 .. 12</strong></td><td>Values entered in these fields are available to the asynchronous application by calling the OpalGetAsyncCtrlParameters function. These twelve values are placed in the FloatParam array of the Opal_GenAsyncParam_Ctrl structure. Example:</td></tr><tr><td><strong>String parameter 1 .. 12</strong></td><td><p>Characters entered in these fields are available to the asynchronous application by calling the OpalGetAsyncCtrlParameters function. These twelve strings are placed in the StringParam array of the Opal_GenAsyncParam_Ctrl structure.</p><p><em>EX:</em><br><em>Opal_GenAsyncParam_Ctrl Param;</em><br><em>OpalGetAsyncCtrlParameters(&#x26;Param,sizeof(Opal_GenAsyncParam_Ctrl));</em><br><em>printf("The first string parameter is %s\n",Param.StringParam[0]);</em></p></td></tr><tr><td><strong>Name of executable</strong></td><td>Name of the executable program developed to handle communications between Send and Recv blocks. Note: the controller must be able to find the executable. The program must be in the simulation directory or in the system path.</td></tr></tbody></table>

## Inputs <a href="#inputs" id="inputs"></a>

This block has no inputs.

## Outputs <a href="#outputs" id="outputs"></a>

This block has no outputs.

## Characteristics and Limitations <a href="#characteristics-and-limitations" id="characteristics-and-limitations"></a>

| Characteristic       | Value                  |
| -------------------- | ---------------------- |
| Direct Feedthrough   | N/A                    |
| Discrete sample time | No                     |
| XHP support          | Yes (Partial XHP only) |
| Work offline         | No                     |


---

# 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/rt-lab/simulink-blocks-reference/rt-lab-library/opasyncgenctrl.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.
