Table of Contents
quanser.hardware.hil.get_string_property
Get the values of the given string properties of the board.
[values, err] = board.get_string_property(properties)
Returns the values of the given string properties of the board. Not all boards support properties. Properties are generally used for features of the board that may be reconfigured periodically, rather than configured once through the card-specific options (see set_card_specific_options). They are also used to get information about the card. For example, properties may often be used to get the vendor ID and product ID of a card, or the manufacturer. They might also be used for calibrating the A/Ds or D/As on the card.
Properties are identified by a numeric code and boards may have property codes unique to the board. Such custom properties are always assigned a property code of 128 or higher. Property codes between 0 and 127 are reserved for standard properties. There is a separate set of property codes for string properties. Integer-valued properties have their own set of property codes, as do double properties.
If no err output is provided then it throws an exception if an error occurs. In generated code it prints the error message. Use hil_get_error_message to get the message associated with an error code.
board
The board instance returned by the quanser.hardware.hil.open function.
properties
An array of property codes or a string or cell array of strings identifying standard properties. Valid strings are currently:
Property |
Code |
Description |
---|---|---|
'manufacturer' |
0 |
manufacturer of the board |
'product_name' |
1 |
product name of the board |
'model_name' |
2 |
model name of the board |
'serial_number' |
3 |
serial number of the board |
'firmware_version' |
4 |
firmware version on the board (may be different firmware than integer properties for firmware) |
Other integral property codes may be supported but are board-specific. Custom codes are always given the value of 128 or above.
values
A cell array of the string property values
err
A negative error code or zero on success.
values = board.get_string_property(0:2); % Get information about the board
See Also
Copyright ©2024 Quanser Inc. This page was generated 2024-10-17. Submit feedback to Quanser about this page.
Link to this page.