How to use the UaoClientForOpcUaSca librairy

How to download

In your quasar project: git submodule init https://gitlab.cern.ch/atlas-dcs-opcua-servers/UaoClientForOpcUaSca.git

After that you have to modify your cmake settings by adding the submodule :set(CUSTOM_SERVER_MODULES UaoClientForOpcUaSca )

How to use (in each method)

First create the session with the endpoints connection of the server
 UaClientSdk::UaSession* session= ClientSessionFactory::connect(_Endpoints connection_);

Test the creation of the session

if (!session){
   return OpcUa_BadCommunicationError;
}

Create a client with the Id of the node

UaoClientForOpcUaSca::I2cSlave registerId(session,UaNodeId(_nodeId_,2));

Several client exist

  • I2CSlave
  • AnalogInput
  • DigitalIO
  • Jtag
  • Spi
  • etc....

After that you can write/read

registerId.writeValue(bs);
registerId.readValue(bs);
-- Main.etfortin - 2018-11-29
Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r2 - 2018-11-30 - EtienneMarieFortin
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright &© 2008-2024 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback