Main Content

RT.Driver

Represent device driver in real-time kernel

Since R2023b

Description

An RT.Driver object represents a device driver in the real-time kernel.

Creation

Use the loadDriver function to load a device driver in the real-time kernel.

Properties

expand all

The Parent property provides the name of the kernel object that is the parent of the device driver.

The name of the device driver.

The device driver address.

The I/O sizes of devices. The array contains the sizes of all supported I/O types:

  • Analog I/O

  • Digital I/O

  • Counter I/O

  • Encoder I/O

  • Other I/O

  • Stream I/O

Object Functions

loadDriverLoad driver instance into real-time kernel

Examples

collapse all

This example shows how to get driver property values for the RT.Driver object.

Create a variable that represents the driver, then get the Name property value.

openExample('sldrtex_counter');
myBoard = get_param(['sldrtex_counter','/Counter Input'], 'DrvName');
myDriver = loadDriver(RT.Kernel,myBoard);
myDriver.Name
ans =

    'Standard_Devices/UDP_Protocol'

Version History

Introduced in R2023b