qc_add_target_uri qc_remove_target_uri navigation bar

Table of Contents

qc_get_target_uris

Returns a list of all the URIs that may be used to connect to a target.

Syntax

[uris, result] = qc_get_target_uris(model)      % Get a list of all the URIs available for the target associated with MODEL
[uris, result] = qc_get_target_uris(config_set) % Get a list of all the URIs available for the target associated with the configuration set
[uris, result] = qc_get_target_uris(target_uri) % Get a list of all the URIs available for the target specified by the target URI
[uris, result] = qc_get_target_uris             % Get a list of all the URIs available for the target associated with the current model
    

Description

Returns a list of all the URIs that may be used to connect to a target. The list is returned as a structure array where each structure contains two fields:

key = the key associated with the URI, as a string
uri = the full URI, as a string

The qc_add_target_uri and qc_remove_target_uri functions may be used to add and remove URIs from this list. Be very careful using the qc_remove_target_uri function because if all the URIs for a target are removed there will no longer be any means of connecting to that target!

If MODEL is specified, then the target URI associated with the active configuration set of that model is used to identify the target. If a configuration set is specified then its associated target URI is used. If a target URI is specified then it is used directly to access the target.

If no target URI is specified via a model, configuration set or URI then the target associated with the current model is used.

Parameters

model

A string indicating the name of the model from which to identify the target eg. 'q_a_lpbk'.

config_set

A Simulink.ConfigSet configuration set from which to identify the target (see getConfigSet).

target_uri

A string containing the URI used for communicating with the QUARC Target Manager on the target.

Outputs

uris

A structure array containing the list of URIs. See the Description above for the fields in the structure.

result

Returns 0 on success and a negative error code on failure. See qc_error and qc_get_error_message for handling error codes. If no result output is assigned it issues an error on failure.

Examples

uris = qc_get_target_uris; % Gets the URIs being served by the current target
    

See Also

 

navigation bar