Skip to Main Content Skip to Search
Product Documentation

Function Reference


OPC Data Access (DA)Functions supporting OPC data access
OPC Historical Data Access (HDA)Functions supporting OPC historical data access

OPC Data Access (DA)

Object Creation and Configuration

addgroupAdd data access group to opcda object
additemAdd data access items to dagroup object
clonegroupClone group into new private group on same client
connectConnect OPC Toolbox client to server
copyobjMake copy of OPC data access object
deleteRemove OPC Toolbox objects from memory
disconnectDisconnect OPC Toolbox client from server
dispSummary of information for OPC Toolbox objects
getOPC Toolbox object properties
isvalidTrue for undeleted OPC Toolbox objects
makepublicConvert private group into public group
opcdaConstruct OPC data access object
removepublicgroupRemove public group from server
setConfigure or display OPC Toolbox object properties

Server Exploration

flatnamespaceFlatten hierarchical OPC name space
getnamespace (opcda)OPC data access server name space
opcserverinfoVersion, server, and status information
serveritempropsProperty information for items in OPC server name space
serveritemsQuery server or name space for fully qualified item IDs

Data Access

cancelasyncCancel asynchronous read and write operations
opc.daQualityStringOPC data access part of quality ID as strings
readRead data synchronously from OPC groups or items
readasyncRead data asynchronously from group or items
refreshRead all active items in group
writeWrite values to group or items
writeasyncAsynchronously write values to group or items

OPC Data Visualization

trendDisplay graphical trend of OPC data for group

Logging and Buffering

flushdataRemove all logged data records associated with dagroup object
getdataLogged records from OPC Toolbox engine to MATLAB workspace
opcreadRead logged records from disk to MATLAB workspace
opcstruct2arrayConvert OPC data from structure to array format
opcstruct2timeseriesConvert OPC data from structure to time series format
peekdataPreview most recently acquired data
startStart a logging task
stopStop a logging task
waitSuspend MATLAB execution until object stops logging

Simulink Support

genslreadGenerate Simulink OPC Read block from MATLAB group object
genslwriteGenerate Simulink OPC Write block from MATLAB group object

Utilities

cleareventlogClear event log, discarding all events
loadLoad OPC Toolbox objects from MAT-file
obj2mfileConvert OPC Toolbox object to MATLAB code
opccallbackEvent information for OPC Toolbox callbacks
opcfindFind OPC Toolbox objects with specific properties
opchelpHelp for OPC Toolbox data access function or property
opcqidConstruct quality ID from item's quality string
opcqpartsExtract quality parts from OPC quality ID
opcqstrConvert OPC quality ID into readable string
opcregisterInstall and register OPC Foundation Core Components
opcresetDisconnect and delete all OPC Toolbox objects
opcsupportRun OPC Toolbox troubleshooting utility
opctoolOpen OPC Tool GUI
openosfOpen OPC Tool GUI session file
propinfoProperty information for OPC Toolbox objects
saveSave OPC Toolbox objects to MAT-file
showopceventsEvent log summary for OPC Toolbox events

OPC Historical Data Access (HDA)

Server Connection

connectConnect OPC Toolbox client to server
deleteRemove OPC Toolbox objects from memory
disconnectDisconnect OPC Toolbox client from server
getNameSpace (opchda)OPC historical data access server name space
isConnectedTrue if HDA Client is connected to server
opc.hda.ClientConstruct an OPC Historical Data Access Client
opc.hda.resetDisconnect and delete all OPC HDA Client objects

Data Retrieval

readAtTimeRead data from an OPC HDA server at specified times
readItemAttributesRead item attribute values from OPC HDA server
readModifiedRead modified data from an OPC HDA server
readProcessedRead server-aggregated data from an OPC HDA server
readRawRead raw data stored over a time range from HDA server

AggregateType Methods

getDescription Get description of OPC HDA Aggregate Type or Item Attribute
getIDFromnameTranslate OPC HDA aggregate type or item attribute name to numeric identifier
getIDListGet all aggregate type or item attribute IDs
getNameListGet all aggregate type or item attribute names

ItemAttributes Methods

getDescription Get description of OPC HDA Aggregate Type or Item Attribute
getIDFromnameTranslate OPC HDA aggregate type or item attribute name to numeric identifier
getIDListGet all aggregate type or item attribute IDs
getNameListGet all aggregate type or item attribute names

Data Manipulation

arrayHasSameTimeStampTrue if all elements of OPC HDA data object have same time stamp vector
doubleConvert OPC HDA data object array to double type matrix
getIndexFromIDIndices matching OPC HDA data item IDs
int16Convert OPC HDA data object array to int16 matrix
int32Convert OPC HDA Data object array to int32 matrix
int64Convert OPC HDA Data object array to int64 matrix
int8Convert OPC HDA data object array to int8 matrix
logicalConvert OPC HDA data object array to logical matrix
plot Plot OPC HDA data object as lines
resampleResample OPC HDA data object to have defined time stamps
showValuesDisplay table of values for OPC HDA data object
singleConvert OPC HDA Data object array to single type matrix
stairsPlot OPC HDA data object as stairstep graph
tsintersectIntersection of time stamp in OPC HDA data object
tsunionUnion of time stamps in an OPC HDA data object
uint16Convert OPC HDA data object array to uint16 matrix
uint32Convert OPC HDA data object array to uint32 matrix
uint64Convert OPC HDA data object array to uint64 matrix
uint8Convert OPC HDA data object array to uint8 matrix

General HDA Functions

opc.getDateDisplayFormatFormat for date display of OPC objects
opc.hda.getServerInfoQuery host for installed HDA servers
opc.hdaQualityStringOPC historical data access part of quality ID as strings
opc.setDateDisplayFormatSet format for date display of OPC objects
  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS