opcqid
(To be removed) Construct quality ID from item quality
Support for the OPC Data Access (DA) standard will be removed in a future release. Instead use OPC Unified Architecture (UA). See Version History.
Syntax
QualityID = opcqid(QualityStr)
Description
QualityID = opcqid(QualityStr)
returns the quality ID, which is a number between 0 and 255, corresponding to the
specified quality attribute. The quality must be a character vector or string in the
form '
.Major Quality
: Quality
Sub-status
(Limit
Status
)'
If QualityStr
is an array of quality values, then
QualityID
will be a matrix having the same size as
QualityStr
.
For more information on quality values, see OPC Quality.
Examples
Construct the quality ID from the quality text of the item
Random.Real8
on the Matrikon™ OPC Simulation Server:
da = opcda('localhost','Matrikon.OPC.Simulation'); connect(da) grp = addgroup(da); itm = additem(grp,'Random.Real8'); qualityID = opcqid(itm.Quality)